avfoundation

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 18, 2026 License: MIT Imports: 15 Imported by: 0

Documentation ¶

Rendered for darwin/amd64

Overview ¶

Package avfoundation provides purego-based Go bindings for the macOS AVFoundation framework.

Apple documentation: https://developer.apple.com/documentation/avfoundation

Index ¶

Constants ¶

This section is empty.

Variables ¶

This section is empty.

Functions ¶

func AVAssetChapterMetadataGroupsDidChangeNotification ¶

func AVAssetChapterMetadataGroupsDidChangeNotification() uintptr

Posted when the collection of arrays of timed metadata groups representing chapters of an AVAsset change and when any of the contents of the timed metadata groups change, but only for changes that occur after the status of the value of @"availableChapterLocales" has reached AVKeyValueStatusLoaded.

func AVAssetContainsFragmentsDidChangeNotification ¶

func AVAssetContainsFragmentsDidChangeNotification() uintptr

Posted after the value of @"containsFragments" has already been loaded and the AVFragmentedAsset is added to an AVFragmentedAssetMinder, either when 1) fragments are detected in the asset on disk after it had previously contained none or when 2) no fragments are detected in the asset on disk after it had previously contained one or more.

func AVAssetDownloadTaskMediaSelectionKey ¶

func AVAssetDownloadTaskMediaSelectionKey() uintptr

The media selection for this download. The value for this key should be an AVMediaSelection. By default, media selections for AVAssetDownloadTask will be automatically selected. Deprecated: Use AVAssetDownloadConfiguration:mediaSelections instead

func AVAssetDownloadTaskMediaSelectionPrefersMultichannelKey ¶

func AVAssetDownloadTaskMediaSelectionPrefersMultichannelKey() uintptr

Download the specified media selections with or without support for multichannel playback. The value for this key should be an NSNumber representing a BOOL. By default AVAssetDownloadTask will prefer multichannel by downloading the most capable multichannel rendition available in additon to stereo. Deprecated: Use AVAssetDownloadConfiguration:variantQualifiers with predicateForChannelCount instead

func AVAssetDownloadTaskMinimumRequiredMediaBitrateKey ¶

func AVAssetDownloadTaskMinimumRequiredMediaBitrateKey() uintptr

The lowest media bitrate greater than or equal to this value will be selected. Value should be a NSNumber in bps. If no suitable media bitrate is found, the highest media bitrate will be selected. The value for this key should be a NSNumber. By default, the highest media bitrate will be selected for download. Deprecated: Use AVAssetDownloadConfiguration:variantQualifiers with assetVariantQualifierWithPredicate using desired comparison value against averageBitRate/peakBitRate instead

func AVAssetDownloadTaskMinimumRequiredPresentationSizeKey ¶

func AVAssetDownloadTaskMinimumRequiredPresentationSizeKey() uintptr

The lowest media presentation size greater than or equal to this value will be selected. If no suitable media presentation size is found, the highest media presentation size will be selected. The value for this key should be a NSValue of CGSize. By default, the highest media presentation size will be selected for download. Deprecated: Use AVAssetDownloadConfiguration:variantQualifiers with predicateForPresentationWidth and predicateForPresentationHeight instead

func AVAssetDownloadTaskPrefersHDRKey ¶

func AVAssetDownloadTaskPrefersHDRKey() uintptr

Download the specified media selections with or without HDR content. The value for this key should be an NSNumber representing a BOOL. By default AVAssetDownloadTask will prefer HDR content. Deprecated: Use AVAssetDownloadConfiguration:variantQualifiers with assetVariantQualifierWithPredicate using [NSPredicate predicateWithFormat:@'videoAttributes.videoRange == %@', AVVideoRangePQ]

func AVAssetDownloadTaskPrefersLosslessAudioKey ¶

func AVAssetDownloadTaskPrefersLosslessAudioKey() uintptr

Download the specified media selections in lossless audio representation. The value for this key should be an NSNumber representing a BOOL. By default AVAssetDownloadTask will prefer lossy audio representation. Deprecated: Use AVAssetDownloadConfiguration:variantQualifiers with assetVariantQualifierWithPredicate using [NSPredicate predicateWithFormat:@'%d in audioAttributes.formatIDs', kAudioFormatAppleLossless]

func AVAssetDownloadedAssetEvictionPriorityDefault ¶

func AVAssetDownloadedAssetEvictionPriorityDefault() *foundation.NSString

Used to mark assets have the default priority. They will be the first to be purged.

func AVAssetDownloadedAssetEvictionPriorityImportant ¶

func AVAssetDownloadedAssetEvictionPriorityImportant() *foundation.NSString

Used to mark assets with the highest priority. They will be the last to be purged.

func AVAssetDurationDidChangeNotification ¶

func AVAssetDurationDidChangeNotification() uintptr

Posted when the duration of an AVFragmentedAsset changes while it's being minded by an AVFragmentedAssetMinder, but only for changes that occur after the status of the value of @"duration" has reached AVKeyValueStatusLoaded.

func AVAssetExportPreset640x480 ¶

func AVAssetExportPreset640x480() uintptr

func AVAssetExportPreset960x540 ¶

func AVAssetExportPreset960x540() uintptr

func AVAssetExportPreset1280x720 ¶

func AVAssetExportPreset1280x720() uintptr

func AVAssetExportPreset1920x1080 ¶

func AVAssetExportPreset1920x1080() uintptr

func AVAssetExportPreset3840x2160 ¶

func AVAssetExportPreset3840x2160() uintptr

func AVAssetExportPresetAppleM4A ¶

func AVAssetExportPresetAppleM4A() uintptr

func AVAssetExportPresetAppleM4V480pSD ¶

func AVAssetExportPresetAppleM4V480pSD() uintptr

func AVAssetExportPresetAppleM4V720pHD ¶

func AVAssetExportPresetAppleM4V720pHD() uintptr

func AVAssetExportPresetAppleM4V1080pHD ¶

func AVAssetExportPresetAppleM4V1080pHD() uintptr

func AVAssetExportPresetAppleM4VAppleTV ¶

func AVAssetExportPresetAppleM4VAppleTV() uintptr

func AVAssetExportPresetAppleM4VCellular ¶

func AVAssetExportPresetAppleM4VCellular() uintptr

func AVAssetExportPresetAppleM4VWiFi ¶

func AVAssetExportPresetAppleM4VWiFi() uintptr

func AVAssetExportPresetAppleM4ViPod ¶

func AVAssetExportPresetAppleM4ViPod() uintptr

func AVAssetExportPresetAppleProRes422LPCM ¶

func AVAssetExportPresetAppleProRes422LPCM() uintptr

func AVAssetExportPresetAppleProRes4444LPCM ¶

func AVAssetExportPresetAppleProRes4444LPCM() uintptr

func AVAssetExportPresetHEVC1920x1080 ¶

func AVAssetExportPresetHEVC1920x1080() uintptr

func AVAssetExportPresetHEVC1920x1080WithAlpha ¶

func AVAssetExportPresetHEVC1920x1080WithAlpha() uintptr

func AVAssetExportPresetHEVC3840x2160 ¶

func AVAssetExportPresetHEVC3840x2160() uintptr

func AVAssetExportPresetHEVC3840x2160WithAlpha ¶

func AVAssetExportPresetHEVC3840x2160WithAlpha() uintptr

func AVAssetExportPresetHEVC4320x2160 ¶

func AVAssetExportPresetHEVC4320x2160() uintptr

func AVAssetExportPresetHEVC7680x4320 ¶

func AVAssetExportPresetHEVC7680x4320() uintptr

func AVAssetExportPresetHEVCHighestQuality ¶

func AVAssetExportPresetHEVCHighestQuality() uintptr

func AVAssetExportPresetHEVCHighestQualityWithAlpha ¶

func AVAssetExportPresetHEVCHighestQualityWithAlpha() uintptr

func AVAssetExportPresetHighestQuality ¶

func AVAssetExportPresetHighestQuality() uintptr

func AVAssetExportPresetLowQuality ¶

func AVAssetExportPresetLowQuality() uintptr

func AVAssetExportPresetMVHEVC960x960 ¶

func AVAssetExportPresetMVHEVC960x960() uintptr

func AVAssetExportPresetMVHEVC1440x1440 ¶

func AVAssetExportPresetMVHEVC1440x1440() uintptr

func AVAssetExportPresetMVHEVC4320x4320 ¶

func AVAssetExportPresetMVHEVC4320x4320() uintptr

func AVAssetExportPresetMVHEVC7680x7680 ¶

func AVAssetExportPresetMVHEVC7680x7680() uintptr

func AVAssetExportPresetMediumQuality ¶

func AVAssetExportPresetMediumQuality() uintptr

func AVAssetExportPresetPassthrough ¶

func AVAssetExportPresetPassthrough() uintptr

func AVAssetExportSessionAllExportPresets ¶

func AVAssetExportSessionAllExportPresets() *foundation.NSArray[*foundation.NSString]

@method allExportPresets @abstract Returns all available export preset names. @discussion Returns an array of NSStrings with the names of all available presets. Note that not all presets are compatible with all AVAssets. @result An NSArray containing an NSString for each of the available preset names.

func AVAssetExportSessionDetermineCompatibilityOfExportPresetWithAssetOutputFileTypeCompletionHandler ¶

func AVAssetExportSessionDetermineCompatibilityOfExportPresetWithAssetOutputFileTypeCompletionHandler(presetName *foundation.NSString, asset *AVAsset, outputFileType *foundation.NSString, handler func(bool))

@method determineCompatibilityOfExportPreset:withAsset:outputFileType:completionHandler: @abstract Performs an inspection on the compatibility of an export preset, AVAsset and output file type. Calls the completion handler with YES if the arguments are compatible; NO otherwise. @discussion Not all export presets are compatible with all AVAssets and file types. This method can be used to query compatibility. In order to ensure that the setup and running of an export operation will succeed using a given preset no significant changes (such as adding or deleting tracks) should be made to the asset between retrieving compatible identifiers and performing the export operation. @param presetName An NSString specifying the name of the preset template for the export. @param asset An AVAsset object that is intended to be exported. @param outputFileType An AVFileType indicating a file type to check; or nil, to query whether there are any compatible types. @param handler A block called with the compatibility result.

func AVAssetExportSessionExportPresetsCompatibleWithAsset ¶

func AVAssetExportSessionExportPresetsCompatibleWithAsset(asset *AVAsset) *foundation.NSArray[*foundation.NSString]

@method exportPresetsCompatibleWithAsset: @abstract Returns only the identifiers compatible with the given AVAsset object. @discussion Not all export presets are compatible with all AVAssets. For example an video only asset is not compatible with an audio only preset. This method returns only the identifiers for presets that will be compatible with the given asset. A client should pass in an AVAsset that is ready to be exported. In order to ensure that the setup and running of an export operation will succeed using a given preset no significant changes (such as adding or deleting tracks) should be made to the asset between retrieving compatible identifiers and performing the export operation. This method will access the tracks property of the AVAsset to build the returned NSArray. To avoid blocking the calling thread, the tracks property should be loaded using the AVAsynchronousKeyValueLoading protocol before calling this method. @param asset An AVAsset object that is intended to be exported. @result An NSArray containing NSString values for the identifiers of compatible export types. The array is a complete list of the valid identifiers that can be used as arguments to initWithAsset:presetName: with the specified asset. Deprecated: since macOS 13.0.

func AVAssetImageGeneratorApertureModeCleanAperture ¶

func AVAssetImageGeneratorApertureModeCleanAperture() uintptr

@constant AVAssetImageGeneratorApertureModeCleanAperture @abstract Both pixel aspect ratio and clean aperture will be applied. @discussion An image's clean aperture is a region of video free from transition artifacts caused by the encoding of the signal.

func AVAssetImageGeneratorApertureModeEncodedPixels ¶

func AVAssetImageGeneratorApertureModeEncodedPixels() uintptr

@constant AVAssetImageGeneratorApertureModeEncodedPixels @abstract Neither pixel aspect ratio nor clean aperture will be applied. @discussion The image is not cropped to the clean aperture region and is not scaled according to the pixel aspect ratio. The encoded dimensions of the image description are displayed.

func AVAssetImageGeneratorApertureModeProductionAperture ¶

func AVAssetImageGeneratorApertureModeProductionAperture() uintptr

@constant AVAssetImageGeneratorApertureModeProductionAperture @abstract Only pixel aspect ratio will be applied. @discussion The image is not cropped to the clean aperture region, but it is scaled according to the pixel aspect ratio. Use this option when you want to see all the pixels in your video, including the edges.

func AVAssetImageGeneratorDynamicRangePolicyForceSDR ¶

func AVAssetImageGeneratorDynamicRangePolicyForceSDR() uintptr

func AVAssetImageGeneratorDynamicRangePolicyMatchSource ¶

func AVAssetImageGeneratorDynamicRangePolicyMatchSource() uintptr

func AVAssetMediaSelectionGroupsDidChangeNotification ¶

func AVAssetMediaSelectionGroupsDidChangeNotification() uintptr

Posted when the collection of media selection groups provided by an AVAsset changes and when any of the contents of its media selection groups change, but only for changes that occur after the status of the value of @"availableMediaCharacteristicsWithMediaSelectionOptions" has reached AVKeyValueStatusLoaded.

func AVAssetPlaybackConfigurationOptionAppleImmersiveVideo ¶

func AVAssetPlaybackConfigurationOptionAppleImmersiveVideo() *foundation.NSString

Indicates whether the asset is Apple Immersive Video. Clients may use this property to switch into specific display and control modes for Apple Immersive Video playback.

func AVAssetPlaybackConfigurationOptionNonRectilinearProjection ¶

func AVAssetPlaybackConfigurationOptionNonRectilinearProjection() *foundation.NSString

Indicates whether the asset calls for the use of a non-rectilinear projection for rendering video. Clients may use this property to determine whether to configure a non-rectilinear projection when displaying video.

func AVAssetPlaybackConfigurationOptionSpatialVideo ¶

func AVAssetPlaybackConfigurationOptionSpatialVideo() *foundation.NSString

Indicates whether or not the asset can be rendered as spatial video. Clients may use this property to determine whether to configure spatial video rendering.

func AVAssetPlaybackConfigurationOptionStereoMultiviewVideo ¶

func AVAssetPlaybackConfigurationOptionStereoMultiviewVideo() *foundation.NSString

Indicates whether or not the asset can rendered as stereo video and is also in a multiview compression format. Clients may use this property to determine whether to configure stereo video rendering.

func AVAssetPlaybackConfigurationOptionStereoVideo ¶

func AVAssetPlaybackConfigurationOptionStereoVideo() *foundation.NSString

Indicates whether or not the asset can be rendered as stereo video. Clients may use this property to determine whether to configure stereo video rendering.

func AVAssetResourceLoadingRequestStreamingContentKeyRequestRequiresPersistentKey ¶

func AVAssetResourceLoadingRequestStreamingContentKeyRequestRequiresPersistentKey() uintptr

@constant AVAssetResourceLoadingRequestStreamingContentKeyRequestRequiresPersistentKey @abstract Specifies whether the content key request should require a persistable key to be returned from the key vendor. Value should be a NSNumber created with +[NSNumber numberWithBool:]. Deprecated: Use -[AVPersistableContentKeyRequest persistableContentKeyFromKeyVendorResponse:options:error:] instead

func AVAssetTrackSegmentsDidChangeNotification ¶

func AVAssetTrackSegmentsDidChangeNotification() uintptr

Posted when the array of segments of an AVFragmentedAssetTrack changes while the associated instance of AVFragmentedAsset is being minded by an AVFragmentedAssetMinder, but only for changes that occur after the status of the value of @"segments" has reached AVKeyValueStatusLoaded.

func AVAssetTrackTimeRangeDidChangeNotification ¶

func AVAssetTrackTimeRangeDidChangeNotification() uintptr

Posted when the timeRange of an AVFragmentedAssetTrack changes while the associated instance of AVFragmentedAsset is being minded by an AVFragmentedAssetMinder, but only for changes that occur after the status of the value of @"timeRange" has reached AVKeyValueStatusLoaded.

func AVAssetTrackTrackAssociationsDidChangeNotification ¶

func AVAssetTrackTrackAssociationsDidChangeNotification() uintptr

Posted when the collection of track associations of an AVAssetTrack changes, but only for changes that occur after the status of the value of @"availableTrackAssociationTypes" has reached AVKeyValueStatusLoaded.

func AVAssetVariantQualifierPredicateForAudioSampleRateMediaSelectionOptionOperatorType ¶

func AVAssetVariantQualifierPredicateForAudioSampleRateMediaSelectionOptionOperatorType(sampleRate float64, mediaSelectionOption *AVMediaSelectionOption, operatorType foundation.NSPredicateOperatorType) *foundation.NSPredicate

Creates a NSPredicate for audio sample rate which can be used with other NSPredicates to express variant preferences. - Parameter sampleRate: The RHS value for the sample rate in the predicate equation. - Parameter mediaSelectionOption: The audio media selection option under consideration. - Parameter operatorType: The valid values are NSLessThanPredicateOperatorType, NSLessThanOrEqualToPredicateOperatorType, NSGreaterThanPredicateOperatorType, NSGreaterThanOrEqualToPredicateOperatorType, NSEqualToPredicateOperatorType and NSNotEqualToPredicateOperatorType.

func AVAssetVariantQualifierPredicateForAudioSampleRateOperatorType ¶

func AVAssetVariantQualifierPredicateForAudioSampleRateOperatorType(sampleRate float64, operatorType foundation.NSPredicateOperatorType) *foundation.NSPredicate

Creates a NSPredicate for audio sample rate which can be used with other NSPredicates to express variant preferences. Predicate will be evaluated on the media selection option selected for the asset. Media selection options for primary assets may be specified in the AVAssetDownloadConfiguration mediaSelections property. Media selection options for interstitial assets may be circumscribed by -[AVAssetDownloadConfiguration setInterstitialMediaSelectionCriteria: forMediaCharacteristic:]. - Parameter sampleRate: The RHS value for the sample rate in the predicate equation. - Parameter operatorType: The valid values are NSLessThanPredicateOperatorType, NSLessThanOrEqualToPredicateOperatorType, NSGreaterThanPredicateOperatorType, NSGreaterThanOrEqualToPredicateOperatorType, NSEqualToPredicateOperatorType and NSNotEqualToPredicateOperatorType.

func AVAssetVariantQualifierPredicateForBinauralAudio ¶

func AVAssetVariantQualifierPredicateForBinauralAudio(isBinauralAudio bool) *foundation.NSPredicate

Creates a NSPredicate for binaural which can be used with other NSPredicates to express variant preferences. - Parameter isBinaural: The RHS value for the value of isBinauralAudio in the predicate equation.

func AVAssetVariantQualifierPredicateForBinauralAudioMediaSelectionOption ¶

func AVAssetVariantQualifierPredicateForBinauralAudioMediaSelectionOption(isBinauralAudio bool, mediaSelectionOption *AVMediaSelectionOption) *foundation.NSPredicate

Creates a NSPredicate for binaural which can be used with other NSPredicates to express variant preferences. - Parameter isBinaural: The RHS value for the value of isBinauralAudio in the predicate equation. - Parameter mediaSelectionOption: The audio media selection option under consideration.

func AVAssetVariantQualifierPredicateForChannelCountMediaSelectionOptionOperatorType ¶

func AVAssetVariantQualifierPredicateForChannelCountMediaSelectionOptionOperatorType(channelCount int, mediaSelectionOption *AVMediaSelectionOption, operatorType foundation.NSPredicateOperatorType) *foundation.NSPredicate

Creates a NSPredicate for audio channel count which can be used with other NSPredicates to express variant preferences. - Parameter channelCount: The RHS value for the channel count in the predicate equation. - Parameter mediaSelectionOption: The audio media selection option under consideration. - Parameter operatorType: The valid values are NSLessThanPredicateOperatorType, NSLessThanOrEqualToPredicateOperatorType, NSGreaterThanPredicateOperatorType, NSGreaterThanOrEqualToPredicateOperatorType, NSEqualToPredicateOperatorType and NSNotEqualToPredicateOperatorType.

func AVAssetVariantQualifierPredicateForChannelCountOperatorType ¶

func AVAssetVariantQualifierPredicateForChannelCountOperatorType(channelCount int, operatorType foundation.NSPredicateOperatorType) *foundation.NSPredicate

Creates a NSPredicate for audio channel count which can be used with other NSPredicates to express variant preferences. Predicate will be evaluated on the media selection option selected for the asset. Media selection options for primary assets may be specified in the AVAssetDownloadConfiguration mediaSelections property. Media selection options for interstitial assets may be circumscribed by -[AVAssetDownloadConfiguration setInterstitialMediaSelectionCriteria: forMediaCharacteristic:]. - Parameter channelCount: The RHS value for the channel count in the predicate equation. - Parameter operatorType: The valid values are NSLessThanPredicateOperatorType, NSLessThanOrEqualToPredicateOperatorType, NSGreaterThanPredicateOperatorType, NSGreaterThanOrEqualToPredicateOperatorType, NSEqualToPredicateOperatorType and NSNotEqualToPredicateOperatorType.

func AVAssetVariantQualifierPredicateForDownmixAudio ¶

func AVAssetVariantQualifierPredicateForDownmixAudio(isDownmixAudio bool) *foundation.NSPredicate

Creates a NSPredicate for immersive audio which can be used with other NSPredicates to express variant preferences. Predicate will be evaluated on the media selection option selected for the asset. Media selection options for primary assets may be specified in the AVAssetDownloadConfiguration mediaSelections property. Media selection options for interstitial assets may be circumscribed by -[AVAssetDownloadConfiguration setInterstitialMediaSelectionCriteria: forMediaCharacteristic:]. - Parameter isDownmixAudio: The RHS value for the value of isDownmixAudio in the predicate equation.

func AVAssetVariantQualifierPredicateForDownmixAudioMediaSelectionOption ¶

func AVAssetVariantQualifierPredicateForDownmixAudioMediaSelectionOption(isDownmixAudio bool, mediaSelectionOption *AVMediaSelectionOption) *foundation.NSPredicate

Creates a NSPredicate for immersive audio which can be used with other NSPredicates to express variant preferences. - Parameter isDownmixAudio: The RHS value for the value of isDownmixAudio in the predicate equation. - Parameter mediaSelectionOption: The audio media selection option under consideration.

func AVAssetVariantQualifierPredicateForImmersiveAudio ¶

func AVAssetVariantQualifierPredicateForImmersiveAudio(isImmersiveAudio bool) *foundation.NSPredicate

Creates a NSPredicate for immersive audio which can be used with other NSPredicates to express variant preferences. Predicate will be evaluated on the media selection option selected for the asset. Media selection options for primary assets may be specified in the AVAssetDownloadConfiguration mediaSelections property. Media selection options for interstitial assets may be circumscribed by -[AVAssetDownloadConfiguration setInterstitialMediaSelectionCriteria: forMediaCharacteristic:]. - Parameter isImmersiveAudio: The RHS value for the value of isImmersiveAudio in the predicate equation.

func AVAssetVariantQualifierPredicateForImmersiveAudioMediaSelectionOption ¶

func AVAssetVariantQualifierPredicateForImmersiveAudioMediaSelectionOption(isImmersiveAudio bool, mediaSelectionOption *AVMediaSelectionOption) *foundation.NSPredicate

Creates a NSPredicate for immersive audio which can be used with other NSPredicates to express variant preferences. - Parameter isImmersiveAudio: The RHS value for the value of isImmersiveAudio in the predicate equation. - Parameter mediaSelectionOption: The audio media selection option under consideration.

func AVAssetVariantQualifierPredicateForPresentationHeightOperatorType ¶

func AVAssetVariantQualifierPredicateForPresentationHeightOperatorType(height float64, operatorType foundation.NSPredicateOperatorType) *foundation.NSPredicate

Creates a NSPredicate for presentation size height which can be used with other NSPredicates to express variant preferences. - Parameter height: The RHS value for the presentation size height in the predicate equation. - Parameter operatorType: The valid values are NSLessThanPredicateOperatorType, NSLessThanOrEqualToPredicateOperatorType, NSGreaterThanPredicateOperatorType, NSGreaterThanOrEqualToPredicateOperatorType, NSEqualToPredicateOperatorType and NSNotEqualToPredicateOperatorType.

func AVAssetVariantQualifierPredicateForPresentationWidthOperatorType ¶

func AVAssetVariantQualifierPredicateForPresentationWidthOperatorType(width float64, operatorType foundation.NSPredicateOperatorType) *foundation.NSPredicate

Creates a NSPredicate for presentation size width which can be used with other NSPredicates to express variant preferences. - Parameter width: The RHS value for the presentation size width in the predicate equation. - Parameter operatorType: The valid values are NSLessThanPredicateOperatorType, NSLessThanOrEqualToPredicateOperatorType, NSGreaterThanPredicateOperatorType, NSGreaterThanOrEqualToPredicateOperatorType, NSEqualToPredicateOperatorType and NSNotEqualToPredicateOperatorType.

func AVAssetWasDefragmentedNotification ¶

func AVAssetWasDefragmentedNotification() uintptr

Posted when the asset on disk is defragmented while an AVFragmentedAsset is being minded by an AVFragmentedAssetMinder, but only if the defragmentation occurs after the status of the value of @"canContainFragments" has reached AVKeyValueStatusLoaded. After this notification is posted, the value of the asset properties canContainFragments and containsFragments will both be NO.

func AVAssetWriterInputMediaDataLocationBeforeMainMediaDataNotInterleaved ¶

func AVAssetWriterInputMediaDataLocationBeforeMainMediaDataNotInterleaved() uintptr

Indicates that the media data should be laid out before all the media data with AVAssetWriterInputMediaDataLocationInterleavedWithMainMediaData and not be interleaved.

func AVAssetWriterInputMediaDataLocationInterleavedWithMainMediaData ¶

func AVAssetWriterInputMediaDataLocationInterleavedWithMainMediaData() uintptr

Indicates that the media data should be interleaved with all other media data with this constant.

func AVAssetWriterInputMediaDataLocationSparselyInterleavedWithMainMediaData ¶

func AVAssetWriterInputMediaDataLocationSparselyInterleavedWithMainMediaData() uintptr

Indicates that there may be large segments of time without any media data from this track. When mediaDataLocation is set to this value, AVAssetWriter will interleave the media data, but will not wait for media data from this track to achieve tight interleaving with other tracks.

func AVAudioTimePitchAlgorithmSpectral ¶

func AVAudioTimePitchAlgorithmSpectral() *foundation.NSString

func AVAudioTimePitchAlgorithmTimeDomain ¶

func AVAudioTimePitchAlgorithmTimeDomain() *foundation.NSString

func AVAudioTimePitchAlgorithmVarispeed ¶

func AVAudioTimePitchAlgorithmVarispeed() *foundation.NSString

func AVCaptionConversionAdjustmentTypeTimeRange ¶

func AVCaptionConversionAdjustmentTypeTimeRange() *foundation.NSString

@constant AVCaptionConversionAdjustmentTypeTimeRange @abstract Indicates a timing adjustment.

func AVCaptionConversionWarningTypeExcessMediaData ¶

func AVCaptionConversionWarningTypeExcessMediaData() *foundation.NSString

@constant AVCaptionConversionWarningTypeExcessMediaData @abstract Indicates that one or more captions in the validator's captions array exceed the capacity for media data of the media type and subtype specified by the conversion settings.

func AVCaptionMediaSubTypeKey ¶

func AVCaptionMediaSubTypeKey() *foundation.NSString

@constant AVCaptionMediaSubTypeKey @abstract Indicates the output media subtype of a caption conversion operation. For example, [NSNumber numberWithInt:kCMClosedCaptionFormatType_CEA608]. @discussion Both numeric and string forms of media subtypes are accepted for caption conversions, so you could, for example, use @"c608" instead of [NSNumber numberWithInt:kCMClosedCaptionFormatType_CEA608].

func AVCaptionMediaTypeKey ¶

func AVCaptionMediaTypeKey() *foundation.NSString

@constant AVCaptionMediaTypeKey @abstract Indicates the output media type of a caption conversion operation. For example, AVMediaTypeClosedCaption.

func AVCaptionRendererCaptionPreviewForProfileIDExtendedLanguageTagRenderSize ¶

func AVCaptionRendererCaptionPreviewForProfileIDExtendedLanguageTagRenderSize(profileID *foundation.NSString, extendedLanguageTag *foundation.NSString, renderSize corefoundation.CGSize) *foundation.NSAttributedString

@method captionPreviewForProfileID:extendedLanguageTag:renderSize: @abstract Generate a caption preview attributed string for the specified profile ID. @discussion Returns an attributed string containing a preview of captions rendered using the specified profile ID. @param profileID The identifier of the accessibility profile to use for caption appearance. Profile IDs can be obtained from MACaptionAppearanceCopyProfileIDs(). This determines font, color, background, and other visual characteristics. @param extendedLanguageTag The IETF BCP 47 (RFC 4646) language identifier that will be used to generate the localized caption preview text. If nil, the system language will be used. @param renderSize The size of the layer into which the captions will be rendered. This determines the layout and positioning of the caption text. @result An NSAttributedString containing the caption preview. @discussion It is strongly recommended that the caller take appropriate measures to prevent blocking essential services such as the user interface, for example, by avoiding calling this method in the main thread.

func AVCaptionTimeCodeFrameDurationKey ¶

func AVCaptionTimeCodeFrameDurationKey() *foundation.NSString

@constant AVCaptionTimeCodeFrameDurationKey @abstract Frame duration used for the time code. @discussion Some formats, such as TTML, use time code notation to indicate the timing of a caption. Use the property to specify the frame rate of the time code. For example, if the time code steps for every 1001 / 30000 seconds, the value should be CMTime(value: 1001, scale: 30000).

func AVCaptionUseDropFrameTimeCodeKey ¶

func AVCaptionUseDropFrameTimeCodeKey() *foundation.NSString

@constant AVCaptionUseDropFrameTimeCodeKey @abstract Indicates whether to use drop frame time code. @discussion Some formats, such as SCC, use time code notation to indicate the timing of a caption. Use the property to specify whether to use the drop frame time code or non-drop frame time code. When the value for this key is a NSNumber indicating the BOOL YES, the receiver will use the drop frame time code. When the value for this key is a NSNumber indicating the BOOL NO, the receiver will use the non-drop frame time code. The default is NO.

func AVCaptureAudioFileOutputAvailableOutputFileTypes ¶

func AVCaptureAudioFileOutputAvailableOutputFileTypes() *foundation.NSArray[*foundation.NSString]

@method availableOutputFileTypes @abstract Provides the file types AVCaptureAudioFileOutput can write. @result An NSArray of UTIs identifying the file types the AVCaptureAudioFileOutput class can write.

func AVCaptureDeviceDevices ¶

func AVCaptureDeviceDevices() *foundation.NSArray[*AVCaptureDevice]

@method devices @abstract Returns an array of devices currently available for use as media input sources. @result An NSArray of AVCaptureDevice instances for each available device. @discussion This method returns an array of AVCaptureDevice instances for input devices currently connected and available for capture. The returned array contains all devices that are available at the time the method is called. Applications should observe AVCaptureDeviceWasConnectedNotification and AVCaptureDeviceWasDisconnectedNotification to be notified when the list of available devices has changed. Deprecated: Use AVCaptureDeviceDiscoverySession instead.

func AVCaptureDeviceDevicesWithMediaType ¶

func AVCaptureDeviceDevicesWithMediaType(mediaType *foundation.NSString) *foundation.NSArray[*AVCaptureDevice]

@method devicesWithMediaType: @abstract Returns an array of devices currently available for use as sources of media with the given media type. @param mediaType The media type, such as AVMediaTypeVideo, AVMediaTypeAudio, or AVMediaTypeMuxed, supported by each returned device. @result An NSArray of AVCaptureDevice instances for each available device. @discussion This method returns an array of AVCaptureDevice instances for input devices currently connected and available for capture that provide media of the given type. Media type constants are defined in AVMediaFormat.h. The returned array contains all devices that are available at the time the method is called. Applications should observe AVCaptureDeviceWasConnectedNotification and AVCaptureDeviceWasDisconnectedNotification to be notified when the list of available devices has changed. Deprecated: Use AVCaptureDeviceDiscoverySession instead.

func AVCaptureDeviceIsBackgroundReplacementEnabled ¶

func AVCaptureDeviceIsBackgroundReplacementEnabled() bool

@property backgroundReplacementEnabled @abstract A class property indicating whether the user has enabled the Background Replacement feature for this application.

func AVCaptureDeviceIsCenterStageEnabled ¶

func AVCaptureDeviceIsCenterStageEnabled() bool

@property centerStageEnabled @abstract A class property indicating whether the Center Stage feature is currently enabled or disabled (such as in Control Center or programmatically via your app). @discussion This property may only be set if centerStageControlMode is AVCaptureCenterStageControlModeApp or AVCaptureCenterStageControlModeCooperative, and otherwise throws an NSInvalidArgumentException. When centerStageControlMode is AVCaptureCenterStageControlModeUser or AVCaptureCenterStageControlModeCooperative, this property may change according to user desire (such as enabling / disabling the feature in Control Center), so you should key-value observe it.

func AVCaptureDeviceIsEdgeLightActive ¶

func AVCaptureDeviceIsEdgeLightActive() bool

A class property indicating whether the edge light UI is actively being shown on a screen. This readonly property reflects whether the edge light UI is actively being shown on a screen. It is key-value observable.

func AVCaptureDeviceIsEdgeLightEnabled ¶

func AVCaptureDeviceIsEdgeLightEnabled() bool

A class property indicating whether the Edge Light feature is currently enabled in Control Center. This readonly property changes to reflect the Edge Light state in Control Center. It is key-value observable.

func AVCaptureDeviceIsPortraitEffectEnabled ¶

func AVCaptureDeviceIsPortraitEffectEnabled() bool

@property portraitEffectEnabled @abstract A class property indicating whether the Portrait Effect feature is currently enabled in Control Center. @discussion This property changes to reflect the Portrait Effect state in Control Center. It is key-value observable. On iOS, Portrait Effect only applies to video conferencing apps by default (apps that use "voip" as one of their UIBackgroundModes). Non video conferencing apps may opt in for the Portrait Effect by adding the following key to their Info.plist: <key>NSCameraPortraitEffectEnabled</key> <true/>

func AVCaptureDeviceIsStudioLightEnabled ¶

func AVCaptureDeviceIsStudioLightEnabled() bool

@property studioLightEnabled @abstract A class property indicating whether the Studio Light feature is currently enabled in Control Center. @discussion This property changes to reflect the Studio Light state in Control Center. It is key-value observable. On iOS, Studio Light only applies to video conferencing apps by default (apps that use "voip" as one of their UIBackgroundModes). Non video conferencing apps may opt in for Studio Light by adding the following key to their Info.plist: <key>NSCameraStudioLightEnabled</key> <true/>

func AVCaptureDeviceReactionEffectGesturesEnabled ¶

func AVCaptureDeviceReactionEffectGesturesEnabled() bool

@property reactionEffectGesturesEnabled @abstract A class property indicating whether gesture detection will trigger reaction effects on the video stream. Gesture detection will only run when the device's activeFormat.reactionEffectsSupported is also YES, which will be reflected by canPerformReactionEffects. @discussion This property changes to reflect the Gestures state in Control Center. It is key-value observable. Clients can call performEffectForReaction: independently of whether gesture detection is enabled, reaction effects from either source will be intermixed. By default, gesture detection is enabled. As of iOS 17.4 and macOS 14.4, applications can control the default value of this property by adding the following key to their Info.plist: <key>NSCameraReactionEffectGesturesEnabledDefault</key> A value of true enables gesture detection and a value of false disables it, until such time that the user makes their own selection in Control Center.

func AVCaptureDeviceReactionEffectsEnabled ¶

func AVCaptureDeviceReactionEffectsEnabled() bool

@property reactionEffectsEnabled @abstract A class property indicating whether the application is suitable for reaction effects, either by automatic gesture detection, or by calls to -[AVCaptureDevice performEffectForReaction:]. Reactions are only rendered when the device's activeFormat.reactionEffectsSupported is also YES, which will be reflected by canPerformReactionEffects when the feature is both enabled and supported. @discussion On macOS, Reaction Effects are enabled by default for all applications. On iOS, Reaction Effects are enabled by default for video conferencing applications (apps that use "voip" as one of their UIBackgroundModes). Non video conferencing applications may opt in for Reaction Effects by adding the following key to their Info.plist: <key>NSCameraReactionEffectsEnabled</key> <true/>

func AVCaptureDeviceRequestAccessForMediaTypeCompletionHandler ¶

func AVCaptureDeviceRequestAccessForMediaTypeCompletionHandler(mediaType *foundation.NSString, handler func(bool))

@method requestAccessForMediaType:completionHandler: @abstract Requests access to the underlying hardware for the media type, showing a dialog to the user if necessary. @param mediaType The media type, either AVMediaTypeVideo or AVMediaTypeAudio @param handler A block called with the result of requesting access @discussion Use this function to request access to the hardware for a given media type. Media type constants are defined in AVMediaFormat.h. If any media type other than AVMediaTypeVideo or AVMediaTypeAudio is supplied, an NSInvalidArgumentException will be thrown. This call will not block while the user is being asked for access, allowing the client to continue running. Until access has been granted, any AVCaptureDevices for the media type will vend silent audio samples or black video frames. The user is only asked for permission the first time the client requests access. Later calls use the permission granted by the user. Note that the authorization dialog will automatically be shown if the status is AVAuthorizationStatusNotDetermined when creating an AVCaptureDeviceInput. Invoking this method with AVMediaTypeAudio is equivalent to calling -[AVAudioSession requestRecordPermission:]. The completion handler is called on an arbitrary dispatch queue. It is the client's responsibility to ensure that any UIKit-related updates are called on the main queue or main thread as a result.

func AVCaptureDeviceSetCenterStageControlMode ¶

func AVCaptureDeviceSetCenterStageControlMode(centerStageControlMode AVCaptureCenterStageControlMode)

func AVCaptureDeviceSetCenterStageEnabled ¶

func AVCaptureDeviceSetCenterStageEnabled(centerStageEnabled bool)

func AVCaptureDeviceSetUserPreferredCamera ¶

func AVCaptureDeviceSetUserPreferredCamera(userPreferredCamera *AVCaptureDevice)

func AVCaptureDeviceShowSystemUserInterface ¶

func AVCaptureDeviceShowSystemUserInterface(systemUserInterface AVCaptureSystemUserInterface)

@method showSystemUserInterface: @abstract Displays the system's user interface for video effects or microphone modes. @param systemUserInterface The system UI to show. @discussion This method allows the calling application to prompt the user to make changes to Video Effects (such as Center Stage or the Portrait Effect) or Microphone Modes. It brings up the system user interface and deep links to the appropriate module. This method is non-blocking. After presenting the desired system user interface, control returns immediately to the application.

func AVCaptureDeviceTypeBuiltInMicrophone ¶

func AVCaptureDeviceTypeBuiltInMicrophone() uintptr

@constant AVCaptureDeviceTypeBuiltInMicrophone A deprecated synonym for AVCaptureDeviceTypeMicrophone. Please use AVCaptureDeviceTypeMicrophone instead. Deprecated: since macOS 14.0.

func AVCaptureDeviceTypeBuiltInWideAngleCamera ¶

func AVCaptureDeviceTypeBuiltInWideAngleCamera() uintptr

@constant AVCaptureDeviceTypeBuiltInWideAngleCamera A built-in wide angle camera device. These devices are suitable for general purpose use.

func AVCaptureDeviceTypeContinuityCamera ¶

func AVCaptureDeviceTypeContinuityCamera() uintptr

@constant AVCaptureDeviceTypeContinuityCamera A continuity camera device. These devices are suitable for general purpose use. Note that devices of this type may only be discovered using an AVCaptureDeviceDiscoverySession or -[AVCaptureDevice defaultDeviceWithDeviceType:mediaType:position:]. @discussion Starting in macOS 14.0 and Mac Catalyst 17.0, apps may opt in for using AVCaptureDeviceTypeContinuityCamera by adding the following key to their Info.plist: <key>NSCameraUseContinuityCameraDeviceType</key> <true/> Otherwise, continuity cameras on macOS and Mac Catalyst report that their device type is AVCaptureDeviceTypeBuiltInWideAngleCamera.

func AVCaptureDeviceTypeDeskViewCamera ¶

func AVCaptureDeviceTypeDeskViewCamera() uintptr

@constant AVCaptureDeviceTypeDeskViewCamera A distortion corrected cut out from an ultra wide camera, made to approximate an overhead camera pointing at a desk. Supports multicam operation.

func AVCaptureDeviceTypeExternal ¶

func AVCaptureDeviceTypeExternal() uintptr

@constant AVCaptureDeviceTypeExternal An external device type. On iPad, external devices are those that conform to the UVC (USB Video Class) specification. @discussion Starting in Mac Catalyst 17.0, apps may opt in for using AVCaptureDeviceTypeExternal by adding the following key to their Info.plist: <key>NSCameraUseExternalDeviceType</key> <true/> Otherwise, external cameras on Mac Catalyst report that their device type is AVCaptureDeviceTypeBuiltInWideAngleCamera. Prior to visionOS 3.0, your app must have the `com.apple.developer.avfoundation.uvc-device-access` entitlement in order to discover and use devices of type `AVCaptureDeviceTypeExternal` on visionOS.

func AVCaptureDeviceTypeExternalUnknown ¶

func AVCaptureDeviceTypeExternalUnknown() uintptr

@constant AVCaptureDeviceTypeExternalUnknown A deprecated synonym for AVCaptureDeviceTypeExternal. Please use AVCaptureDeviceTypeExternal instead. Deprecated: since macOS 14.0.

func AVCaptureDeviceTypeMicrophone ¶

func AVCaptureDeviceTypeMicrophone() uintptr

@constant AVCaptureDeviceTypeMicrophone A microphone. On iOS and tvOS, only one AVCaptureDevice of type AVCaptureDeviceTypeMicrophone is exposed to the system. The audio routing subsystem decides which physical microphone to use, be it a built in microphone, a wired headset, an external microphone, etc. The microphone device's `localizedName` will change as the audio subsystem switches to a different physical device.

func AVCaptureDeviceWasConnectedNotification ¶

func AVCaptureDeviceWasConnectedNotification() uintptr

@constant AVCaptureDeviceWasConnectedNotification @abstract Posted when a device becomes available on the system. @discussion The notification object is an AVCaptureDevice instance representing the device that became available.

func AVCaptureDeviceWasDisconnectedNotification ¶

func AVCaptureDeviceWasDisconnectedNotification() uintptr

@constant AVCaptureDeviceWasDisconnectedNotification @abstract Posted when a device becomes unavailable on the system. @discussion The notification object is an AVCaptureDevice instance representing the device that became unavailable.

func AVCaptureExternalDisplayConfiguratorIsBypassingColorSpaceConversionSupported ¶

func AVCaptureExternalDisplayConfiguratorIsBypassingColorSpaceConversionSupported() bool

Whether the external display supports bypassing color space conversion. If `true`, you may instantiate a configurator with a configuration specifying “AVCaptureExternalDisplayConfiguration/bypassColorSpaceConversion“ set to `true`.

func AVCaptureExternalDisplayConfiguratorIsMatchingFrameRateSupported ¶

func AVCaptureExternalDisplayConfiguratorIsMatchingFrameRateSupported() bool

Whether the external display supports matching frame rate to a capture device. If `true`, you may instantiate a configurator with a configuration specifying “AVCaptureExternalDisplayConfiguration/shouldMatchFrameRate“ set to `true`.

func AVCaptureExternalDisplayConfiguratorIsPreferredResolutionSupported ¶

func AVCaptureExternalDisplayConfiguratorIsPreferredResolutionSupported() bool

Whether the external display supports configuration to your preferred resolution. If `true`, you may instantiate a configurator with a configuration specifying “AVCaptureExternalDisplayConfiguration/preferredResolution“ set to `true`.

func AVCaptureInputPortFormatDescriptionDidChangeNotification ¶

func AVCaptureInputPortFormatDescriptionDidChangeNotification() uintptr

@constant AVCaptureInputPortFormatDescriptionDidChangeNotification @abstract This notification is posted when the value of an AVCaptureInputPort instance's formatDescription property changes. @discussion The notification object is the AVCaptureInputPort instance whose format description changed.

func AVCaptureMaxAvailableTorchLevel ¶

func AVCaptureMaxAvailableTorchLevel() uintptr

@constant AVCaptureMaxAvailableTorchLevel A special value that may be passed to -setTorchModeWithLevel:error: to set the torch to the maximum level currently available. Under thermal duress, the maximum available torch level may be less than 1.0.

func AVCaptureReactionSystemImageNameForType ¶

func AVCaptureReactionSystemImageNameForType(reactionType *foundation.NSString) *foundation.NSString

@function AVCaptureReactionSystemImageNameForType @abstract Returns the name for UIImage or NSImage systemImageNamed: method to obtain the recommended iconography for a specified reaction type.

func AVCaptureReactionTypeBalloons ¶

func AVCaptureReactionTypeBalloons() uintptr

@constant AVCaptureReactionTypeBalloons @abstract Indicates a reaction which features balloons rising through the scene.

func AVCaptureReactionTypeConfetti ¶

func AVCaptureReactionTypeConfetti() uintptr

@constant AVCaptureReactionTypeConfetti @abstract Indicates a reaction which features festive spots of color falling through the scene.

func AVCaptureReactionTypeFireworks ¶

func AVCaptureReactionTypeFireworks() uintptr

@constant AVCaptureReactionTypeFireworks @abstract Indicates a reaction which features fireworks bursting in the background.

func AVCaptureReactionTypeHeart ¶

func AVCaptureReactionTypeHeart() uintptr

@constant AVCaptureReactionTypeHeart @abstract Indicates a reaction which features one or more heart symbols.

func AVCaptureReactionTypeLasers ¶

func AVCaptureReactionTypeLasers() uintptr

@constant AVCaptureReactionTypeLasers @abstract Indicates a reaction which features a bright laser display projecting into the scene.

func AVCaptureReactionTypeRain ¶

func AVCaptureReactionTypeRain() uintptr

@constant AVCaptureReactionTypeRain @abstract Indicates a reaction which features a dark and stormy night.

func AVCaptureReactionTypeThumbsDown ¶

func AVCaptureReactionTypeThumbsDown() uintptr

@constant AVCaptureReactionTypeThumbsDown @abstract Indicates a reaction which features a thumbs-down symbol.

func AVCaptureReactionTypeThumbsUp ¶

func AVCaptureReactionTypeThumbsUp() uintptr

@constant AVCaptureReactionTypeThumbsUp @abstract Indicates a reaction which features a thumbs-up symbol.

func AVCaptureSceneMonitoringStatusNotEnoughLight ¶

func AVCaptureSceneMonitoringStatusNotEnoughLight() uintptr

The light level of the current scene is insufficient for the current set of features to function optimally.

func AVCaptureSessionDidStartRunningNotification ¶

func AVCaptureSessionDidStartRunningNotification() uintptr

@constant AVCaptureSessionDidStartRunningNotification @abstract Posted when an instance of AVCaptureSession successfully starts running. @discussion Clients may observe the AVCaptureSessionDidStartRunningNotification to know when an instance of AVCaptureSession starts running.

func AVCaptureSessionDidStopRunningNotification ¶

func AVCaptureSessionDidStopRunningNotification() uintptr

@constant AVCaptureSessionDidStopRunningNotification @abstract Posted when an instance of AVCaptureSession stops running. @discussion Clients may observe the AVCaptureSessionDidStopRunningNotification to know when an instance of AVCaptureSession stops running. An AVCaptureSession instance may stop running automatically due to external system conditions, such as the device going to sleep, or being locked by a user.

func AVCaptureSessionErrorKey ¶

func AVCaptureSessionErrorKey() uintptr

@constant AVCaptureSessionErrorKey @abstract The key used to provide an NSError describing the failure condition in an AVCaptureSessionRuntimeErrorNotification. @discussion AVCaptureSessionErrorKey may be found in the userInfo dictionary provided with an AVCaptureSessionRuntimeErrorNotification. The NSError associated with the notification gives greater detail on the nature of the error, and in some cases recovery suggestions.

func AVCaptureSessionInterruptionEndedNotification ¶

func AVCaptureSessionInterruptionEndedNotification() uintptr

@constant AVCaptureSessionInterruptionEndedNotification @abstract Posted when an instance of AVCaptureSession ceases to be interrupted. @discussion Clients may observe the AVCaptureSessionInterruptionEndedNotification to know when an instance of AVCaptureSession ceases to be interrupted, for example, when a phone call ends, and hardware resources needed to run the session are again available. When appropriate, the AVCaptureSession instance that was previously stopped in response to an interruption will automatically restart once the interruption ends.

func AVCaptureSessionPreset320x240 ¶

func AVCaptureSessionPreset320x240() uintptr

@constant AVCaptureSessionPreset320x240 @abstract An AVCaptureSession preset suitable for 320x240 video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset320x240 to achieve 320x240 output.

func AVCaptureSessionPreset352x288 ¶

func AVCaptureSessionPreset352x288() uintptr

@constant AVCaptureSessionPreset352x288 @abstract An AVCaptureSession preset suitable for 352x288 video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset352x288 to achieve CIF quality (352x288) output.

func AVCaptureSessionPreset640x480 ¶

func AVCaptureSessionPreset640x480() uintptr

@constant AVCaptureSessionPreset640x480 @abstract An AVCaptureSession preset suitable for 640x480 video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset640x480 to achieve VGA quality (640x480) output.

func AVCaptureSessionPreset960x540 ¶

func AVCaptureSessionPreset960x540() uintptr

@constant AVCaptureSessionPreset960x540 @abstract An AVCaptureSession preset suitable for 960x540 video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset960x540 to achieve quarter HD quality (960x540) output.

func AVCaptureSessionPreset1280x720 ¶

func AVCaptureSessionPreset1280x720() uintptr

@constant AVCaptureSessionPreset1280x720 @abstract An AVCaptureSession preset suitable for 1280x720 video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset1280x720 to achieve 1280x720 output.

func AVCaptureSessionPreset1920x1080 ¶

func AVCaptureSessionPreset1920x1080() uintptr

@constant AVCaptureSessionPreset1920x1080 @abstract An AVCaptureSession preset suitable for 1920x1080 video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset1920x1080 to achieve 1920x1080 output.

func AVCaptureSessionPreset3840x2160 ¶

func AVCaptureSessionPreset3840x2160() uintptr

@constant AVCaptureSessionPreset3840x2160 @abstract An AVCaptureSession preset suitable for 3840x2160 (UHD 4K) video output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPreset3840x2160 to achieve 3840x2160 output.

func AVCaptureSessionPresetHigh ¶

func AVCaptureSessionPresetHigh() uintptr

@constant AVCaptureSessionPresetHigh @abstract An AVCaptureSession preset suitable for high quality video and audio output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPresetHigh to achieve high quality video and audio output. AVCaptureSessionPresetHigh is the default sessionPreset value.

func AVCaptureSessionPresetLow ¶

func AVCaptureSessionPresetLow() uintptr

@constant AVCaptureSessionPresetLow @abstract An AVCaptureSession preset suitable for low quality output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPresetLow to achieve output video and audio bitrates suitable for sharing over 3G.

func AVCaptureSessionPresetMedium ¶

func AVCaptureSessionPresetMedium() uintptr

@constant AVCaptureSessionPresetMedium @abstract An AVCaptureSession preset suitable for medium quality output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPresetMedium to achieve output video and audio bitrates suitable for sharing over WiFi.

func AVCaptureSessionPresetPhoto ¶

func AVCaptureSessionPresetPhoto() uintptr

@constant AVCaptureSessionPresetPhoto @abstract An AVCaptureSession preset suitable for high resolution photo quality output. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPresetPhoto for full resolution photo quality output.

func AVCaptureSessionPresetiFrame960x540 ¶

func AVCaptureSessionPresetiFrame960x540() uintptr

@constant AVCaptureSessionPresetiFrame960x540 @abstract An AVCaptureSession preset producing 960x540 Apple iFrame video and audio content. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPresetiFrame960x540 to achieve 960x540 quality iFrame H.264 video at ~30 Mbits/sec with AAC audio. QuickTime movies captured in iFrame format are optimal for editing applications.

func AVCaptureSessionPresetiFrame1280x720 ¶

func AVCaptureSessionPresetiFrame1280x720() uintptr

@constant AVCaptureSessionPresetiFrame1280x720 @abstract An AVCaptureSession preset producing 1280x720 Apple iFrame video and audio content. @discussion Clients may set an AVCaptureSession instance's sessionPreset to AVCaptureSessionPresetiFrame1280x720 to achieve 1280x720 quality iFrame H.264 video at ~40 Mbits/sec with AAC audio. QuickTime movies captured in iFrame format are optimal for editing applications.

func AVCaptureSessionRuntimeErrorNotification ¶

func AVCaptureSessionRuntimeErrorNotification() uintptr

@constant AVCaptureSessionRuntimeErrorNotification @abstract Posted when an unexpected error occurs while an AVCaptureSession instance is running. @discussion The notification object is the AVCaptureSession instance that encountered a runtime error. The userInfo dictionary contains an NSError for the key AVCaptureSessionErrorKey.

func AVCaptureSessionWasInterruptedNotification ¶

func AVCaptureSessionWasInterruptedNotification() uintptr

@constant AVCaptureSessionWasInterruptedNotification @abstract Posted when an instance of AVCaptureSession becomes interrupted. @discussion Clients may observe the AVCaptureSessionWasInterruptedNotification to know when an instance of AVCaptureSession has been interrupted, for example, by an incoming phone call, or alarm, or another application taking control of needed hardware resources. When appropriate, the AVCaptureSession instance will stop running automatically in response to an interruption. Beginning in iOS 9.0, the AVCaptureSessionWasInterruptedNotification userInfo dictionary contains an AVCaptureSessionInterruptionReasonKey indicating the reason for the interruption.

func AVCaptureStillImageOutputJpegStillImageNSDataRepresentation ¶

func AVCaptureStillImageOutputJpegStillImageNSDataRepresentation(jpegSampleBuffer unsafe.Pointer) *foundation.NSData

@method jpegStillImageNSDataRepresentation: @abstract Converts the still image data and metadata attachments in a JPEG sample buffer to an NSData representation. @param jpegSampleBuffer The sample buffer carrying JPEG image data, optionally with Exif metadata sample buffer attachments. This method throws an NSInvalidArgumentException if jpegSampleBuffer is NULL or not in the JPEG format. @discussion This method returns an NSData representation of a JPEG still image sample buffer, merging the image data and Exif metadata sample buffer attachments without recompressing the image. The returned NSData is suitable for writing to disk.

func AVCaptureTimecodeCreateMetadataSampleBufferAssociatedWithPresentationTimeStamp ¶

func AVCaptureTimecodeCreateMetadataSampleBufferAssociatedWithPresentationTimeStamp(timecode AVCaptureTimecode, presentationTimeStamp coremedia.CMTime) unsafe.Pointer

Creates a sample buffer containing Timecode Media Description metadata for integration with a video track. - Parameter timecode: The “AVCaptureTimecode“ instance providing the timecode details to encode. - Parameter presentationTimeStamp: The presentation time stamp that determines the exact moment in the media timeline where the metadata should be applied. It is embedded in the sample timing info (“CMSampleTimingInfo“) and ensures that the packaged metadata synchronizes accurately with the corresponding video frame. - Returns: A “CMSampleBufferRef“ with the encoded Timecode Media Description metadata for video synchronization, or `nil` if sample buffer creation fails.

func AVCaptureTimecodeCreateMetadataSampleBufferForDuration ¶

func AVCaptureTimecodeCreateMetadataSampleBufferForDuration(timecode AVCaptureTimecode, duration coremedia.CMTime) unsafe.Pointer

Creates a sample buffer containing Timecode Media Description metadata for a specified duration. - Parameter timecode: The “AVCaptureTimecode“ instance providing the timecode details for the metadata sample. - Parameter duration: The duration that the metadata sample buffer should represent. - Returns: A “CMSampleBufferRef“ with encoded Timecode Media Description metadata for the given duration, or `nil` if sample buffer creation fails. Use this function for scenarios where timecode metadata needs to span a custom interval (not just a single frame), such as non-frame-accurate workflows or for describing a segment of media with a consistent timecode.

func AVContentKeyRequestProtocolVersionsKey ¶

func AVContentKeyRequestProtocolVersionsKey() uintptr

Specifies the versions of the content protection protocol supported by the application as an NSArray of one or more NSNumber objects.

func AVContentKeyRequestRandomDeviceIdentifierSeedKey ¶

func AVContentKeyRequestRandomDeviceIdentifierSeedKey() uintptr

Value is an NSData containing a 16-byte seed to randomize the user's deviceID contained in the SPC blob during FairPlay key exchange This property must be used in conjunction with AVContentKeyRequestShouldRandomizeDeviceIdentifierKey. Use a RND function to generate a 16 byte seed. This seed will be used to randomize the user's anonymized device ID if AVContentKeyRequestShouldRandomizeDeviceIdentifierKey is true. Content providers use the SPC to distinguish the playback device from other devices, typically to enforce per-screen business rule limits. If the app developer, in cooperation with the content vendor, does not require to distinguish the playback device, they can further enhance user privacy by making this identifier non-constant, using this option. In either case, apps are not allowed to store or use the FairPlay anonymized device ID for anything other than to enforce business rule limits. App developers must use the AppTrackingTransparency framework to disclose to users if the application or the related FairPlay Key Server collect data about end users and share it with other companies for purposes of tracking across apps and web sites.

func AVContentKeyRequestRequiresValidationDataInSecureTokenKey ¶

func AVContentKeyRequestRequiresValidationDataInSecureTokenKey() uintptr

Request secure token to have extended validation data. The value for the key should be previously created offline key using -[AVContentKeyRequest persistableContentKeyFromKeyVendorResponse:options:error:].

func AVContentKeyRequestRetryReasonReceivedObsoleteContentKey ¶

func AVContentKeyRequestRetryReasonReceivedObsoleteContentKey() *foundation.NSString

Indicates that the content key request should be retried because an obsolete key response was set on the previous content key request.

func AVContentKeyRequestRetryReasonReceivedResponseWithExpiredLease ¶

func AVContentKeyRequestRetryReasonReceivedResponseWithExpiredLease() *foundation.NSString

Indicates that the content key request should be retried because a key response with expired lease was set on the previous content key request.

func AVContentKeyRequestRetryReasonTimedOut ¶

func AVContentKeyRequestRetryReasonTimedOut() *foundation.NSString

Indicates that the content key request should be retried because the key response was not set soon enough either due the initial request/response was taking too long, or a lease was expiring in the meantime.

func AVContentKeyRequestShouldRandomizeDeviceIdentifierKey ¶

func AVContentKeyRequestShouldRandomizeDeviceIdentifierKey() uintptr

Value is an Boolean indicating whether the user's deviceID contained in the SPC blob during FairPlay key exchange should be randomized using a system generated seed Content providers use the SPC to distinguish the playback device from other devices, typically to enforce per-screen business rule limits. If the app developer, in cooperation with the content vendor, does not require to distinguish the playback device, they can further enhance user privacy by making this identifier non-constant, using this option. In either case, apps are not allowed to store or use the FairPlay anonymized device ID for anything other than to enforce business rule limits. App developers must use the AppTrackingTransparency framework to disclose to users if the application or the related FairPlay Key Server collect data about end users and share it with other companies for purposes of tracking across apps and web sites. When true, the system generates a random seed with which the device id will be randomized. To override the seed used; use this property in conjunction with AVContentKeyRequestRandomDeviceIdentifierSeedKey to provide a seed generated by your application.

func AVContentKeySessionPendingExpiredSessionReportsWithAppIdentifierStorageDirectoryAtURL ¶

func AVContentKeySessionPendingExpiredSessionReportsWithAppIdentifierStorageDirectoryAtURL(appIdentifier *foundation.NSData, storageURL *foundation.NSURL) *foundation.NSArray[*foundation.NSData]

Provides "expired session reports" for prior AVContentKeySessions created with the specified app identifier that have expired either normally or abnormally. Note that no reports for sessions still in progress will be included. - Parameter appIdentifier: An opaque identifier for the application. The contents of this identifier depend on the particular protocol in use by the entity that controls the use of the media data. - Parameter storageURL: URL to a directory previously used with one or more instances of AVContentKeySession for the storage of expired session reports. - Returns: An NSArray containing instances of NSData, each containing a pending expired session report as a property-list serialization of an NSDictionary object. The contents of expired session reports depend on the particular protocol in use by the entity that controls the use of the media data.

func AVContentKeySessionRemovePendingExpiredSessionReportsWithAppIdentifierStorageDirectoryAtURL ¶

func AVContentKeySessionRemovePendingExpiredSessionReportsWithAppIdentifierStorageDirectoryAtURL(expiredSessionReports *foundation.NSArray[*foundation.NSData], appIdentifier *foundation.NSData, storageURL *foundation.NSURL)

Removes expired session reports for prior AVContentKeySessions from storage. Once they have been removed, they will no longer be available via subsequent invocations of +pendingExpiredSessionReportsWithAppIdentifier:. This method is most suitable for use only after the specified expired session reports have been sent to the entity that controls the use of the media data and the entity has acknowledged their receipt. - Parameter expiredSessionReports: An array of expired session reports to be discarded. - Parameter appIdentifier: An opaque identifier for the application. The contents of this identifier depend on the particular protocol in use by the entity that controls the use of the media data. - Parameter storageURL: URL to a writable folder.

func AVContentKeySessionServerPlaybackContextOptionProtocolVersions ¶

func AVContentKeySessionServerPlaybackContextOptionProtocolVersions() *foundation.NSString

Specifies the versions of the content protection protocol supported by the application; as an NSArray of one or more NSNumber objects. If this option is not set, an appropriate protocol version will be selected based on sideband information such as an associated HLS playlist. If such information is not available, a protocol version of 1 is assumed

func AVContentKeySessionServerPlaybackContextOptionServerChallenge ¶

func AVContentKeySessionServerPlaybackContextOptionServerChallenge() *foundation.NSString

Specifies a nonce as a 8-byte NSData object to be included in the secure server playback context (SPC) in order to prevent replay attacks. If not specified default server challenge of 0 is assumed.

func AVContentKeySystemAuthorizationToken ¶

func AVContentKeySystemAuthorizationToken() *foundation.NSString

Used to specify a token that could be used to authorize playback of associated content key recipients.

func AVContentKeySystemClearKey ¶

func AVContentKeySystemClearKey() *foundation.NSString

Used to specify clear key as the method of key delivery.

func AVContentKeySystemFairPlayStreaming ¶

func AVContentKeySystemFairPlayStreaming() *foundation.NSString

Used to specify FairPlay Streaming (FPS) as the method of key delivery.

func AVCoordinatedPlaybackSuspensionReasonAudioSessionInterrupted ¶

func AVCoordinatedPlaybackSuspensionReasonAudioSessionInterrupted() uintptr

The participant's audio session was interrupted.

func AVCoordinatedPlaybackSuspensionReasonCoordinatedPlaybackNotPossible ¶

func AVCoordinatedPlaybackSuspensionReasonCoordinatedPlaybackNotPossible() uintptr

The participant cannot participate in coordinated playback.

func AVCoordinatedPlaybackSuspensionReasonPlayingInterstitial ¶

func AVCoordinatedPlaybackSuspensionReasonPlayingInterstitial() uintptr

The participant is presented with interstitial content instead of the main player.

func AVCoordinatedPlaybackSuspensionReasonStallRecovery ¶

func AVCoordinatedPlaybackSuspensionReasonStallRecovery() uintptr

The player is buffering data after a stall.

func AVCoordinatedPlaybackSuspensionReasonUserActionRequired ¶

func AVCoordinatedPlaybackSuspensionReasonUserActionRequired() uintptr

The participant's playback object is in a state that requires manual intervention by the user to resume playback.

func AVCoordinatedPlaybackSuspensionReasonUserIsChangingCurrentTime ¶

func AVCoordinatedPlaybackSuspensionReasonUserIsChangingCurrentTime() uintptr

The participant is actively changing current time.

func AVCoreAnimationBeginTimeAtZero ¶

func AVCoreAnimationBeginTimeAtZero() float64

@constant AVCoreAnimationBeginTimeAtZero @discussion Use this constant to set the CoreAnimation's animation beginTime property to be time 0. The constant is a small, non-zero, positive value which avoids CoreAnimation from replacing 0.0 with CACurrentMediaTime().

func AVErrorDeviceKey ¶

func AVErrorDeviceKey() uintptr

func AVErrorDiscontinuityFlagsKey ¶

func AVErrorDiscontinuityFlagsKey() uintptr

func AVErrorFileSizeKey ¶

func AVErrorFileSizeKey() uintptr

func AVErrorFileTypeKey ¶

func AVErrorFileTypeKey() uintptr

func AVErrorMediaSubTypeKey ¶

func AVErrorMediaSubTypeKey() uintptr

func AVErrorMediaTypeKey ¶

func AVErrorMediaTypeKey() uintptr

func AVErrorPIDKey ¶

func AVErrorPIDKey() uintptr

func AVErrorPersistentTrackIDKey ¶

func AVErrorPersistentTrackIDKey() uintptr

func AVErrorPresentationTimeStampKey ¶

func AVErrorPresentationTimeStampKey() uintptr

func AVErrorRecordingSuccessfullyFinishedKey ¶

func AVErrorRecordingSuccessfullyFinishedKey() uintptr

func AVErrorTimeKey ¶

func AVErrorTimeKey() uintptr

func AVExternalStorageDeviceDiscoverySessionIsSupported ¶

func AVExternalStorageDeviceDiscoverySessionIsSupported() bool

@property supported @abstract Whether the external storage devices are supported by this device. @discussion A value of YES indicates that external storage devices are supported while NO indicates it is not.

func AVExternalStorageDeviceRequestAccessWithCompletionHandler ¶

func AVExternalStorageDeviceRequestAccessWithCompletionHandler(handler func(bool))

@method requestAccessWithCompletionHandler: @abstract Requests access to capture onto an external storage device connected to this device, showing a dialog to the user if necessary. @param handler A completion handler block called with the result of requesting access to capture onto an external storage device. @discussion Use this method to request access to capture onto an external storage device connected to this device. This call will not block while the user is being asked for access, allowing the client to continue running. Until access has been granted, trying to capture into detected external storage devices will result in an error. The user is only asked for permission the first time the client requests access, later calls use the authorization status selected by the user. The completion handler is called on an arbitrary dispatch queue. It is the client's responsibility to ensure that any UIKit-related updates are called on the main queue or main thread as a result.

func AVExternalSyncDeviceDiscoverySessionIsSupported ¶

func AVExternalSyncDeviceDiscoverySessionIsSupported() bool

Whether external sync devices are supported by this device. A value of `true` indicates that external sync devices are supported while `false` indicates they are not.

func AVFileType3GPP ¶

func AVFileType3GPP() *foundation.NSString

A UTI for the 3GPP file format. The value of this UTI is @"public.3gpp". Files are identified with the .3gp, .3gpp, and .sdv extensions.

func AVFileType3GPP2 ¶

func AVFileType3GPP2() *foundation.NSString

A UTI for the 3GPP file format. The value of this UTI is @"public.3gpp2". Files are identified with the .3g2, .3gp2 extensions.

func AVFileTypeAC3 ¶

func AVFileTypeAC3() *foundation.NSString

A UTI for the AC-3 audio file format. The value of this UTI is @"public.ac3-audio". Files are identified with the .ac3 extension.

func AVFileTypeAHAP ¶

func AVFileTypeAHAP() *foundation.NSString

A UTI for the Apple Haptics Audio Pattern file format. The value of this UTI is @"public.haptics-content". Files are identified with the .ahap extension.

func AVFileTypeAIFC ¶

func AVFileTypeAIFC() *foundation.NSString

A UTI for the AIFC audio file format. The value of this UTI is @"public.aifc-audio". Files are identified with the .aifc and .cdda extensions.

func AVFileTypeAIFF ¶

func AVFileTypeAIFF() *foundation.NSString

A UTI for the AIFF audio file format. The value of this UTI is @"public.aiff-audio". Files are identified with the .aif and .aiff extensions.

func AVFileTypeAMR ¶

func AVFileTypeAMR() *foundation.NSString

A UTI for the adaptive multi-rate audio file format. The value of this UTI is @"org.3gpp.adaptive-multi-rate-audio". Files are identified with the .amr extension.

func AVFileTypeAVCI ¶

func AVFileTypeAVCI() *foundation.NSString

A UTI for the high efficiency image file format containing H.264 compressed images. The value of this UTI is @"public.avci". Files are identified with the .avci extension.

func AVFileTypeAppleM4A ¶

func AVFileTypeAppleM4A() *foundation.NSString

The value of this UTI is @"com.apple.m4a-audio". Files are identified with the .m4a extension.

func AVFileTypeAppleM4V ¶

func AVFileTypeAppleM4V() *foundation.NSString

The value of this UTI is @"com.apple.m4v-video". Files are identified with the .m4v extension.

func AVFileTypeAppleiTT ¶

func AVFileTypeAppleiTT() *foundation.NSString

A UTI for the Apple iTT caption file format The value of this UTI is @"com.apple.itunes-timed-text". Files are identified with the .itt extension.

func AVFileTypeCoreAudioFormat ¶

func AVFileTypeCoreAudioFormat() *foundation.NSString

A UTI for the CoreAudio file format. The value of this UTI is @"com.apple.coreaudio-format". Files are identified with the .caf extension.

func AVFileTypeDICOM ¶

func AVFileTypeDICOM() *foundation.NSString

A UTI for the Digital Imaging and Communications in Medicine (DICOM) file format. The value of this UTI is @"org.nema.dicom". Files are identified with the .dcm extension.

func AVFileTypeDNG ¶

func AVFileTypeDNG() *foundation.NSString

A UTI for the Adobe digital negative file format. The value of this UTI is @"com.adobe.raw-image". Files are identified with the .dng extension.

func AVFileTypeEnhancedAC3 ¶

func AVFileTypeEnhancedAC3() *foundation.NSString

A UTI for the enhanced AC-3 audio file format. The value of this UTI is @"public.enhanced-ac3-audio". Files are identified with the .eac3 extension.

func AVFileTypeHEIC ¶

func AVFileTypeHEIC() *foundation.NSString

A UTI for the high efficiency image file format containing HEVC compressed images. The value of this UTI is @"public.heic". Files are identified with the .heic extension.

func AVFileTypeHEIF ¶

func AVFileTypeHEIF() *foundation.NSString

A UTI for the high efficiency image file format containing images compressed with any codec. The value of this UTI is @"public.heif". Files are identified with the .heif extension.

func AVFileTypeJPEG ¶

func AVFileTypeJPEG() *foundation.NSString

A UTI for the JPEG (JFIF) format. The value of this UTI is @"public.jpeg". Files are identified with the .jpg or .jpeg extension.

func AVFileTypeMPEG4 ¶

func AVFileTypeMPEG4() *foundation.NSString

A UTI for the MPEG-4 file format. The value of this UTI is @"public.mpeg-4". Files are identified with the .mp4 extension.

func AVFileTypeMPEGLayer3 ¶

func AVFileTypeMPEGLayer3() *foundation.NSString

A UTI for the MPEG layer 3 audio file format. The value of this UTI is @"public.mp3". Files are identified with the .mp3 extension.

func AVFileTypeProfileMPEG4AppleHLS ¶

func AVFileTypeProfileMPEG4AppleHLS() *foundation.NSString

Apple HTTP Live Streaming profile The profile that is suitable for Apple HTTP Live Streaming.

func AVFileTypeProfileMPEG4CMAFCompliant ¶

func AVFileTypeProfileMPEG4CMAFCompliant() *foundation.NSString

CMAF compliant profile The profile that is compliance with CMAF format.

func AVFileTypeQuickTimeAudio ¶

func AVFileTypeQuickTimeAudio() *foundation.NSString

A UTI for the QuickTime audio file format The value of this UTI is @"com.apple.quicktime-audio". Files are identified with the .qta extension.

func AVFileTypeQuickTimeMovie ¶

func AVFileTypeQuickTimeMovie() *foundation.NSString

A UTI for the QuickTime movie file format. The value of this UTI is @"com.apple.quicktime-movie". Files are identified with the .mov and .qt extensions.

func AVFileTypeSCC ¶

func AVFileTypeSCC() *foundation.NSString

A UTI for the Scenarist closed caption file format The value of this UTI is @"com.scenarist.closed-caption". Files are identified with the .scc extension.

func AVFileTypeSunAU ¶

func AVFileTypeSunAU() *foundation.NSString

A UTI for the Sun/NeXT audio file format. The value of this UTI is @"public.au-audio". Files are identified with the .au and .snd extensions.

func AVFileTypeTIFF ¶

func AVFileTypeTIFF() *foundation.NSString

A UTI for the tagged image file format. The value of this UTI is @"public.tiff". Files are identified with the .tiff or .tif extension.

func AVFileTypeWAVE ¶

func AVFileTypeWAVE() *foundation.NSString

A UTI for the WAVE audio file format. The value of this UTI is @"com.microsoft.waveform-audio". Files are identified with the .wav, .wave, and .bwf extensions.

func AVFoundationErrorDomain ¶

func AVFoundationErrorDomain() *foundation.NSString

func AVFragmentedMovieContainsMovieFragmentsDidChangeNotification ¶

func AVFragmentedMovieContainsMovieFragmentsDidChangeNotification() uintptr

@constant AVFragmentedMovieContainsMovieFragmentsDidChangeNotification @abstract Posted after the value of @"containsMovieFragments" has already been loaded and the AVFragmentedMovie is added to an AVFragmentedMovieMinder, either when 1) movie fragments are detected in the movie file on disk after it had previously contained none or when 2) no movie fragments are detected in the movie file on disk after it had previously contained one or more.

func AVFragmentedMovieDurationDidChangeNotification ¶

func AVFragmentedMovieDurationDidChangeNotification() uintptr

@constant AVFragmentedMovieDurationDidChangeNotification @abstract Posted when the duration of an AVFragmentedMovie changes while it's being minded by an AVFragmentedMovieMinder, but only for changes that occur after the status of the value of @"duration" has reached AVKeyValueStatusLoaded.

func AVFragmentedMovieTrackSegmentsDidChangeNotification ¶

func AVFragmentedMovieTrackSegmentsDidChangeNotification() uintptr

@constant AVFragmentedMovieTrackSegmentsDidChangeNotification @abstract Posted when the array of segments of an AVFragmentedMovieTrack changes while the associated instance of AVFragmentedMovie is being minded by an AVFragmentedMovieMinder, but only for changes that occur after the status of the value of @"segments" has reached AVKeyValueStatusLoaded.

func AVFragmentedMovieTrackTimeRangeDidChangeNotification ¶

func AVFragmentedMovieTrackTimeRangeDidChangeNotification() uintptr

@constant AVFragmentedMovieTrackTimeRangeDidChangeNotification @abstract Posted when the timeRange of an AVFragmentedMovieTrack changes while the associated instance of AVFragmentedMovie is being minded by an AVFragmentedMovieMinder, but only for changes that occur after the status of the value of @"timeRange" has reached AVKeyValueStatusLoaded.

func AVFragmentedMovieTrackTotalSampleDataLengthDidChangeNotification ¶

func AVFragmentedMovieTrackTotalSampleDataLengthDidChangeNotification() uintptr

@constant AVFragmentedMovieTrackTotalSampleDataLengthDidChangeNotification @discussion This notification name has been deprecated. Use either AVFragmentedMovieTrackTimeRangeDidChangeNotification or AVFragmentedMovieTrackSegmentsDidChangeNotification instead; in either case, you can assume that timing changes to fragmented tracks result in changes to the total length of the sample data used by the track. Deprecated: Upon receipt of either AVFragmentedMovieTrackTimeRangeDidChangeNotification or AVFragmentedMovieTrackSegmentsDidChangeNotification, you can assume that the sender's totalSampleDataLength has changed.

func AVFragmentedMovieWasDefragmentedNotification ¶

func AVFragmentedMovieWasDefragmentedNotification() uintptr

@constant AVFragmentedMovieWasDefragmentedNotification @abstract Posted when the movie file on disk is defragmented while an AVFragmentedMovie is being minded by an AVFragmentedMovieMinder, but only if the defragmentation occurs after the status of the value of @"canContainMovieFragments" has reached AVKeyValueStatusLoaded.

func AVLayerVideoGravityResize ¶

func AVLayerVideoGravityResize() *foundation.NSString

@constant AVLayerVideoGravityResize @abstract Stretch to fill layer bounds. @discussion AVLayerVideoGravityResize may be used when setting the videoGravity property of an AVPlayerLayer or AVCaptureVideoPreviewLayer instance.

func AVLayerVideoGravityResizeAspect ¶

func AVLayerVideoGravityResizeAspect() *foundation.NSString

@constant AVLayerVideoGravityResizeAspect @abstract Preserve aspect ratio; fit within layer bounds. @discussion AVLayerVideoGravityResizeAspect may be used when setting the videoGravity property of an AVPlayerLayer or AVCaptureVideoPreviewLayer instance.

func AVLayerVideoGravityResizeAspectFill ¶

func AVLayerVideoGravityResizeAspectFill() *foundation.NSString

@constant AVLayerVideoGravityResizeAspectFill @abstract Preserve aspect ratio; fill layer bounds. @discussion AVLayerVideoGravityResizeAspectFill may be used when setting the videoGravity property of an AVPlayerLayer or AVCaptureVideoPreviewLayer instance.

func AVMakeRectWithAspectRatioInsideRect ¶

func AVMakeRectWithAspectRatioInsideRect(aspectRatio corefoundation.CGSize, boundingRect corefoundation.CGRect) corefoundation.CGRect

func AVMediaCharacteristicAudible ¶

func AVMediaCharacteristicAudible() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes audible content. AVMediaTypeAudio is a media type with the characteristic AVMediaCharacteristicAudible. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicCarriesVideoStereoMetadata ¶

func AVMediaCharacteristicCarriesVideoStereoMetadata() *foundation.NSString

A media characteristic that indicates that the stereoscopic video track carries additional information related to the stereoscopic video. This is not an indication that the encoded video carries stereoscopic views. It instead indicates that it carries additional information that may influence the interpretation of those views and contribute to a better experience. The value of this characteristic is @“com.apple.quicktime.video.stereo-metadata". Note for content authors: the presence of this characteristic is strictly inferred from the format description of the associated track.

func AVMediaCharacteristicContainsAlphaChannel ¶

func AVMediaCharacteristicContainsAlphaChannel() *foundation.NSString

A media characteristic that indicates that a track contains an alpha channel. To determine whether alpha is straight or pre-multiplied, look for the format description extension with key kCMFormatDescriptionExtension_AlphaChannelMode.

func AVMediaCharacteristicContainsHDRVideo ¶

func AVMediaCharacteristicContainsHDRVideo() *foundation.NSString

A media characteristic that indicates that a track contains HDR video. HDR video contains extended dynamic range that requires explicit support when compositing. The value of this characteristic is @“public.contains-hdr-video". Note for content authors: the presence of this characteristic is strictly inferred from the format description of the associated track.

func AVMediaCharacteristicContainsOnlyForcedSubtitles ¶

func AVMediaCharacteristicContainsOnlyForcedSubtitles() *foundation.NSString

A media characteristic that indicates that a track or media selection option presents only forced subtitles. Media options with forced-only subtitles are typically selected when 1) the user has not selected a legible option with an accessibility characteristic or an auxiliary purpose and 2) its locale matches the locale of the selected audible media selection option. The value of this characteristic is @"public.subtitles.forced-only". Note for content authors: the presence of this characteristic for a legible media option may be inferred from the format description of the associated track that presents the subtitle media, if the format description carries sufficient information to indicate the presence or absence of forced and non-forced subtitles. If the format description does not carry this information, the legible media option can be explicitly tagged with the characteristic. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicContainsStereoMultiviewVideo ¶

func AVMediaCharacteristicContainsStereoMultiviewVideo() *foundation.NSString

A media characteristic that indicates that a track contains stereoscopic video captured in a multiview compression format. Stereoscopic video contains two views with one view for the left eye and one view for the right eye. Multiview video contains more than one view (not necessarily stereoscopic) in the same compressed video sample. The combination of stereoscopic and multiview indicates that multiview carriage is used to carry at least two stereoscopic views. It does not imply that there might not be more than two views. Access to the two stereo views may require opt-in to retrieve both views. Accessing only one of the left or right stereoscopic views as a fallback for playback or compositing where stereoscopic rendering is not supported may itself not be supported. The value of this characteristic is @“public.contains-stereo-multiview-video". Note for content authors: the presence of this characteristic is strictly inferred from the format description of the associated track.

func AVMediaCharacteristicDescribesMusicAndSoundForAccessibility ¶

func AVMediaCharacteristicDescribesMusicAndSoundForAccessibility() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes legible content in the language of its specified locale that: - describes music and - describes sound other than spoken dialog, such as sound effects and significant silences, occurring in program audio. Legible tracks provided for accessibility purposes are typically tagged both with this characteristic as well as with AVMediaCharacteristicTranscribesSpokenDialogForAccessibility. A legible track provided for accessibility purposes that's associated with an audio track without music and without sound other than spoken dialog -- lacking even significant silences -- can be tagged with this characteristic, because it trivially meets these requirements. The value of this characteristic is @"public.accessibility.describes-music-and-sound". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicDescribesMusicAndSoundForAccessibility only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicDescribesVideoForAccessibility ¶

func AVMediaCharacteristicDescribesVideoForAccessibility() *foundation.NSString

A media characteristic that indicates that a track or media selection option provides descriptions of the visual portion of the presentation that are sufficient to comprehend essential information that it depicts, such as action and setting. See -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:]. The value of this characteristic is @"public.accessibility.describes-video". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicDescribesVideoForAccessibility only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicDubbedTranslation ¶

func AVMediaCharacteristicDubbedTranslation() *foundation.NSString

A media characteristic that indicates that a track or media selection option contains a language or dialect translation of originally or previously produced content, created by substituting most or all of the dialog in a previous mix of audio content with dialog spoken in its designated language. Tracks to which this characteristic is assigned should typically also be assigned the characteristic AVMediaCharacteristicLanguageTranslation. See -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:]. The value of this characteristic is @"public.translation.dubbed". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicDubbedTranslation only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below.

func AVMediaCharacteristicEasyToRead ¶

func AVMediaCharacteristicEasyToRead() *foundation.NSString

A media characteristic that indicates that a track or media selection option provides legible content in the language of its specified locale that has been edited for ease of reading. The value of this characteristic is @"public.easy-to-read". Closed caption tracks that carry "easy reader" captions (per the CEA-608 specification) should be tagged with this characteristic. Subtitle tracks can also be tagged with this characteristic, where appropriate. Note for content authors: for QuickTime movie and .m4v files a track is considered to have the characteristic AVMediaCharacteristicEasyToRead only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicEnhancesSpeechIntelligibility ¶

func AVMediaCharacteristicEnhancesSpeechIntelligibility() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes audio that has been prepared or otherwise processed to heighten the intelligibility of speech. The value of this characteristic is @"public.accessibility.enhances-speech-intelligibility". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicEnhancesSpeechIntelligibility only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicFrameBased ¶

func AVMediaCharacteristicFrameBased() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes content that's frame-based. Frame-based content typically comprises discrete media samples that, once rendered, can remain current for indefinite periods of time without additional processing in support of "time-stretching". Further, any dependencies between samples are always explicitly signalled, so that the operations required to render any single sample can readily be performed on demand. AVMediaTypeVideo is the most common type of frame-based media. AVMediaTypeAudio is the most common counterexample. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicIndicatesHorizontalFieldOfView ¶

func AVMediaCharacteristicIndicatesHorizontalFieldOfView() *foundation.NSString

A media characteristic that indicates the video track carries information related to the horizontal field of view. This media characteristic is currently synthesized if the CMVideoFormatDescription includes a kCMFormatDescriptionExtension_HorizontalFieldOfView extension. This is not an indication that the field of view is expanded beyond or more narrow than typical horizontal fields of view. The value of this characteristic is @“public.indicates-horizontal-field-of-view". Note for content authors: the presence of this characteristic is strictly inferred from the format description of the associated track.

func AVMediaCharacteristicIndicatesNonRectilinearProjection ¶

func AVMediaCharacteristicIndicatesNonRectilinearProjection() *foundation.NSString

A media characteristic that indicates the video track carries information related to how it should be projected for display. This media characteristic is currently synthesized if the CMVideoFormatDescription specifies a non-rectilinear projection. To determine which kind of projection is indicated, look for the format description extension with key kCMFormatDescriptionExtension_ProjectionKind. The value of this characteristic is @“public.indicates-non-rectilinear-projection". Note for content authors: the presence of this characteristic is strictly inferred from the format description of the associated track.

func AVMediaCharacteristicIsAuxiliaryContent ¶

func AVMediaCharacteristicIsAuxiliaryContent() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes content that's marked by the content author as auxiliary to the presentation of the asset. The value of this characteristic is @"public.auxiliary-content". Example: an option that presents audio media containing commentary on the presentation would typically have this characteristic. Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicIsAuxiliaryContent if it's explicitly tagged with that characteristic or if, as a member of an alternate track group, its associated track is excluded from autoselection. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicIsMainProgramContent ¶

func AVMediaCharacteristicIsMainProgramContent() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes content that's marked by the content author as intrinsic to the presentation of the asset. Example: an option that presents the main program audio for the presentation, regardless of locale, would typically have this characteristic. The value of this characteristic is @"public.main-program-content". Note for content authors: the presence of this characteristic for a media option is inferred; any option that does not have the characteristic AVMediaCharacteristicIsAuxiliaryContent is considered to have the characteristic AVMediaCharacteristicIsMainProgramContent. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicIsOriginalContent ¶

func AVMediaCharacteristicIsOriginalContent() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes content that's marked by the content author as original to the principal production of the media, as opposed to supplementary or derivative content created by means of language translation or by other means. The value of this characteristic is @"public.original-content". Example: an option that presents audio media with dialog in the principal language of the production may be tagged with this characteristic; audio media containing dialog dubbed in a language other than the principal language of the production typically would not be tagged with this characteristic. Note for content authors: for QuickTime movie and .m4v files and for HTTP Live Streaming, a media option is considered to have the characteristic AVMediaCharacteristicIsOriginalContent only if it's explicitly tagged with the characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicLanguageTranslation ¶

func AVMediaCharacteristicLanguageTranslation() *foundation.NSString

A media characteristic that indicates that a track or media selection option contains a language or dialect translation of originally or previously produced content, intended to be used as a substitute for that content by users who prefer its designated language. See -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:]. The value of this characteristic is @"public.translation". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicLanguageTranslation only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below.

func AVMediaCharacteristicLegible ¶

func AVMediaCharacteristicLegible() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes legible content. AVMediaTypeSubtitle and AVMediaTypeClosedCaption are examples of media types with the characteristic AVMediaCharacteristicLegible. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicMachineGenerated ¶

func AVMediaCharacteristicMachineGenerated() *foundation.NSString

A media characteristic that indicates that a track was generated in an automated fashion by a machine. This media characteristic can be used to distinguish machine generated content from human authored content. The value of this characteristic is @“public.machine-generated". Note for content authors: for QuickTime movie and .m4v files and for HTTP Live Streaming, a media option is considered to have the characteristic AVMediaCharacteristicIsOriginalContent only if it's explicitly tagged with the characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicTactileMinimal ¶

func AVMediaCharacteristicTactileMinimal() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes haptic content that's marked by the content author as providing minimal tactile stimulation. Example: an option that presents low strength haptics feedback when user is actively attending the device, would typically have this characteristic. See -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:]. The value of this characteristic is @"public.haptics.minimal". Note for content authors: for QuickTime movie and MPEG-4 files a track is considered to have the characteristic AVMediaCharacteristicTactileMinimal only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below.

func AVMediaCharacteristicTranscribesSpokenDialogForAccessibility ¶

func AVMediaCharacteristicTranscribesSpokenDialogForAccessibility() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes legible content in the language of its specified locale that: - transcribes spoken dialog and - identifies speakers whenever other visual cues are insufficient for a viewer to determine who is speaking. Legible tracks provided for accessibility purposes are typically tagged both with this characteristic as well as with AVMediaCharacteristicDescribesMusicAndSoundForAccessibility. A legible track provided for accessibility purposes that's associated with an audio track that has no spoken dialog can be tagged with this characteristic, because it trivially meets these requirements. The value of this characteristic is @"public.accessibility.transcribes-spoken-dialog". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicTranscribesSpokenDialogForAccessibility only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicUsesWideGamutColorSpace ¶

func AVMediaCharacteristicUsesWideGamutColorSpace() *foundation.NSString

A media characteristic that indicates that a track uses a wide gamut color space and therefore may make use of colors that cannot be accurately represented otherwise. A wide color space such as AVVideo*_P3_D65 contains additional dynamic range that may benefit from special treatment when compositing. Care should be taken to avoid clamping. Non-wide spaces include AVVideo*_ITU_R_709_2 and AVVideo*_SMPTE_C.

func AVMediaCharacteristicVisual ¶

func AVMediaCharacteristicVisual() *foundation.NSString

A media characteristic that indicates that a track or media selection option includes visual content. AVMediaTypeVideo, AVMediaTypeSubtitle, AVMediaTypeClosedCaption are examples of media types with the characteristic AVMediaCharacteristicVisual. Also see -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:].

func AVMediaCharacteristicVoiceOverTranslation ¶

func AVMediaCharacteristicVoiceOverTranslation() *foundation.NSString

A media characteristic that indicates that a track or media selection option contains a language translation of originally or previously produced content, created by adding, in its designated language, a verbal interpretation of dialog and translations of other important information to a new mix of the audio content. Tracks to which this characteristic is assigned should typically also be assigned the characteristic AVMediaCharacteristicLanguageTranslation. See -[AVAssetTrack hasMediaCharacteristic:] and -[AVMediaSelectionOption hasMediaCharacteristic:]. The value of this characteristic is @"public.translation.voice-over". Note for content authors: for QuickTime movie and .m4v files a media option is considered to have the characteristic AVMediaCharacteristicVoiceOverTranslation only if it's explicitly tagged with that characteristic. See the discussion of the tagging of tracks with media characteristics below.

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayFilteredAndSortedAccordingToPreferredLanguages ¶

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayFilteredAndSortedAccordingToPreferredLanguages(mediaSelectionOptions *foundation.NSArray[*AVMediaSelectionOption], preferredLanguages *foundation.NSArray[*foundation.NSString]) *foundation.NSArray[*AVMediaSelectionOption]

Filters an array of AVMediaSelectionOptions according to whether their locales match any language identifier in the specified array of preferred languages. The returned array is sorted according to the order of preference of the language each matches. - Parameter mediaSelectionOptions: An array of AVMediaSelectionOptions to be filtered and sorted. - Parameter preferredLanguages: An array of language identifiers in order of preference, each of which is an IETF BCP 47 (RFC 4646) language identifier. If your goal is to provide the best match for the end user's preferred languages without consideration of your app's available localizations, pass [NSLocale preferredLanguages] as the value of preferredLanguages. However, if you want to filter the available choices in order to obtain the best match among the localizations that are available for your app, pass [NSBundle preferredLocalizationsFromArray:[[NSBundle mainBundle] localizations] forPreferences:[NSLocale preferredLanguages]] instead. The latter choice is normally more appropriate for strings intended for display as part of the app's UI. - Returns: An instance of NSArray containing media selection options of the specified NSArray that match a preferred language, sorted according to the order of preference of the language each matches.

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayWithLocale ¶

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayWithLocale(mediaSelectionOptions *foundation.NSArray[*AVMediaSelectionOption], locale *foundation.NSLocale) *foundation.NSArray[*AVMediaSelectionOption]

Filters an array of AVMediaSelectionOptions according to locale. - Parameter mediaSelectionOptions: An array of AVMediaSelectionOption to be filtered by locale. - Parameter locale: The NSLocale that must be matched for a media selection option to be copied to the output array. - Returns: An instance of NSArray containing the media selection options of the specified NSArray that match the specified locale.

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayWithMediaCharacteristics ¶

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayWithMediaCharacteristics(mediaSelectionOptions *foundation.NSArray[*AVMediaSelectionOption], mediaCharacteristics *foundation.NSArray[*foundation.NSString]) *foundation.NSArray[*AVMediaSelectionOption]

Filters an array of AVMediaSelectionOptions according to one or more media characteristics. - Parameter mediaSelectionOptions: An array of AVMediaSelectionOptions to be filtered by media characteristic. - Parameter mediaCharacteristics: The media characteristics that must be matched for a media selection option to be copied to the output array. - Returns: An instance of NSArray containing the media selection options of the specified NSArray that match the specified media characteristics.

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayWithoutMediaCharacteristics ¶

func AVMediaSelectionGroupMediaSelectionOptionsFromArrayWithoutMediaCharacteristics(mediaSelectionOptions *foundation.NSArray[*AVMediaSelectionOption], mediaCharacteristics *foundation.NSArray[*foundation.NSString]) *foundation.NSArray[*AVMediaSelectionOption]

Filters an array of AVMediaSelectionOptions according to whether they lack one or more media characteristics. - Parameter mediaSelectionOptions: An array of AVMediaSelectionOptions to be filtered by media characteristic. - Parameter mediaCharacteristics: The media characteristics that must not be present for a media selection option to be copied to the output array. - Returns: An instance of NSArray containing the media selection options of the specified NSArray that lack the specified media characteristics.

func AVMediaSelectionGroupPlayableMediaSelectionOptionsFromArray ¶

func AVMediaSelectionGroupPlayableMediaSelectionOptionsFromArray(mediaSelectionOptions *foundation.NSArray[*AVMediaSelectionOption]) *foundation.NSArray[*AVMediaSelectionOption]

Filters an array of AVMediaSelectionOptions according to whether they are playable. - Parameter mediaSelectionOptions: An array of AVMediaSelectionOption to be filtered according to whether they are playable. - Returns: An instance of NSArray containing the media selection options of the specified NSArray that are playable.

func AVMediaTypeAudio ¶

func AVMediaTypeAudio() *foundation.NSString

func AVMediaTypeAuxiliaryPicture ¶

func AVMediaTypeAuxiliaryPicture() *foundation.NSString

This media type is used only to identify the track type. An Auxiliary Picture track is not intended to be displayed; as such, the track_in_movie flag in TrackHeaderBox of these tracks will be 0. A track with this media type contain video samples the media type of the format description of which is AVMediaTypeVideo.

func AVMediaTypeClosedCaption ¶

func AVMediaTypeClosedCaption() *foundation.NSString

func AVMediaTypeDepthData ¶

func AVMediaTypeDepthData() *foundation.NSString

func AVMediaTypeHaptic ¶

func AVMediaTypeHaptic() *foundation.NSString

func AVMediaTypeMetadata ¶

func AVMediaTypeMetadata() *foundation.NSString

func AVMediaTypeMuxed ¶

func AVMediaTypeMuxed() *foundation.NSString

func AVMediaTypeSubtitle ¶

func AVMediaTypeSubtitle() *foundation.NSString

func AVMediaTypeText ¶

func AVMediaTypeText() *foundation.NSString

func AVMediaTypeTimecode ¶

func AVMediaTypeTimecode() *foundation.NSString

func AVMediaTypeVideo ¶

func AVMediaTypeVideo() *foundation.NSString

func AVMetadata3GPUserDataKeyAlbumAndTrack ¶

func AVMetadata3GPUserDataKeyAlbumAndTrack() *foundation.NSString

func AVMetadata3GPUserDataKeyAuthor ¶

func AVMetadata3GPUserDataKeyAuthor() *foundation.NSString

func AVMetadata3GPUserDataKeyCollection ¶

func AVMetadata3GPUserDataKeyCollection() *foundation.NSString

func AVMetadata3GPUserDataKeyCopyright ¶

func AVMetadata3GPUserDataKeyCopyright() *foundation.NSString

func AVMetadata3GPUserDataKeyDescription ¶

func AVMetadata3GPUserDataKeyDescription() *foundation.NSString

func AVMetadata3GPUserDataKeyGenre ¶

func AVMetadata3GPUserDataKeyGenre() *foundation.NSString

func AVMetadata3GPUserDataKeyKeywordList ¶

func AVMetadata3GPUserDataKeyKeywordList() *foundation.NSString

func AVMetadata3GPUserDataKeyLocation ¶

func AVMetadata3GPUserDataKeyLocation() *foundation.NSString

func AVMetadata3GPUserDataKeyMediaClassification ¶

func AVMetadata3GPUserDataKeyMediaClassification() *foundation.NSString

func AVMetadata3GPUserDataKeyMediaRating ¶

func AVMetadata3GPUserDataKeyMediaRating() *foundation.NSString

func AVMetadata3GPUserDataKeyPerformer ¶

func AVMetadata3GPUserDataKeyPerformer() *foundation.NSString

func AVMetadata3GPUserDataKeyRecordingYear ¶

func AVMetadata3GPUserDataKeyRecordingYear() *foundation.NSString

func AVMetadata3GPUserDataKeyThumbnail ¶

func AVMetadata3GPUserDataKeyThumbnail() *foundation.NSString

func AVMetadata3GPUserDataKeyTitle ¶

func AVMetadata3GPUserDataKeyTitle() *foundation.NSString

func AVMetadata3GPUserDataKeyUserRating ¶

func AVMetadata3GPUserDataKeyUserRating() *foundation.NSString

func AVMetadataCommonIdentifierAccessibilityDescription ¶

func AVMetadataCommonIdentifierAccessibilityDescription() *foundation.NSString

func AVMetadataCommonIdentifierAlbumName ¶

func AVMetadataCommonIdentifierAlbumName() *foundation.NSString

func AVMetadataCommonIdentifierArtist ¶

func AVMetadataCommonIdentifierArtist() *foundation.NSString

func AVMetadataCommonIdentifierArtwork ¶

func AVMetadataCommonIdentifierArtwork() *foundation.NSString

func AVMetadataCommonIdentifierAssetIdentifier ¶

func AVMetadataCommonIdentifierAssetIdentifier() *foundation.NSString

func AVMetadataCommonIdentifierAuthor ¶

func AVMetadataCommonIdentifierAuthor() *foundation.NSString

func AVMetadataCommonIdentifierContributor ¶

func AVMetadataCommonIdentifierContributor() *foundation.NSString

func AVMetadataCommonIdentifierCopyrights ¶

func AVMetadataCommonIdentifierCopyrights() *foundation.NSString

func AVMetadataCommonIdentifierCreationDate ¶

func AVMetadataCommonIdentifierCreationDate() *foundation.NSString

func AVMetadataCommonIdentifierCreator ¶

func AVMetadataCommonIdentifierCreator() *foundation.NSString

func AVMetadataCommonIdentifierDescription ¶

func AVMetadataCommonIdentifierDescription() *foundation.NSString

func AVMetadataCommonIdentifierFormat ¶

func AVMetadataCommonIdentifierFormat() *foundation.NSString

func AVMetadataCommonIdentifierLanguage ¶

func AVMetadataCommonIdentifierLanguage() *foundation.NSString

func AVMetadataCommonIdentifierLastModifiedDate ¶

func AVMetadataCommonIdentifierLastModifiedDate() *foundation.NSString

func AVMetadataCommonIdentifierLocation ¶

func AVMetadataCommonIdentifierLocation() *foundation.NSString

func AVMetadataCommonIdentifierMake ¶

func AVMetadataCommonIdentifierMake() *foundation.NSString

func AVMetadataCommonIdentifierModel ¶

func AVMetadataCommonIdentifierModel() *foundation.NSString

func AVMetadataCommonIdentifierPublisher ¶

func AVMetadataCommonIdentifierPublisher() *foundation.NSString

func AVMetadataCommonIdentifierRelation ¶

func AVMetadataCommonIdentifierRelation() *foundation.NSString

func AVMetadataCommonIdentifierSoftware ¶

func AVMetadataCommonIdentifierSoftware() *foundation.NSString

func AVMetadataCommonIdentifierSource ¶

func AVMetadataCommonIdentifierSource() *foundation.NSString

func AVMetadataCommonIdentifierSubject ¶

func AVMetadataCommonIdentifierSubject() *foundation.NSString

func AVMetadataCommonIdentifierTitle ¶

func AVMetadataCommonIdentifierTitle() *foundation.NSString

func AVMetadataCommonIdentifierType ¶

func AVMetadataCommonIdentifierType() *foundation.NSString

func AVMetadataCommonKeyAccessibilityDescription ¶

func AVMetadataCommonKeyAccessibilityDescription() *foundation.NSString

func AVMetadataCommonKeyAlbumName ¶

func AVMetadataCommonKeyAlbumName() *foundation.NSString

func AVMetadataCommonKeyArtist ¶

func AVMetadataCommonKeyArtist() *foundation.NSString

func AVMetadataCommonKeyArtwork ¶

func AVMetadataCommonKeyArtwork() *foundation.NSString

func AVMetadataCommonKeyAuthor ¶

func AVMetadataCommonKeyAuthor() *foundation.NSString

func AVMetadataCommonKeyContributor ¶

func AVMetadataCommonKeyContributor() *foundation.NSString

func AVMetadataCommonKeyCopyrights ¶

func AVMetadataCommonKeyCopyrights() *foundation.NSString

func AVMetadataCommonKeyCreationDate ¶

func AVMetadataCommonKeyCreationDate() *foundation.NSString

func AVMetadataCommonKeyCreator ¶

func AVMetadataCommonKeyCreator() *foundation.NSString

func AVMetadataCommonKeyDescription ¶

func AVMetadataCommonKeyDescription() *foundation.NSString

func AVMetadataCommonKeyFormat ¶

func AVMetadataCommonKeyFormat() *foundation.NSString

func AVMetadataCommonKeyIdentifier ¶

func AVMetadataCommonKeyIdentifier() *foundation.NSString

func AVMetadataCommonKeyLanguage ¶

func AVMetadataCommonKeyLanguage() *foundation.NSString

func AVMetadataCommonKeyLastModifiedDate ¶

func AVMetadataCommonKeyLastModifiedDate() *foundation.NSString

func AVMetadataCommonKeyLocation ¶

func AVMetadataCommonKeyLocation() *foundation.NSString

func AVMetadataCommonKeyMake ¶

func AVMetadataCommonKeyMake() *foundation.NSString

func AVMetadataCommonKeyModel ¶

func AVMetadataCommonKeyModel() *foundation.NSString

func AVMetadataCommonKeyPublisher ¶

func AVMetadataCommonKeyPublisher() *foundation.NSString

func AVMetadataCommonKeyRelation ¶

func AVMetadataCommonKeyRelation() *foundation.NSString

func AVMetadataCommonKeySoftware ¶

func AVMetadataCommonKeySoftware() *foundation.NSString

func AVMetadataCommonKeySource ¶

func AVMetadataCommonKeySource() *foundation.NSString

func AVMetadataCommonKeySubject ¶

func AVMetadataCommonKeySubject() *foundation.NSString

func AVMetadataCommonKeyTitle ¶

func AVMetadataCommonKeyTitle() *foundation.NSString

func AVMetadataCommonKeyType ¶

func AVMetadataCommonKeyType() *foundation.NSString

func AVMetadataExtraAttributeBaseURIKey ¶

func AVMetadataExtraAttributeBaseURIKey() *foundation.NSString

When present in an item's extraAttributes dictionary, identifies the base URI against which other URIs related to the item are to be resolved, e.g. AVMetadataExtraAttributeValueURIKey. Values for this key are of type NSString.

func AVMetadataExtraAttributeInfoKey ¶

func AVMetadataExtraAttributeInfoKey() *foundation.NSString

More information about the item; specific to the item keySpace & key. For example, this key is used with the following ID3 tags: TXXX, WXXX, APIC, GEOB: carries the Description PRIV: carries the Owner Identifier

func AVMetadataExtraAttributeValueURIKey ¶

func AVMetadataExtraAttributeValueURIKey() *foundation.NSString

When present in an item's extraAttributes dictionary, identifies the resource to be used as the item's value. Values for this key are of type NSString.

func AVMetadataFormatHLSMetadata ¶

func AVMetadataFormatHLSMetadata() *foundation.NSString

HTTP Live Streaming metadata

func AVMetadataFormatID3Metadata ¶

func AVMetadataFormatID3Metadata() *foundation.NSString

func AVMetadataFormatISOUserData ¶

func AVMetadataFormatISOUserData() *foundation.NSString

func AVMetadataFormatQuickTimeMetadata ¶

func AVMetadataFormatQuickTimeMetadata() *foundation.NSString

func AVMetadataFormatQuickTimeUserData ¶

func AVMetadataFormatQuickTimeUserData() *foundation.NSString

func AVMetadataFormatUnknown ¶

func AVMetadataFormatUnknown() *foundation.NSString

Metadata format for AVMetadataItems of unknown provenance. This can occur when metadata is provided generically by an intermediate interface, such as AudioToolbox's AudioFile interface.

func AVMetadataFormatiTunesMetadata ¶

func AVMetadataFormatiTunesMetadata() *foundation.NSString

func AVMetadataID3MetadataKeyAlbumSortOrder ¶

func AVMetadataID3MetadataKeyAlbumSortOrder() *foundation.NSString

func AVMetadataID3MetadataKeyAlbumTitle ¶

func AVMetadataID3MetadataKeyAlbumTitle() *foundation.NSString

func AVMetadataID3MetadataKeyAttachedPicture ¶

func AVMetadataID3MetadataKeyAttachedPicture() *foundation.NSString

func AVMetadataID3MetadataKeyAudioEncryption ¶

func AVMetadataID3MetadataKeyAudioEncryption() *foundation.NSString

func AVMetadataID3MetadataKeyAudioSeekPointIndex ¶

func AVMetadataID3MetadataKeyAudioSeekPointIndex() *foundation.NSString

func AVMetadataID3MetadataKeyBand ¶

func AVMetadataID3MetadataKeyBand() *foundation.NSString

func AVMetadataID3MetadataKeyBeatsPerMinute ¶

func AVMetadataID3MetadataKeyBeatsPerMinute() *foundation.NSString

func AVMetadataID3MetadataKeyComments ¶

func AVMetadataID3MetadataKeyComments() *foundation.NSString

func AVMetadataID3MetadataKeyCommercial ¶

func AVMetadataID3MetadataKeyCommercial() *foundation.NSString

func AVMetadataID3MetadataKeyCommercialInformation ¶

func AVMetadataID3MetadataKeyCommercialInformation() *foundation.NSString

func AVMetadataID3MetadataKeyCommerical deprecated

func AVMetadataID3MetadataKeyCommerical() *foundation.NSString

Deprecated: since macOS 10.11.

func AVMetadataID3MetadataKeyComposer ¶

func AVMetadataID3MetadataKeyComposer() *foundation.NSString

func AVMetadataID3MetadataKeyConductor ¶

func AVMetadataID3MetadataKeyConductor() *foundation.NSString

func AVMetadataID3MetadataKeyContentGroupDescription ¶

func AVMetadataID3MetadataKeyContentGroupDescription() *foundation.NSString

func AVMetadataID3MetadataKeyContentType ¶

func AVMetadataID3MetadataKeyContentType() *foundation.NSString

func AVMetadataID3MetadataKeyCopyright ¶

func AVMetadataID3MetadataKeyCopyright() *foundation.NSString

func AVMetadataID3MetadataKeyCopyrightInformation ¶

func AVMetadataID3MetadataKeyCopyrightInformation() *foundation.NSString

func AVMetadataID3MetadataKeyDate ¶

func AVMetadataID3MetadataKeyDate() *foundation.NSString

func AVMetadataID3MetadataKeyEncodedBy ¶

func AVMetadataID3MetadataKeyEncodedBy() *foundation.NSString

func AVMetadataID3MetadataKeyEncodedWith ¶

func AVMetadataID3MetadataKeyEncodedWith() *foundation.NSString

func AVMetadataID3MetadataKeyEncodingTime ¶

func AVMetadataID3MetadataKeyEncodingTime() *foundation.NSString

func AVMetadataID3MetadataKeyEncryption ¶

func AVMetadataID3MetadataKeyEncryption() *foundation.NSString

func AVMetadataID3MetadataKeyEqualization ¶

func AVMetadataID3MetadataKeyEqualization() *foundation.NSString

func AVMetadataID3MetadataKeyEqualization2 ¶

func AVMetadataID3MetadataKeyEqualization2() *foundation.NSString

func AVMetadataID3MetadataKeyEventTimingCodes ¶

func AVMetadataID3MetadataKeyEventTimingCodes() *foundation.NSString

func AVMetadataID3MetadataKeyFileOwner ¶

func AVMetadataID3MetadataKeyFileOwner() *foundation.NSString

func AVMetadataID3MetadataKeyFileType ¶

func AVMetadataID3MetadataKeyFileType() *foundation.NSString

func AVMetadataID3MetadataKeyGeneralEncapsulatedObject ¶

func AVMetadataID3MetadataKeyGeneralEncapsulatedObject() *foundation.NSString

func AVMetadataID3MetadataKeyGroupIdentifier ¶

func AVMetadataID3MetadataKeyGroupIdentifier() *foundation.NSString

func AVMetadataID3MetadataKeyInitialKey ¶

func AVMetadataID3MetadataKeyInitialKey() *foundation.NSString

func AVMetadataID3MetadataKeyInternationalStandardRecordingCode ¶

func AVMetadataID3MetadataKeyInternationalStandardRecordingCode() *foundation.NSString

func AVMetadataID3MetadataKeyInternetRadioStationName ¶

func AVMetadataID3MetadataKeyInternetRadioStationName() *foundation.NSString

func AVMetadataID3MetadataKeyInternetRadioStationOwner ¶

func AVMetadataID3MetadataKeyInternetRadioStationOwner() *foundation.NSString

func AVMetadataID3MetadataKeyInvolvedPeopleList_v23 ¶

func AVMetadataID3MetadataKeyInvolvedPeopleList_v23() *foundation.NSString

func AVMetadataID3MetadataKeyInvolvedPeopleList_v24 ¶

func AVMetadataID3MetadataKeyInvolvedPeopleList_v24() *foundation.NSString

func AVMetadataID3MetadataKeyLanguage ¶

func AVMetadataID3MetadataKeyLanguage() *foundation.NSString

func AVMetadataID3MetadataKeyLeadPerformer ¶

func AVMetadataID3MetadataKeyLeadPerformer() *foundation.NSString

func AVMetadataID3MetadataKeyLength ¶

func AVMetadataID3MetadataKeyLength() *foundation.NSString
func AVMetadataID3MetadataKeyLink() *foundation.NSString

func AVMetadataID3MetadataKeyLyricist ¶

func AVMetadataID3MetadataKeyLyricist() *foundation.NSString

func AVMetadataID3MetadataKeyMPEGLocationLookupTable ¶

func AVMetadataID3MetadataKeyMPEGLocationLookupTable() *foundation.NSString

func AVMetadataID3MetadataKeyMediaType ¶

func AVMetadataID3MetadataKeyMediaType() *foundation.NSString

func AVMetadataID3MetadataKeyModifiedBy ¶

func AVMetadataID3MetadataKeyModifiedBy() *foundation.NSString

func AVMetadataID3MetadataKeyMood ¶

func AVMetadataID3MetadataKeyMood() *foundation.NSString

func AVMetadataID3MetadataKeyMusicCDIdentifier ¶

func AVMetadataID3MetadataKeyMusicCDIdentifier() *foundation.NSString

func AVMetadataID3MetadataKeyMusicianCreditsList ¶

func AVMetadataID3MetadataKeyMusicianCreditsList() *foundation.NSString

func AVMetadataID3MetadataKeyOfficialArtistWebpage ¶

func AVMetadataID3MetadataKeyOfficialArtistWebpage() *foundation.NSString

func AVMetadataID3MetadataKeyOfficialAudioFileWebpage ¶

func AVMetadataID3MetadataKeyOfficialAudioFileWebpage() *foundation.NSString

func AVMetadataID3MetadataKeyOfficialAudioSourceWebpage ¶

func AVMetadataID3MetadataKeyOfficialAudioSourceWebpage() *foundation.NSString

func AVMetadataID3MetadataKeyOfficialInternetRadioStationHomepage ¶

func AVMetadataID3MetadataKeyOfficialInternetRadioStationHomepage() *foundation.NSString

func AVMetadataID3MetadataKeyOfficialPublisherWebpage ¶

func AVMetadataID3MetadataKeyOfficialPublisherWebpage() *foundation.NSString

func AVMetadataID3MetadataKeyOriginalAlbumTitle ¶

func AVMetadataID3MetadataKeyOriginalAlbumTitle() *foundation.NSString

func AVMetadataID3MetadataKeyOriginalArtist ¶

func AVMetadataID3MetadataKeyOriginalArtist() *foundation.NSString

func AVMetadataID3MetadataKeyOriginalFilename ¶

func AVMetadataID3MetadataKeyOriginalFilename() *foundation.NSString

func AVMetadataID3MetadataKeyOriginalLyricist ¶

func AVMetadataID3MetadataKeyOriginalLyricist() *foundation.NSString

func AVMetadataID3MetadataKeyOriginalReleaseTime ¶

func AVMetadataID3MetadataKeyOriginalReleaseTime() *foundation.NSString

func AVMetadataID3MetadataKeyOriginalReleaseYear ¶

func AVMetadataID3MetadataKeyOriginalReleaseYear() *foundation.NSString

func AVMetadataID3MetadataKeyOwnership ¶

func AVMetadataID3MetadataKeyOwnership() *foundation.NSString

func AVMetadataID3MetadataKeyPartOfASet ¶

func AVMetadataID3MetadataKeyPartOfASet() *foundation.NSString

func AVMetadataID3MetadataKeyPayment ¶

func AVMetadataID3MetadataKeyPayment() *foundation.NSString

func AVMetadataID3MetadataKeyPerformerSortOrder ¶

func AVMetadataID3MetadataKeyPerformerSortOrder() *foundation.NSString

func AVMetadataID3MetadataKeyPlayCounter ¶

func AVMetadataID3MetadataKeyPlayCounter() *foundation.NSString

func AVMetadataID3MetadataKeyPlaylistDelay ¶

func AVMetadataID3MetadataKeyPlaylistDelay() *foundation.NSString

func AVMetadataID3MetadataKeyPopularimeter ¶

func AVMetadataID3MetadataKeyPopularimeter() *foundation.NSString

func AVMetadataID3MetadataKeyPositionSynchronization ¶

func AVMetadataID3MetadataKeyPositionSynchronization() *foundation.NSString

func AVMetadataID3MetadataKeyPrivate ¶

func AVMetadataID3MetadataKeyPrivate() *foundation.NSString

func AVMetadataID3MetadataKeyProducedNotice ¶

func AVMetadataID3MetadataKeyProducedNotice() *foundation.NSString

func AVMetadataID3MetadataKeyPublisher ¶

func AVMetadataID3MetadataKeyPublisher() *foundation.NSString

func AVMetadataID3MetadataKeyRecommendedBufferSize ¶

func AVMetadataID3MetadataKeyRecommendedBufferSize() *foundation.NSString

func AVMetadataID3MetadataKeyRecordingDates ¶

func AVMetadataID3MetadataKeyRecordingDates() *foundation.NSString

func AVMetadataID3MetadataKeyRecordingTime ¶

func AVMetadataID3MetadataKeyRecordingTime() *foundation.NSString

func AVMetadataID3MetadataKeyRelativeVolumeAdjustment ¶

func AVMetadataID3MetadataKeyRelativeVolumeAdjustment() *foundation.NSString

func AVMetadataID3MetadataKeyRelativeVolumeAdjustment2 ¶

func AVMetadataID3MetadataKeyRelativeVolumeAdjustment2() *foundation.NSString

func AVMetadataID3MetadataKeyReleaseTime ¶

func AVMetadataID3MetadataKeyReleaseTime() *foundation.NSString

func AVMetadataID3MetadataKeyReverb ¶

func AVMetadataID3MetadataKeyReverb() *foundation.NSString

func AVMetadataID3MetadataKeySeek ¶

func AVMetadataID3MetadataKeySeek() *foundation.NSString

func AVMetadataID3MetadataKeySetSubtitle ¶

func AVMetadataID3MetadataKeySetSubtitle() *foundation.NSString

func AVMetadataID3MetadataKeySignature ¶

func AVMetadataID3MetadataKeySignature() *foundation.NSString

func AVMetadataID3MetadataKeySize ¶

func AVMetadataID3MetadataKeySize() *foundation.NSString

func AVMetadataID3MetadataKeySubTitle ¶

func AVMetadataID3MetadataKeySubTitle() *foundation.NSString

func AVMetadataID3MetadataKeySynchronizedLyric ¶

func AVMetadataID3MetadataKeySynchronizedLyric() *foundation.NSString

func AVMetadataID3MetadataKeySynchronizedTempoCodes ¶

func AVMetadataID3MetadataKeySynchronizedTempoCodes() *foundation.NSString

func AVMetadataID3MetadataKeyTaggingTime ¶

func AVMetadataID3MetadataKeyTaggingTime() *foundation.NSString

func AVMetadataID3MetadataKeyTermsOfUse ¶

func AVMetadataID3MetadataKeyTermsOfUse() *foundation.NSString

func AVMetadataID3MetadataKeyTime ¶

func AVMetadataID3MetadataKeyTime() *foundation.NSString

func AVMetadataID3MetadataKeyTitleDescription ¶

func AVMetadataID3MetadataKeyTitleDescription() *foundation.NSString

func AVMetadataID3MetadataKeyTitleSortOrder ¶

func AVMetadataID3MetadataKeyTitleSortOrder() *foundation.NSString

func AVMetadataID3MetadataKeyTrackNumber ¶

func AVMetadataID3MetadataKeyTrackNumber() *foundation.NSString

func AVMetadataID3MetadataKeyUniqueFileIdentifier ¶

func AVMetadataID3MetadataKeyUniqueFileIdentifier() *foundation.NSString

func AVMetadataID3MetadataKeyUnsynchronizedLyric ¶

func AVMetadataID3MetadataKeyUnsynchronizedLyric() *foundation.NSString

func AVMetadataID3MetadataKeyUserText ¶

func AVMetadataID3MetadataKeyUserText() *foundation.NSString

func AVMetadataID3MetadataKeyUserURL ¶

func AVMetadataID3MetadataKeyUserURL() *foundation.NSString

func AVMetadataID3MetadataKeyYear ¶

func AVMetadataID3MetadataKeyYear() *foundation.NSString

func AVMetadataISOUserDataKeyAccessibilityDescription ¶

func AVMetadataISOUserDataKeyAccessibilityDescription() *foundation.NSString

func AVMetadataISOUserDataKeyCopyright ¶

func AVMetadataISOUserDataKeyCopyright() *foundation.NSString

func AVMetadataISOUserDataKeyDate ¶

func AVMetadataISOUserDataKeyDate() *foundation.NSString

ISO User data key for the content creation date/time. The value is date and time, formatted according to ISO 8601, when the content was created. For clips captured by recording devices, this is typically the date and time when the clip’s recording started. When stored in AV(Mutable)MetadataItem, the value type must be either NSDate or NSString. When NSString is used, the value uses one of ISO 8601 formats such as "2016-01-11T17:31:10Z".

func AVMetadataISOUserDataKeyTaggedCharacteristic ¶

func AVMetadataISOUserDataKeyTaggedCharacteristic() *foundation.NSString

func AVMetadataIcyMetadataKeyStreamTitle ¶

func AVMetadataIcyMetadataKeyStreamTitle() *foundation.NSString

func AVMetadataIcyMetadataKeyStreamURL ¶

func AVMetadataIcyMetadataKeyStreamURL() *foundation.NSString

func AVMetadataIdentifier3GPUserDataAlbumAndTrack ¶

func AVMetadataIdentifier3GPUserDataAlbumAndTrack() *foundation.NSString

func AVMetadataIdentifier3GPUserDataAuthor ¶

func AVMetadataIdentifier3GPUserDataAuthor() *foundation.NSString

func AVMetadataIdentifier3GPUserDataCollection ¶

func AVMetadataIdentifier3GPUserDataCollection() *foundation.NSString

func AVMetadataIdentifier3GPUserDataCopyright ¶

func AVMetadataIdentifier3GPUserDataCopyright() *foundation.NSString

func AVMetadataIdentifier3GPUserDataDescription ¶

func AVMetadataIdentifier3GPUserDataDescription() *foundation.NSString

func AVMetadataIdentifier3GPUserDataGenre ¶

func AVMetadataIdentifier3GPUserDataGenre() *foundation.NSString

func AVMetadataIdentifier3GPUserDataKeywordList ¶

func AVMetadataIdentifier3GPUserDataKeywordList() *foundation.NSString

func AVMetadataIdentifier3GPUserDataLocation ¶

func AVMetadataIdentifier3GPUserDataLocation() *foundation.NSString

func AVMetadataIdentifier3GPUserDataMediaClassification ¶

func AVMetadataIdentifier3GPUserDataMediaClassification() *foundation.NSString

func AVMetadataIdentifier3GPUserDataMediaRating ¶

func AVMetadataIdentifier3GPUserDataMediaRating() *foundation.NSString

func AVMetadataIdentifier3GPUserDataPerformer ¶

func AVMetadataIdentifier3GPUserDataPerformer() *foundation.NSString

func AVMetadataIdentifier3GPUserDataRecordingYear ¶

func AVMetadataIdentifier3GPUserDataRecordingYear() *foundation.NSString

func AVMetadataIdentifier3GPUserDataThumbnail ¶

func AVMetadataIdentifier3GPUserDataThumbnail() *foundation.NSString

func AVMetadataIdentifier3GPUserDataTitle ¶

func AVMetadataIdentifier3GPUserDataTitle() *foundation.NSString

func AVMetadataIdentifier3GPUserDataUserRating ¶

func AVMetadataIdentifier3GPUserDataUserRating() *foundation.NSString

func AVMetadataIdentifierID3MetadataAlbumSortOrder ¶

func AVMetadataIdentifierID3MetadataAlbumSortOrder() *foundation.NSString

func AVMetadataIdentifierID3MetadataAlbumTitle ¶

func AVMetadataIdentifierID3MetadataAlbumTitle() *foundation.NSString

func AVMetadataIdentifierID3MetadataAttachedPicture ¶

func AVMetadataIdentifierID3MetadataAttachedPicture() *foundation.NSString

func AVMetadataIdentifierID3MetadataAudioEncryption ¶

func AVMetadataIdentifierID3MetadataAudioEncryption() *foundation.NSString

func AVMetadataIdentifierID3MetadataAudioSeekPointIndex ¶

func AVMetadataIdentifierID3MetadataAudioSeekPointIndex() *foundation.NSString

func AVMetadataIdentifierID3MetadataBand ¶

func AVMetadataIdentifierID3MetadataBand() *foundation.NSString

func AVMetadataIdentifierID3MetadataBeatsPerMinute ¶

func AVMetadataIdentifierID3MetadataBeatsPerMinute() *foundation.NSString

func AVMetadataIdentifierID3MetadataComments ¶

func AVMetadataIdentifierID3MetadataComments() *foundation.NSString

func AVMetadataIdentifierID3MetadataCommercial ¶

func AVMetadataIdentifierID3MetadataCommercial() *foundation.NSString

func AVMetadataIdentifierID3MetadataCommercialInformation ¶

func AVMetadataIdentifierID3MetadataCommercialInformation() *foundation.NSString

func AVMetadataIdentifierID3MetadataCommerical deprecated

func AVMetadataIdentifierID3MetadataCommerical() *foundation.NSString

Deprecated: No longer supported

func AVMetadataIdentifierID3MetadataComposer ¶

func AVMetadataIdentifierID3MetadataComposer() *foundation.NSString

func AVMetadataIdentifierID3MetadataConductor ¶

func AVMetadataIdentifierID3MetadataConductor() *foundation.NSString

func AVMetadataIdentifierID3MetadataContentGroupDescription ¶

func AVMetadataIdentifierID3MetadataContentGroupDescription() *foundation.NSString

func AVMetadataIdentifierID3MetadataContentType ¶

func AVMetadataIdentifierID3MetadataContentType() *foundation.NSString

func AVMetadataIdentifierID3MetadataCopyright ¶

func AVMetadataIdentifierID3MetadataCopyright() *foundation.NSString

func AVMetadataIdentifierID3MetadataCopyrightInformation ¶

func AVMetadataIdentifierID3MetadataCopyrightInformation() *foundation.NSString

func AVMetadataIdentifierID3MetadataDate ¶

func AVMetadataIdentifierID3MetadataDate() *foundation.NSString

func AVMetadataIdentifierID3MetadataEncodedBy ¶

func AVMetadataIdentifierID3MetadataEncodedBy() *foundation.NSString

func AVMetadataIdentifierID3MetadataEncodedWith ¶

func AVMetadataIdentifierID3MetadataEncodedWith() *foundation.NSString

func AVMetadataIdentifierID3MetadataEncodingTime ¶

func AVMetadataIdentifierID3MetadataEncodingTime() *foundation.NSString

func AVMetadataIdentifierID3MetadataEncryption ¶

func AVMetadataIdentifierID3MetadataEncryption() *foundation.NSString

func AVMetadataIdentifierID3MetadataEqualization ¶

func AVMetadataIdentifierID3MetadataEqualization() *foundation.NSString

func AVMetadataIdentifierID3MetadataEqualization2 ¶

func AVMetadataIdentifierID3MetadataEqualization2() *foundation.NSString

func AVMetadataIdentifierID3MetadataEventTimingCodes ¶

func AVMetadataIdentifierID3MetadataEventTimingCodes() *foundation.NSString

func AVMetadataIdentifierID3MetadataFileOwner ¶

func AVMetadataIdentifierID3MetadataFileOwner() *foundation.NSString

func AVMetadataIdentifierID3MetadataFileType ¶

func AVMetadataIdentifierID3MetadataFileType() *foundation.NSString

func AVMetadataIdentifierID3MetadataGeneralEncapsulatedObject ¶

func AVMetadataIdentifierID3MetadataGeneralEncapsulatedObject() *foundation.NSString

func AVMetadataIdentifierID3MetadataGroupIdentifier ¶

func AVMetadataIdentifierID3MetadataGroupIdentifier() *foundation.NSString

func AVMetadataIdentifierID3MetadataInitialKey ¶

func AVMetadataIdentifierID3MetadataInitialKey() *foundation.NSString

func AVMetadataIdentifierID3MetadataInternationalStandardRecordingCode ¶

func AVMetadataIdentifierID3MetadataInternationalStandardRecordingCode() *foundation.NSString

func AVMetadataIdentifierID3MetadataInternetRadioStationName ¶

func AVMetadataIdentifierID3MetadataInternetRadioStationName() *foundation.NSString

func AVMetadataIdentifierID3MetadataInternetRadioStationOwner ¶

func AVMetadataIdentifierID3MetadataInternetRadioStationOwner() *foundation.NSString

func AVMetadataIdentifierID3MetadataInvolvedPeopleList_v23 ¶

func AVMetadataIdentifierID3MetadataInvolvedPeopleList_v23() *foundation.NSString

func AVMetadataIdentifierID3MetadataInvolvedPeopleList_v24 ¶

func AVMetadataIdentifierID3MetadataInvolvedPeopleList_v24() *foundation.NSString

func AVMetadataIdentifierID3MetadataLanguage ¶

func AVMetadataIdentifierID3MetadataLanguage() *foundation.NSString

func AVMetadataIdentifierID3MetadataLeadPerformer ¶

func AVMetadataIdentifierID3MetadataLeadPerformer() *foundation.NSString

func AVMetadataIdentifierID3MetadataLength ¶

func AVMetadataIdentifierID3MetadataLength() *foundation.NSString
func AVMetadataIdentifierID3MetadataLink() *foundation.NSString

func AVMetadataIdentifierID3MetadataLyricist ¶

func AVMetadataIdentifierID3MetadataLyricist() *foundation.NSString

func AVMetadataIdentifierID3MetadataMPEGLocationLookupTable ¶

func AVMetadataIdentifierID3MetadataMPEGLocationLookupTable() *foundation.NSString

func AVMetadataIdentifierID3MetadataMediaType ¶

func AVMetadataIdentifierID3MetadataMediaType() *foundation.NSString

func AVMetadataIdentifierID3MetadataModifiedBy ¶

func AVMetadataIdentifierID3MetadataModifiedBy() *foundation.NSString

func AVMetadataIdentifierID3MetadataMood ¶

func AVMetadataIdentifierID3MetadataMood() *foundation.NSString

func AVMetadataIdentifierID3MetadataMusicCDIdentifier ¶

func AVMetadataIdentifierID3MetadataMusicCDIdentifier() *foundation.NSString

func AVMetadataIdentifierID3MetadataMusicianCreditsList ¶

func AVMetadataIdentifierID3MetadataMusicianCreditsList() *foundation.NSString

func AVMetadataIdentifierID3MetadataOfficialArtistWebpage ¶

func AVMetadataIdentifierID3MetadataOfficialArtistWebpage() *foundation.NSString

func AVMetadataIdentifierID3MetadataOfficialAudioFileWebpage ¶

func AVMetadataIdentifierID3MetadataOfficialAudioFileWebpage() *foundation.NSString

func AVMetadataIdentifierID3MetadataOfficialAudioSourceWebpage ¶

func AVMetadataIdentifierID3MetadataOfficialAudioSourceWebpage() *foundation.NSString

func AVMetadataIdentifierID3MetadataOfficialInternetRadioStationHomepage ¶

func AVMetadataIdentifierID3MetadataOfficialInternetRadioStationHomepage() *foundation.NSString

func AVMetadataIdentifierID3MetadataOfficialPublisherWebpage ¶

func AVMetadataIdentifierID3MetadataOfficialPublisherWebpage() *foundation.NSString

func AVMetadataIdentifierID3MetadataOriginalAlbumTitle ¶

func AVMetadataIdentifierID3MetadataOriginalAlbumTitle() *foundation.NSString

func AVMetadataIdentifierID3MetadataOriginalArtist ¶

func AVMetadataIdentifierID3MetadataOriginalArtist() *foundation.NSString

func AVMetadataIdentifierID3MetadataOriginalFilename ¶

func AVMetadataIdentifierID3MetadataOriginalFilename() *foundation.NSString

func AVMetadataIdentifierID3MetadataOriginalLyricist ¶

func AVMetadataIdentifierID3MetadataOriginalLyricist() *foundation.NSString

func AVMetadataIdentifierID3MetadataOriginalReleaseTime ¶

func AVMetadataIdentifierID3MetadataOriginalReleaseTime() *foundation.NSString

func AVMetadataIdentifierID3MetadataOriginalReleaseYear ¶

func AVMetadataIdentifierID3MetadataOriginalReleaseYear() *foundation.NSString

func AVMetadataIdentifierID3MetadataOwnership ¶

func AVMetadataIdentifierID3MetadataOwnership() *foundation.NSString

func AVMetadataIdentifierID3MetadataPartOfASet ¶

func AVMetadataIdentifierID3MetadataPartOfASet() *foundation.NSString

func AVMetadataIdentifierID3MetadataPayment ¶

func AVMetadataIdentifierID3MetadataPayment() *foundation.NSString

func AVMetadataIdentifierID3MetadataPerformerSortOrder ¶

func AVMetadataIdentifierID3MetadataPerformerSortOrder() *foundation.NSString

func AVMetadataIdentifierID3MetadataPlayCounter ¶

func AVMetadataIdentifierID3MetadataPlayCounter() *foundation.NSString

func AVMetadataIdentifierID3MetadataPlaylistDelay ¶

func AVMetadataIdentifierID3MetadataPlaylistDelay() *foundation.NSString

func AVMetadataIdentifierID3MetadataPopularimeter ¶

func AVMetadataIdentifierID3MetadataPopularimeter() *foundation.NSString

func AVMetadataIdentifierID3MetadataPositionSynchronization ¶

func AVMetadataIdentifierID3MetadataPositionSynchronization() *foundation.NSString

func AVMetadataIdentifierID3MetadataPrivate ¶

func AVMetadataIdentifierID3MetadataPrivate() *foundation.NSString

func AVMetadataIdentifierID3MetadataProducedNotice ¶

func AVMetadataIdentifierID3MetadataProducedNotice() *foundation.NSString

func AVMetadataIdentifierID3MetadataPublisher ¶

func AVMetadataIdentifierID3MetadataPublisher() *foundation.NSString

func AVMetadataIdentifierID3MetadataRecommendedBufferSize ¶

func AVMetadataIdentifierID3MetadataRecommendedBufferSize() *foundation.NSString

func AVMetadataIdentifierID3MetadataRecordingDates ¶

func AVMetadataIdentifierID3MetadataRecordingDates() *foundation.NSString

func AVMetadataIdentifierID3MetadataRecordingTime ¶

func AVMetadataIdentifierID3MetadataRecordingTime() *foundation.NSString

func AVMetadataIdentifierID3MetadataRelativeVolumeAdjustment ¶

func AVMetadataIdentifierID3MetadataRelativeVolumeAdjustment() *foundation.NSString

func AVMetadataIdentifierID3MetadataRelativeVolumeAdjustment2 ¶

func AVMetadataIdentifierID3MetadataRelativeVolumeAdjustment2() *foundation.NSString

func AVMetadataIdentifierID3MetadataReleaseTime ¶

func AVMetadataIdentifierID3MetadataReleaseTime() *foundation.NSString

func AVMetadataIdentifierID3MetadataReverb ¶

func AVMetadataIdentifierID3MetadataReverb() *foundation.NSString

func AVMetadataIdentifierID3MetadataSeek ¶

func AVMetadataIdentifierID3MetadataSeek() *foundation.NSString

func AVMetadataIdentifierID3MetadataSetSubtitle ¶

func AVMetadataIdentifierID3MetadataSetSubtitle() *foundation.NSString

func AVMetadataIdentifierID3MetadataSignature ¶

func AVMetadataIdentifierID3MetadataSignature() *foundation.NSString

func AVMetadataIdentifierID3MetadataSize ¶

func AVMetadataIdentifierID3MetadataSize() *foundation.NSString

func AVMetadataIdentifierID3MetadataSubTitle ¶

func AVMetadataIdentifierID3MetadataSubTitle() *foundation.NSString

func AVMetadataIdentifierID3MetadataSynchronizedLyric ¶

func AVMetadataIdentifierID3MetadataSynchronizedLyric() *foundation.NSString

func AVMetadataIdentifierID3MetadataSynchronizedTempoCodes ¶

func AVMetadataIdentifierID3MetadataSynchronizedTempoCodes() *foundation.NSString

func AVMetadataIdentifierID3MetadataTaggingTime ¶

func AVMetadataIdentifierID3MetadataTaggingTime() *foundation.NSString

func AVMetadataIdentifierID3MetadataTermsOfUse ¶

func AVMetadataIdentifierID3MetadataTermsOfUse() *foundation.NSString

func AVMetadataIdentifierID3MetadataTime ¶

func AVMetadataIdentifierID3MetadataTime() *foundation.NSString

func AVMetadataIdentifierID3MetadataTitleDescription ¶

func AVMetadataIdentifierID3MetadataTitleDescription() *foundation.NSString

func AVMetadataIdentifierID3MetadataTitleSortOrder ¶

func AVMetadataIdentifierID3MetadataTitleSortOrder() *foundation.NSString

func AVMetadataIdentifierID3MetadataTrackNumber ¶

func AVMetadataIdentifierID3MetadataTrackNumber() *foundation.NSString

func AVMetadataIdentifierID3MetadataUniqueFileIdentifier ¶

func AVMetadataIdentifierID3MetadataUniqueFileIdentifier() *foundation.NSString

func AVMetadataIdentifierID3MetadataUnsynchronizedLyric ¶

func AVMetadataIdentifierID3MetadataUnsynchronizedLyric() *foundation.NSString

func AVMetadataIdentifierID3MetadataUserText ¶

func AVMetadataIdentifierID3MetadataUserText() *foundation.NSString

func AVMetadataIdentifierID3MetadataUserURL ¶

func AVMetadataIdentifierID3MetadataUserURL() *foundation.NSString

func AVMetadataIdentifierID3MetadataYear ¶

func AVMetadataIdentifierID3MetadataYear() *foundation.NSString

func AVMetadataIdentifierISOUserDataAccessibilityDescription ¶

func AVMetadataIdentifierISOUserDataAccessibilityDescription() *foundation.NSString

func AVMetadataIdentifierISOUserDataCopyright ¶

func AVMetadataIdentifierISOUserDataCopyright() *foundation.NSString

func AVMetadataIdentifierISOUserDataDate ¶

func AVMetadataIdentifierISOUserDataDate() *foundation.NSString

func AVMetadataIdentifierISOUserDataTaggedCharacteristic ¶

func AVMetadataIdentifierISOUserDataTaggedCharacteristic() *foundation.NSString

func AVMetadataIdentifierIcyMetadataStreamTitle ¶

func AVMetadataIdentifierIcyMetadataStreamTitle() *foundation.NSString

func AVMetadataIdentifierIcyMetadataStreamURL ¶

func AVMetadataIdentifierIcyMetadataStreamURL() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataAIMEData ¶

func AVMetadataIdentifierQuickTimeMetadataAIMEData() *foundation.NSString

A value of type kCMMetadataBaseDataType_RawData The static presentation metadata, Apple Immersive Media Embedded (AIME), for Apple Immersive Video that originates from ImmersiveMediaSupport framework's VenueDescriptor.aimeData.

func AVMetadataIdentifierQuickTimeMetadataAccessibilityDescription ¶

func AVMetadataIdentifierQuickTimeMetadataAccessibilityDescription() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataAlbum ¶

func AVMetadataIdentifierQuickTimeMetadataAlbum() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataArranger ¶

func AVMetadataIdentifierQuickTimeMetadataArranger() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataArtist ¶

func AVMetadataIdentifierQuickTimeMetadataArtist() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataArtwork ¶

func AVMetadataIdentifierQuickTimeMetadataArtwork() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataAuthor ¶

func AVMetadataIdentifierQuickTimeMetadataAuthor() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataAutoLivePhoto ¶

func AVMetadataIdentifierQuickTimeMetadataAutoLivePhoto() *foundation.NSString

A value of type kCMMetadataBaseDataType_UInt8 indicating whether this Live Photo movie was captured in "Auto" mode. Clients capturing LivePhoto content may add this movie-level metadata to signify that the movie content should only be used (when swiping between photos, or force-touching a photo) if it's sufficiently dynamic. For instance, photos of static scenes or documents are to be excluded from the Live Photo experience.

func AVMetadataIdentifierQuickTimeMetadataCameraFocalLength35mmEquivalent ¶

func AVMetadataIdentifierQuickTimeMetadataCameraFocalLength35mmEquivalent() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating focal length normalized to the 35mm film equivalent value (e.g. "50.00mm"). This is track-level metadata for video track that is associated with the camera.

func AVMetadataIdentifierQuickTimeMetadataCameraFrameReadoutTime ¶

func AVMetadataIdentifierQuickTimeMetadataCameraFrameReadoutTime() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataCameraISOSensitivity ¶

func AVMetadataIdentifierQuickTimeMetadataCameraISOSensitivity() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the sensitivity of the camera to light in terms of ISO exposure index (e.g. "800"). See SMPTE RDD 18.

func AVMetadataIdentifierQuickTimeMetadataCameraIdentifier ¶

func AVMetadataIdentifierQuickTimeMetadataCameraIdentifier() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataCameraLensIrisFNumber ¶

func AVMetadataIdentifierQuickTimeMetadataCameraLensIrisFNumber() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating measure of the amount of light transmitted through the lens. It is the focal length divided by the effective lens aperture diameter (e.g. "F2.8" or "2.8"). This is track-level metadata for video track that is associated with the camera.

func AVMetadataIdentifierQuickTimeMetadataCameraLensModel ¶

func AVMetadataIdentifierQuickTimeMetadataCameraLensModel() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the lens model (e.g. "iPhone 16 Pro back camera 6.765mm f/1.78"). This is track-level metadata for video track that is associated with the camera.

func AVMetadataIdentifierQuickTimeMetadataCameraShutterSpeedAngle ¶

func AVMetadataIdentifierQuickTimeMetadataCameraShutterSpeedAngle() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the exposure period expressed as an angle in minutes (1/60 degree) (e.g. "21600" or "360.00deg"").

func AVMetadataIdentifierQuickTimeMetadataCameraShutterSpeedTime ¶

func AVMetadataIdentifierQuickTimeMetadataCameraShutterSpeedTime() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the exposure period expressed as a time per one frame/field period in seconds.

func AVMetadataIdentifierQuickTimeMetadataCameraWhiteBalance ¶

func AVMetadataIdentifierQuickTimeMetadataCameraWhiteBalance() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the white balance value defined by the temperature in Kelvin units (e.g. "5500K" or "5500"). See SMPTE RDD 18.

func AVMetadataIdentifierQuickTimeMetadataCinematicVideoIntent ¶

func AVMetadataIdentifierQuickTimeMetadataCinematicVideoIntent() *foundation.NSString

A value of type `kCMMetadataBaseDataType_UInt8` indicating whether this movie is intended as a Cinematic Video (1) or not (0). This movie-level metadata is automatically added (with a value of 1) to a movie recorded using the Cinematic Video API. Clients can override it with a value of 0 to signal that this movie is not to be treated as a Cinematic Video by Apple's software like Photos.

func AVMetadataIdentifierQuickTimeMetadataCollectionUser ¶

func AVMetadataIdentifierQuickTimeMetadataCollectionUser() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataComment ¶

func AVMetadataIdentifierQuickTimeMetadataComment() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataComposer ¶

func AVMetadataIdentifierQuickTimeMetadataComposer() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataContentIdentifier ¶

func AVMetadataIdentifierQuickTimeMetadataContentIdentifier() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataCopyright ¶

func AVMetadataIdentifierQuickTimeMetadataCopyright() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataCreationDate ¶

func AVMetadataIdentifierQuickTimeMetadataCreationDate() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataCredits ¶

func AVMetadataIdentifierQuickTimeMetadataCredits() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDescription ¶

func AVMetadataIdentifierQuickTimeMetadataDescription() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDetectedCatBody ¶

func AVMetadataIdentifierQuickTimeMetadataDetectedCatBody() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDetectedDogBody ¶

func AVMetadataIdentifierQuickTimeMetadataDetectedDogBody() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDetectedFace ¶

func AVMetadataIdentifierQuickTimeMetadataDetectedFace() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDetectedHumanBody ¶

func AVMetadataIdentifierQuickTimeMetadataDetectedHumanBody() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDetectedSalientObject ¶

func AVMetadataIdentifierQuickTimeMetadataDetectedSalientObject() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDirectionFacing ¶

func AVMetadataIdentifierQuickTimeMetadataDirectionFacing() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDirectionMotion ¶

func AVMetadataIdentifierQuickTimeMetadataDirectionMotion() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDirector ¶

func AVMetadataIdentifierQuickTimeMetadataDirector() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataDisplayName ¶

func AVMetadataIdentifierQuickTimeMetadataDisplayName() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataEncodedBy ¶

func AVMetadataIdentifierQuickTimeMetadataEncodedBy() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataFullFrameRatePlaybackIntent ¶

func AVMetadataIdentifierQuickTimeMetadataFullFrameRatePlaybackIntent() *foundation.NSString

A value of type kCMMetadataBaseDataType_UInt8 indicating whether this movie is intended to be played back at the full frame rate (1), or at a slow motion rate (0). Historically, some apps have played movies recorded at frame rates of 120fps or higher in slow motion by default. With the introduction of this metadata, apps that record high-frame-rate movies may add this movie-level metadata to indicate whether the movie is intended to be played at the full frame rate (1) or at a slow motion rate (0). Apps that play movies may use this metadata, when present, to guide their behavior.

func AVMetadataIdentifierQuickTimeMetadataGenre ¶

func AVMetadataIdentifierQuickTimeMetadataGenre() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataInformation ¶

func AVMetadataIdentifierQuickTimeMetadataInformation() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataIsMontage ¶

func AVMetadataIdentifierQuickTimeMetadataIsMontage() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataKeywords ¶

func AVMetadataIdentifierQuickTimeMetadataKeywords() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataLivePhotoVitalityScore ¶

func AVMetadataIdentifierQuickTimeMetadataLivePhotoVitalityScore() *foundation.NSString

A value of type kCMMetadataBaseDataType_Float32. Live Photo movies may be algorithmically scored from 0. to 1. on their level of vitality. A Live Photo movie with a low vitality score offers little dynamism to the still photo it accompanies. The vitality score is normalized and independent of the vitality scoring version of the algorithm (see AVMetadataIdentifierQuickTimeMetadataLivePhotoVitalityScoringVersion). If a Live Photo movie contains the AVMetadataIdentifierQuickTimeMetadataAutoLivePhoto key and its value is non-zero, apps should read the AVMetadataIdentifierQuickTimeMetadataLivePhotoVitalityScore value and only display the movie's content if the score is 0.5 or higher. If the capture session includes a metadata output configured to provide face, dog, or cat metadata objects, their presence will greatly increase the vitality score.

func AVMetadataIdentifierQuickTimeMetadataLivePhotoVitalityScoringVersion ¶

func AVMetadataIdentifierQuickTimeMetadataLivePhotoVitalityScoringVersion() *foundation.NSString

A value of type kCMMetadataBaseDataType_UInt32. The version of the algorithm that scored the Live Photo movie for vitality.

func AVMetadataIdentifierQuickTimeMetadataLocationBody ¶

func AVMetadataIdentifierQuickTimeMetadataLocationBody() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataLocationDate ¶

func AVMetadataIdentifierQuickTimeMetadataLocationDate() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataLocationHorizontalAccuracyInMeters ¶

func AVMetadataIdentifierQuickTimeMetadataLocationHorizontalAccuracyInMeters() *foundation.NSString

A value of type kCMMetadataBaseDataType_Float32. The horizontal accuracy of the provided location data (usually specified by AVMetadataIdentifierQuickTimeMetadataLocationISO6709).

func AVMetadataIdentifierQuickTimeMetadataLocationISO6709 ¶

func AVMetadataIdentifierQuickTimeMetadataLocationISO6709() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataLocationName ¶

func AVMetadataIdentifierQuickTimeMetadataLocationName() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataLocationNote ¶

func AVMetadataIdentifierQuickTimeMetadataLocationNote() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataLocationRole ¶

func AVMetadataIdentifierQuickTimeMetadataLocationRole() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataMake ¶

func AVMetadataIdentifierQuickTimeMetadataMake() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataModel ¶

func AVMetadataIdentifierQuickTimeMetadataModel() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataOriginalArtist ¶

func AVMetadataIdentifierQuickTimeMetadataOriginalArtist() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataPerformer ¶

func AVMetadataIdentifierQuickTimeMetadataPerformer() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataPhonogramRights ¶

func AVMetadataIdentifierQuickTimeMetadataPhonogramRights() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataPreferredAffineTransform ¶

func AVMetadataIdentifierQuickTimeMetadataPreferredAffineTransform() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataPresentationImmersiveMedia ¶

func AVMetadataIdentifierQuickTimeMetadataPresentationImmersiveMedia() *foundation.NSString

A value of type kCMMetadataBaseDataType_RawData The presentation timed metadata for Apple Immerisve Video. Value is a JSON-encoding of ImmersiveMediaSupport framework's PresentationDescriptor object.

func AVMetadataIdentifierQuickTimeMetadataProducer ¶

func AVMetadataIdentifierQuickTimeMetadataProducer() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataPublisher ¶

func AVMetadataIdentifierQuickTimeMetadataPublisher() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataRatingUser ¶

func AVMetadataIdentifierQuickTimeMetadataRatingUser() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataSoftware ¶

func AVMetadataIdentifierQuickTimeMetadataSoftware() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataSpatialOverCaptureQualityScore ¶

func AVMetadataIdentifierQuickTimeMetadataSpatialOverCaptureQualityScore() *foundation.NSString

A value of type kCMMetadataBaseDataType_Float32. The video may be scored by a heuristic which considers factors such as exposure and focus. The value ranges from 0-1, where a score below 0.5 indicates the asset has serious flaws.

func AVMetadataIdentifierQuickTimeMetadataSpatialOverCaptureQualityScoringVersion ¶

func AVMetadataIdentifierQuickTimeMetadataSpatialOverCaptureQualityScoringVersion() *foundation.NSString

A value of type kCMMetadataBaseDataType_UInt32. The version of the algorithm that provided the spatial over capture quality score.

func AVMetadataIdentifierQuickTimeMetadataTitle ¶

func AVMetadataIdentifierQuickTimeMetadataTitle() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataVideoOrientation ¶

func AVMetadataIdentifierQuickTimeMetadataVideoOrientation() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataWhiteBalanceByCCTColorMatrices ¶

func AVMetadataIdentifierQuickTimeMetadataWhiteBalanceByCCTColorMatrices() *foundation.NSString

A value of type kCMMetadataBaseDataType_RawData indicating the reference color translation matrix data for ProRes RAW.

func AVMetadataIdentifierQuickTimeMetadataWhiteBalanceByCCTWhiteBalanceFactors ¶

func AVMetadataIdentifierQuickTimeMetadataWhiteBalanceByCCTWhiteBalanceFactors() *foundation.NSString

A value of type kCMMetadataBaseDataType_RawData indicating the reference white balance multiplication factor data for ProRes RAW.

func AVMetadataIdentifierQuickTimeMetadataYear ¶

func AVMetadataIdentifierQuickTimeMetadataYear() *foundation.NSString

func AVMetadataIdentifierQuickTimeMetadataiXML ¶

func AVMetadataIdentifierQuickTimeMetadataiXML() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataAccessibilityDescription ¶

func AVMetadataIdentifierQuickTimeUserDataAccessibilityDescription() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataAlbum ¶

func AVMetadataIdentifierQuickTimeUserDataAlbum() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataArranger ¶

func AVMetadataIdentifierQuickTimeUserDataArranger() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataArtist ¶

func AVMetadataIdentifierQuickTimeUserDataArtist() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataAuthor ¶

func AVMetadataIdentifierQuickTimeUserDataAuthor() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataChapter ¶

func AVMetadataIdentifierQuickTimeUserDataChapter() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataComment ¶

func AVMetadataIdentifierQuickTimeUserDataComment() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataComposer ¶

func AVMetadataIdentifierQuickTimeUserDataComposer() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataCopyright ¶

func AVMetadataIdentifierQuickTimeUserDataCopyright() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataCreationDate ¶

func AVMetadataIdentifierQuickTimeUserDataCreationDate() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataCredits ¶

func AVMetadataIdentifierQuickTimeUserDataCredits() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataDescription ¶

func AVMetadataIdentifierQuickTimeUserDataDescription() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataDirector ¶

func AVMetadataIdentifierQuickTimeUserDataDirector() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataDisclaimer ¶

func AVMetadataIdentifierQuickTimeUserDataDisclaimer() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataEncodedBy ¶

func AVMetadataIdentifierQuickTimeUserDataEncodedBy() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataFullName ¶

func AVMetadataIdentifierQuickTimeUserDataFullName() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataGenre ¶

func AVMetadataIdentifierQuickTimeUserDataGenre() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataHostComputer ¶

func AVMetadataIdentifierQuickTimeUserDataHostComputer() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataInformation ¶

func AVMetadataIdentifierQuickTimeUserDataInformation() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataKeywords ¶

func AVMetadataIdentifierQuickTimeUserDataKeywords() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataLocationISO6709 ¶

func AVMetadataIdentifierQuickTimeUserDataLocationISO6709() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataMake ¶

func AVMetadataIdentifierQuickTimeUserDataMake() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataModel ¶

func AVMetadataIdentifierQuickTimeUserDataModel() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataOriginalArtist ¶

func AVMetadataIdentifierQuickTimeUserDataOriginalArtist() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataOriginalFormat ¶

func AVMetadataIdentifierQuickTimeUserDataOriginalFormat() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataOriginalSource ¶

func AVMetadataIdentifierQuickTimeUserDataOriginalSource() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataPerformers ¶

func AVMetadataIdentifierQuickTimeUserDataPerformers() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataPhonogramRights ¶

func AVMetadataIdentifierQuickTimeUserDataPhonogramRights() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataProducer ¶

func AVMetadataIdentifierQuickTimeUserDataProducer() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataProduct ¶

func AVMetadataIdentifierQuickTimeUserDataProduct() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataPublisher ¶

func AVMetadataIdentifierQuickTimeUserDataPublisher() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataSoftware ¶

func AVMetadataIdentifierQuickTimeUserDataSoftware() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataSpecialPlaybackRequirements ¶

func AVMetadataIdentifierQuickTimeUserDataSpecialPlaybackRequirements() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataTaggedCharacteristic ¶

func AVMetadataIdentifierQuickTimeUserDataTaggedCharacteristic() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataTrack ¶

func AVMetadataIdentifierQuickTimeUserDataTrack() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataTrackName ¶

func AVMetadataIdentifierQuickTimeUserDataTrackName() *foundation.NSString
func AVMetadataIdentifierQuickTimeUserDataURLLink() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataWarning ¶

func AVMetadataIdentifierQuickTimeUserDataWarning() *foundation.NSString

func AVMetadataIdentifierQuickTimeUserDataWriter ¶

func AVMetadataIdentifierQuickTimeUserDataWriter() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataAccountKind ¶

func AVMetadataIdentifieriTunesMetadataAccountKind() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataAcknowledgement ¶

func AVMetadataIdentifieriTunesMetadataAcknowledgement() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataAlbum ¶

func AVMetadataIdentifieriTunesMetadataAlbum() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataAlbumArtist ¶

func AVMetadataIdentifieriTunesMetadataAlbumArtist() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataAppleID ¶

func AVMetadataIdentifieriTunesMetadataAppleID() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataArranger ¶

func AVMetadataIdentifieriTunesMetadataArranger() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataArtDirector ¶

func AVMetadataIdentifieriTunesMetadataArtDirector() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataArtist ¶

func AVMetadataIdentifieriTunesMetadataArtist() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataArtistID ¶

func AVMetadataIdentifieriTunesMetadataArtistID() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataAuthor ¶

func AVMetadataIdentifieriTunesMetadataAuthor() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataBeatsPerMin ¶

func AVMetadataIdentifieriTunesMetadataBeatsPerMin() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataComposer ¶

func AVMetadataIdentifieriTunesMetadataComposer() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataConductor ¶

func AVMetadataIdentifieriTunesMetadataConductor() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataContentRating ¶

func AVMetadataIdentifieriTunesMetadataContentRating() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataCopyright ¶

func AVMetadataIdentifieriTunesMetadataCopyright() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataCoverArt ¶

func AVMetadataIdentifieriTunesMetadataCoverArt() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataCredits ¶

func AVMetadataIdentifieriTunesMetadataCredits() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataDescription ¶

func AVMetadataIdentifieriTunesMetadataDescription() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataDirector ¶

func AVMetadataIdentifieriTunesMetadataDirector() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataDiscCompilation ¶

func AVMetadataIdentifieriTunesMetadataDiscCompilation() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataDiscNumber ¶

func AVMetadataIdentifieriTunesMetadataDiscNumber() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataEQ ¶

func AVMetadataIdentifieriTunesMetadataEQ() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataEncodedBy ¶

func AVMetadataIdentifieriTunesMetadataEncodedBy() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataEncodingTool ¶

func AVMetadataIdentifieriTunesMetadataEncodingTool() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataExecProducer ¶

func AVMetadataIdentifieriTunesMetadataExecProducer() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataGenreID ¶

func AVMetadataIdentifieriTunesMetadataGenreID() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataGrouping ¶

func AVMetadataIdentifieriTunesMetadataGrouping() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataLinerNotes ¶

func AVMetadataIdentifieriTunesMetadataLinerNotes() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataLyrics ¶

func AVMetadataIdentifieriTunesMetadataLyrics() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataOnlineExtras ¶

func AVMetadataIdentifieriTunesMetadataOnlineExtras() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataOriginalArtist ¶

func AVMetadataIdentifieriTunesMetadataOriginalArtist() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataPerformer ¶

func AVMetadataIdentifieriTunesMetadataPerformer() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataPhonogramRights ¶

func AVMetadataIdentifieriTunesMetadataPhonogramRights() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataPlaylistID ¶

func AVMetadataIdentifieriTunesMetadataPlaylistID() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataPredefinedGenre ¶

func AVMetadataIdentifieriTunesMetadataPredefinedGenre() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataProducer ¶

func AVMetadataIdentifieriTunesMetadataProducer() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataPublisher ¶

func AVMetadataIdentifieriTunesMetadataPublisher() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataRecordCompany ¶

func AVMetadataIdentifieriTunesMetadataRecordCompany() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataReleaseDate ¶

func AVMetadataIdentifieriTunesMetadataReleaseDate() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataSoloist ¶

func AVMetadataIdentifieriTunesMetadataSoloist() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataSongID ¶

func AVMetadataIdentifieriTunesMetadataSongID() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataSongName ¶

func AVMetadataIdentifieriTunesMetadataSongName() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataSoundEngineer ¶

func AVMetadataIdentifieriTunesMetadataSoundEngineer() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataThanks ¶

func AVMetadataIdentifieriTunesMetadataThanks() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataTrackNumber ¶

func AVMetadataIdentifieriTunesMetadataTrackNumber() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataTrackSubTitle ¶

func AVMetadataIdentifieriTunesMetadataTrackSubTitle() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataUserComment ¶

func AVMetadataIdentifieriTunesMetadataUserComment() *foundation.NSString

func AVMetadataIdentifieriTunesMetadataUserGenre ¶

func AVMetadataIdentifieriTunesMetadataUserGenre() *foundation.NSString

func AVMetadataItemIdentifierForKeyKeySpace ¶

func AVMetadataItemIdentifierForKeyKeySpace(key objc.ID, keySpace *foundation.NSString) *foundation.NSString

@method identifierForKey:keySpace: @abstract Provides the metadata identifier that's equivalent to a key and keySpace. @param key The metadata key. @param keySpace The metadata keySpace. @result A metadata identifier equivalent to the given key and keySpace, or nil if no identifier can be constructed from the given key and keySpace. @discussion Metadata keys that are not instances of NSString, NSNumber, or NSData cannot be converted to metadata identifiers; they also cannot be written to media resources via AVAssetExportSession or AVAssetWriter. Metadata item keySpaces must be a string of one to four printable ASCII characters. For custom identifiers, the keySpace AVMetadataKeySpaceQuickTimeMetadata is recommended. This keySpace defines its key values to be expressed as reverse-DNS strings, which allows third parties to define their own keys in a well established way that avoids collisions.

func AVMetadataItemKeyForIdentifier ¶

func AVMetadataItemKeyForIdentifier(identifier *foundation.NSString) objc.ID

func AVMetadataItemKeySpaceForIdentifier ¶

func AVMetadataItemKeySpaceForIdentifier(identifier *foundation.NSString) *foundation.NSString

func AVMetadataItemMetadataItemsFromArrayFilteredAndSortedAccordingToPreferredLanguages ¶

func AVMetadataItemMetadataItemsFromArrayFilteredAndSortedAccordingToPreferredLanguages(metadataItems *foundation.NSArray[*AVMetadataItem], preferredLanguages *foundation.NSArray[*foundation.NSString]) *foundation.NSArray[*AVMetadataItem]

@method metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages: @abstract Filters an array of AVMetadataItems according to whether their locales match any language identifier in the specified array of preferred languages. The returned array is sorted according to the order of preference of the language each matches. @param metadataItems An array of AVMetadataItems to be filtered and sorted. @param preferredLanguages An array of language identifiers in order of preference, each of which is an IETF BCP 47 (RFC 4646) language identifier. If your goal is to provide the best match for the end user's preferred languages without consideration of your app's available localizations, pass [NSLocale preferredLanguages] as the value of preferredLanguages. However, if you want to filter the available choices in order to obtain the best match among the localizations that are available for your app, pass [NSBundle preferredLocalizationsFromArray:[[NSBundle mainBundle] localizations] forPreferences:[NSLocale preferredLanguages]] instead. The latter choice is normally more appropriate for strings intended for display as part of the app's UI. @result An instance of NSArray containing metadata items of the specified NSArray that match a preferred language, sorted according to the order of preference of the language each matches.

func AVMetadataItemMetadataItemsFromArrayFilteredByIdentifier ¶

func AVMetadataItemMetadataItemsFromArrayFilteredByIdentifier(metadataItems *foundation.NSArray[*AVMetadataItem], identifier *foundation.NSString) *foundation.NSArray[*AVMetadataItem]

@method metadataItemsFromArray:filteredByIdentifier: @abstract Filters an array of AVMetadataItems according to identifier. @param metadataItems An array of AVMetadataItems to be filtered by identifier. @param identifier The identifier that must be matched for a metadata item to be copied to the output array. Items are considered a match not only when their identifiers are equal to the specified identifier, and also when their identifiers conform to the specified identifier. @result An instance of NSArray containing the metadata items of the target NSArray that match the specified identifier.

func AVMetadataItemMetadataItemsFromArrayFilteredByMetadataItemFilter ¶

func AVMetadataItemMetadataItemsFromArrayFilteredByMetadataItemFilter(metadataItems *foundation.NSArray[*AVMetadataItem], metadataItemFilter *AVMetadataItemFilter) *foundation.NSArray[*AVMetadataItem]

@method metadataItemsFromArray:filteredByMetadataItemFilter: @abstract Filters an array of AVMetadataItems using the supplied AVMetadataItemFilter. @param metadataItems An array of AVMetadataItems to be filtered. @param metadataItemFilter The AVMetadataItemFilter object for filtering the metadataItems. @result An instance of NSArray containing the metadata items of the target NSArray that have not been removed by metadataItemFilter.

func AVMetadataItemMetadataItemsFromArrayWithKeyKeySpace ¶

func AVMetadataItemMetadataItemsFromArrayWithKeyKeySpace(metadataItems *foundation.NSArray[*AVMetadataItem], key objc.ID, keySpace *foundation.NSString) *foundation.NSArray[*AVMetadataItem]

@method metadataItemsFromArray:withKey:keySpace: @discussion Instead, use metadataItemsFromArray:filteredByIdentifier:.

func AVMetadataItemMetadataItemsFromArrayWithLocale ¶

func AVMetadataItemMetadataItemsFromArrayWithLocale(metadataItems *foundation.NSArray[*AVMetadataItem], locale *foundation.NSLocale) *foundation.NSArray[*AVMetadataItem]

@method metadataItemsFromArray:withLocale: @discussion Instead, use metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:.

func AVMetadataKeySpaceAudioFile ¶

func AVMetadataKeySpaceAudioFile() *foundation.NSString

Keys for metadata provided by AudioToolbox's AudioFile interface. See <AudioToolbox/AudioFile.h>

func AVMetadataKeySpaceCommon ¶

func AVMetadataKeySpaceCommon() *foundation.NSString

func AVMetadataKeySpaceHLSDateRange ¶

func AVMetadataKeySpaceHLSDateRange() *foundation.NSString

HLS Metadata does not define its own keySpace or keys. Use of the keySpace AVMetadataKeySpaceQuickTimeMetadata and its keys is recommended.

func AVMetadataKeySpaceID3 ¶

func AVMetadataKeySpaceID3() *foundation.NSString

func AVMetadataKeySpaceISOUserData ¶

func AVMetadataKeySpaceISOUserData() *foundation.NSString

func AVMetadataKeySpaceIcy ¶

func AVMetadataKeySpaceIcy() *foundation.NSString

Icecast/ShoutCAST streaming metadata

func AVMetadataKeySpaceQuickTimeMetadata ¶

func AVMetadataKeySpaceQuickTimeMetadata() *foundation.NSString

func AVMetadataKeySpaceQuickTimeUserData ¶

func AVMetadataKeySpaceQuickTimeUserData() *foundation.NSString

func AVMetadataKeySpaceiTunes ¶

func AVMetadataKeySpaceiTunes() *foundation.NSString

func AVMetadataObjectTypeAztecCode ¶

func AVMetadataObjectTypeAztecCode() *foundation.NSString

@constant AVMetadataObjectTypeAztecCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeAztecCode. @discussion AVMetadataMachineReadableCodeObject objects generated from Aztec codes return this constant as their type.

func AVMetadataObjectTypeCatBody ¶

func AVMetadataObjectTypeCatBody() uintptr

@constant AVMetadataObjectTypeCatBody @abstract An identifier for an instance of AVMetadataCatBodyObject. @discussion AVMetadataCatBodyObject objects return this constant as their type.

func AVMetadataObjectTypeCatHead ¶

func AVMetadataObjectTypeCatHead() uintptr

An identifier for an instance of a cat head object. “AVMetadataCatHeadObject“ objects return this constant as their type.

func AVMetadataObjectTypeCodabarCode ¶

func AVMetadataObjectTypeCodabarCode() uintptr

@constant AVMetadataObjectTypeCodabarCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeCodabarCode. @discussion AVMetadataMachineReadableCodeObject objects generated from Codabar codes return this constant as their type.

func AVMetadataObjectTypeCode39Code ¶

func AVMetadataObjectTypeCode39Code() *foundation.NSString

@constant AVMetadataObjectTypeCode39Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeCode39Code. @discussion AVMetadataMachineReadableCodeObject objects generated from Code 39 codes return this constant as their type.

func AVMetadataObjectTypeCode39Mod43Code ¶

func AVMetadataObjectTypeCode39Mod43Code() *foundation.NSString

@constant AVMetadataObjectTypeCode39Mod43Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeCode39Mod43Code. @discussion AVMetadataMachineReadableCodeObject objects generated from Code 39 mod 43 codes return this constant as their type.

func AVMetadataObjectTypeCode93Code ¶

func AVMetadataObjectTypeCode93Code() *foundation.NSString

@constant AVMetadataObjectTypeCode93Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeCode93Code. @discussion AVMetadataMachineReadableCodeObject objects generated from Code 93 codes return this constant as their type.

func AVMetadataObjectTypeCode128Code ¶

func AVMetadataObjectTypeCode128Code() *foundation.NSString

@constant AVMetadataObjectTypeCode128Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeCode128Code. @discussion AVMetadataMachineReadableCodeObject objects generated from Code 128 codes return this constant as their type.

func AVMetadataObjectTypeDataMatrixCode ¶

func AVMetadataObjectTypeDataMatrixCode() *foundation.NSString

@constant AVMetadataObjectTypeDataMatrixCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeDataMatrixCode. @discussion AVMetadataMachineReadableCodeObject objects generated from DataMatrix codes return this constant as their type.

func AVMetadataObjectTypeDogBody ¶

func AVMetadataObjectTypeDogBody() uintptr

@constant AVMetadataObjectTypeDogBody @abstract An identifier for an instance of AVMetadataDogBodyObject. @discussion AVMetadataDogBodyObject objects return this constant as their type.

func AVMetadataObjectTypeDogHead ¶

func AVMetadataObjectTypeDogHead() uintptr

An identifier for an instance of a dog head object. “AVMetadataDogHeadObject“ objects return this constant as their type.

func AVMetadataObjectTypeEAN8Code ¶

func AVMetadataObjectTypeEAN8Code() *foundation.NSString

@constant AVMetadataObjectTypeEAN8Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeEAN8Code. @discussion AVMetadataMachineReadableCodeObject objects generated from EAN-8 codes return this constant as their type.

func AVMetadataObjectTypeEAN13Code ¶

func AVMetadataObjectTypeEAN13Code() *foundation.NSString

@constant AVMetadataObjectTypeEAN13Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeEAN13Code. @discussion AVMetadataMachineReadableCodeObject objects generated from EAN-13 (including UPC-A) codes return this constant as their type.

func AVMetadataObjectTypeFace ¶

func AVMetadataObjectTypeFace() *foundation.NSString

@constant AVMetadataObjectTypeFace @abstract An identifier for an instance of AVMetadataFaceObject. @discussion AVMetadataFaceObject objects return this constant as their type.

func AVMetadataObjectTypeGS1DataBarCode ¶

func AVMetadataObjectTypeGS1DataBarCode() uintptr

@constant AVMetadataObjectTypeGS1DataBarCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeGS1DataBarCode. @discussion AVMetadataMachineReadableCodeObject objects generated from GS1DataBar codes return this constant as their type.

func AVMetadataObjectTypeGS1DataBarExpandedCode ¶

func AVMetadataObjectTypeGS1DataBarExpandedCode() uintptr

@constant AVMetadataObjectTypeGS1DataBarExpandedCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeGS1DataBarExpandedCode. @discussion AVMetadataMachineReadableCodeObject objects generated from GS1DataBarExpanded codes return this constant as their type.

func AVMetadataObjectTypeGS1DataBarLimitedCode ¶

func AVMetadataObjectTypeGS1DataBarLimitedCode() uintptr

@constant AVMetadataObjectTypeGS1DataBarLimitedCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeGS1DataBarLimitedCode. @discussion AVMetadataMachineReadableCodeObject objects generated from GS1DataBarLimited codes return this constant as their type.

func AVMetadataObjectTypeHumanBody ¶

func AVMetadataObjectTypeHumanBody() uintptr

@constant AVMetadataObjectTypeHumanBody @abstract An identifier for an instance of AVMetadataHumanBodyObject. @discussion AVMetadataHumanBodyObject objects return this constant as their type.

func AVMetadataObjectTypeHumanFullBody ¶

func AVMetadataObjectTypeHumanFullBody() uintptr

@constant AVMetadataObjectTypeHumanFullBody @abstract An identifier for an instance of AVMetadataHumanFullBodyObject. @discussion AVMetadataHumanFullBodyObject objects return this constant as their type.

func AVMetadataObjectTypeITF14Code ¶

func AVMetadataObjectTypeITF14Code() *foundation.NSString

@constant AVMetadataObjectTypeITF14Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeITF14Code. @discussion AVMetadataMachineReadableCodeObject objects generated from ITF14 codes return this constant as their type.

func AVMetadataObjectTypeInterleaved2of5Code ¶

func AVMetadataObjectTypeInterleaved2of5Code() *foundation.NSString

@constant AVMetadataObjectTypeInterleaved2of5Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeInterleaved2of5Code. @discussion AVMetadataMachineReadableCodeObject objects generated from Interleaved 2 of 5 codes return this constant as their type.

func AVMetadataObjectTypeMicroPDF417Code ¶

func AVMetadataObjectTypeMicroPDF417Code() uintptr

@constant AVMetadataObjectTypeMicroPDF417Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeMicroPDF417Code. @discussion AVMetadataMachineReadableCodeObject objects generated from MicroPDF417 codes return this constant as their type.

func AVMetadataObjectTypeMicroQRCode ¶

func AVMetadataObjectTypeMicroQRCode() uintptr

@constant AVMetadataObjectTypeMicroQRCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeMicroQRCode. @discussion AVMetadataMachineReadableCodeObject objects generated from MicroQR codes return this constant as their type.

func AVMetadataObjectTypePDF417Code ¶

func AVMetadataObjectTypePDF417Code() *foundation.NSString

@constant AVMetadataObjectTypePDF417Code @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypePDF417Code. @discussion AVMetadataMachineReadableCodeObject objects generated from PDF417 codes return this constant as their type.

func AVMetadataObjectTypeQRCode ¶

func AVMetadataObjectTypeQRCode() *foundation.NSString

@constant AVMetadataObjectTypeQRCode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeQRCode. @discussion AVMetadataMachineReadableCodeObject objects generated from QR codes return this constant as their type.

func AVMetadataObjectTypeSalientObject ¶

func AVMetadataObjectTypeSalientObject() uintptr

@constant AVMetadataObjectTypeSalientObject @abstract An identifier for an instance of AVMetadataSalientObject. @discussion AVMetadataSalientObject objects return this constant as their type.

func AVMetadataObjectTypeUPCECode ¶

func AVMetadataObjectTypeUPCECode() *foundation.NSString

@constant AVMetadataObjectTypeUPCECode @abstract An identifier for an instance of AVMetadataMachineReadableCodeObject having a type AVMetadataObjectTypeUPCECode. @discussion AVMetadataMachineReadableCodeObject objects generated from UPC-E codes return this constant as their type.

func AVMetadataQuickTimeMetadataKeyAccessibilityDescription ¶

func AVMetadataQuickTimeMetadataKeyAccessibilityDescription() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyAlbum ¶

func AVMetadataQuickTimeMetadataKeyAlbum() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyArranger ¶

func AVMetadataQuickTimeMetadataKeyArranger() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyArtist ¶

func AVMetadataQuickTimeMetadataKeyArtist() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyArtwork ¶

func AVMetadataQuickTimeMetadataKeyArtwork() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyAuthor ¶

func AVMetadataQuickTimeMetadataKeyAuthor() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyCameraFocalLength35mmEquivalent ¶

func AVMetadataQuickTimeMetadataKeyCameraFocalLength35mmEquivalent() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating focal length normalized to the 35mm film equivalent value (e.g. "50.00mm"). This is track-level metadata for video track that is associated with the camera.

func AVMetadataQuickTimeMetadataKeyCameraFrameReadoutTime ¶

func AVMetadataQuickTimeMetadataKeyCameraFrameReadoutTime() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyCameraISOSensitivity ¶

func AVMetadataQuickTimeMetadataKeyCameraISOSensitivity() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the sensitivity of the camera to light in terms of ISO exposure index (e.g. "800"). See SMPTE RDD 18.

func AVMetadataQuickTimeMetadataKeyCameraIdentifier ¶

func AVMetadataQuickTimeMetadataKeyCameraIdentifier() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyCameraLensIrisFNumber ¶

func AVMetadataQuickTimeMetadataKeyCameraLensIrisFNumber() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating measure of the amount of light transmitted through the lens. It is the focal length divided by the effective lens aperture diameter (e.g. "F2.8" or "2.8"). This is track-level metadata for video track that is associated with the camera.

func AVMetadataQuickTimeMetadataKeyCameraLensModel ¶

func AVMetadataQuickTimeMetadataKeyCameraLensModel() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the lens model (e.g. "iPhone 16 Pro back camera 6.765mm f/1.78"). This is track-level metadata for video track that is associated with the camera.

func AVMetadataQuickTimeMetadataKeyCameraShutterSpeedAngle ¶

func AVMetadataQuickTimeMetadataKeyCameraShutterSpeedAngle() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the exposure period expressed as an angle in minutes (1/60 degree) (e.g. "21600" or "360.00deg"").

func AVMetadataQuickTimeMetadataKeyCameraShutterSpeedTime ¶

func AVMetadataQuickTimeMetadataKeyCameraShutterSpeedTime() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the exposure period expressed as a time per one frame/field period in seconds.

func AVMetadataQuickTimeMetadataKeyCameraWhiteBalance ¶

func AVMetadataQuickTimeMetadataKeyCameraWhiteBalance() *foundation.NSString

A value of type kCMMetadataBaseDataType_UTF8 indicating the white balance value defined by the temperature in Kelvin units (e.g. "5500K" or "5500"). See SMPTE RDD 18.

func AVMetadataQuickTimeMetadataKeyCinematicVideoIntent ¶

func AVMetadataQuickTimeMetadataKeyCinematicVideoIntent() *foundation.NSString

A value of type `kCMMetadataBaseDataType_UInt8` indicating whether this movie is intended as a Cinematic Video (1) or not (0). This movie-level metadata is automatically added (with a value of 1) to a movie recorded using the Cinematic Video API. Clients can override it with a value of 0 to signal that this movie is not to be treated as a Cinematic Video by Apple's software like Photos.

func AVMetadataQuickTimeMetadataKeyCollectionUser ¶

func AVMetadataQuickTimeMetadataKeyCollectionUser() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyComment ¶

func AVMetadataQuickTimeMetadataKeyComment() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyComposer ¶

func AVMetadataQuickTimeMetadataKeyComposer() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyContentIdentifier ¶

func AVMetadataQuickTimeMetadataKeyContentIdentifier() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyCopyright ¶

func AVMetadataQuickTimeMetadataKeyCopyright() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyCreationDate ¶

func AVMetadataQuickTimeMetadataKeyCreationDate() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyCredits ¶

func AVMetadataQuickTimeMetadataKeyCredits() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyDescription ¶

func AVMetadataQuickTimeMetadataKeyDescription() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyDirectionFacing ¶

func AVMetadataQuickTimeMetadataKeyDirectionFacing() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyDirectionMotion ¶

func AVMetadataQuickTimeMetadataKeyDirectionMotion() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyDirector ¶

func AVMetadataQuickTimeMetadataKeyDirector() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyDisplayName ¶

func AVMetadataQuickTimeMetadataKeyDisplayName() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyEncodedBy ¶

func AVMetadataQuickTimeMetadataKeyEncodedBy() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyFullFrameRatePlaybackIntent ¶

func AVMetadataQuickTimeMetadataKeyFullFrameRatePlaybackIntent() *foundation.NSString

A value of type kCMMetadataBaseDataType_UInt8 indicating whether this movie is intended to be played back at the full frame rate (1), or at a slow motion rate (0). Historically, some apps have played movies recorded at frame rates of 120fps or higher in slow motion by default. With the introduction of this metadata, apps that record high-frame-rate movies may add this movie-level metadata to indicate whether the movie is intended to be played at the full frame rate (1) or at a slow motion rate (0). Apps that play movies may use this metadata, when present, to guide their behavior.

func AVMetadataQuickTimeMetadataKeyGenre ¶

func AVMetadataQuickTimeMetadataKeyGenre() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyInformation ¶

func AVMetadataQuickTimeMetadataKeyInformation() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyIsMontage ¶

func AVMetadataQuickTimeMetadataKeyIsMontage() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyKeywords ¶

func AVMetadataQuickTimeMetadataKeyKeywords() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyLocationBody ¶

func AVMetadataQuickTimeMetadataKeyLocationBody() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyLocationDate ¶

func AVMetadataQuickTimeMetadataKeyLocationDate() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyLocationISO6709 ¶

func AVMetadataQuickTimeMetadataKeyLocationISO6709() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyLocationName ¶

func AVMetadataQuickTimeMetadataKeyLocationName() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyLocationNote ¶

func AVMetadataQuickTimeMetadataKeyLocationNote() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyLocationRole ¶

func AVMetadataQuickTimeMetadataKeyLocationRole() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyMake ¶

func AVMetadataQuickTimeMetadataKeyMake() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyModel ¶

func AVMetadataQuickTimeMetadataKeyModel() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyOriginalArtist ¶

func AVMetadataQuickTimeMetadataKeyOriginalArtist() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyPerformer ¶

func AVMetadataQuickTimeMetadataKeyPerformer() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyPhonogramRights ¶

func AVMetadataQuickTimeMetadataKeyPhonogramRights() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyProducer ¶

func AVMetadataQuickTimeMetadataKeyProducer() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyPublisher ¶

func AVMetadataQuickTimeMetadataKeyPublisher() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyRatingUser ¶

func AVMetadataQuickTimeMetadataKeyRatingUser() *foundation.NSString

func AVMetadataQuickTimeMetadataKeySoftware ¶

func AVMetadataQuickTimeMetadataKeySoftware() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyTitle ¶

func AVMetadataQuickTimeMetadataKeyTitle() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyWhiteBalanceByCCTColorMatrices ¶

func AVMetadataQuickTimeMetadataKeyWhiteBalanceByCCTColorMatrices() *foundation.NSString

A value of type kCMMetadataBaseDataType_RawData indicating the reference color translation matrix data for ProRes RAW.

func AVMetadataQuickTimeMetadataKeyWhiteBalanceByCCTWhiteBalanceFactors ¶

func AVMetadataQuickTimeMetadataKeyWhiteBalanceByCCTWhiteBalanceFactors() *foundation.NSString

A value of type kCMMetadataBaseDataType_RawData indicating the reference white balance multiplication factor data for ProRes RAW.

func AVMetadataQuickTimeMetadataKeyYear ¶

func AVMetadataQuickTimeMetadataKeyYear() *foundation.NSString

func AVMetadataQuickTimeMetadataKeyiXML ¶

func AVMetadataQuickTimeMetadataKeyiXML() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyAccessibilityDescription ¶

func AVMetadataQuickTimeUserDataKeyAccessibilityDescription() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyAlbum ¶

func AVMetadataQuickTimeUserDataKeyAlbum() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyArranger ¶

func AVMetadataQuickTimeUserDataKeyArranger() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyArtist ¶

func AVMetadataQuickTimeUserDataKeyArtist() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyAuthor ¶

func AVMetadataQuickTimeUserDataKeyAuthor() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyChapter ¶

func AVMetadataQuickTimeUserDataKeyChapter() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyComment ¶

func AVMetadataQuickTimeUserDataKeyComment() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyComposer ¶

func AVMetadataQuickTimeUserDataKeyComposer() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyCopyright ¶

func AVMetadataQuickTimeUserDataKeyCopyright() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyCreationDate ¶

func AVMetadataQuickTimeUserDataKeyCreationDate() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyCredits ¶

func AVMetadataQuickTimeUserDataKeyCredits() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyDescription ¶

func AVMetadataQuickTimeUserDataKeyDescription() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyDirector ¶

func AVMetadataQuickTimeUserDataKeyDirector() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyDisclaimer ¶

func AVMetadataQuickTimeUserDataKeyDisclaimer() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyEncodedBy ¶

func AVMetadataQuickTimeUserDataKeyEncodedBy() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyFullName ¶

func AVMetadataQuickTimeUserDataKeyFullName() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyGenre ¶

func AVMetadataQuickTimeUserDataKeyGenre() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyHostComputer ¶

func AVMetadataQuickTimeUserDataKeyHostComputer() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyInformation ¶

func AVMetadataQuickTimeUserDataKeyInformation() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyKeywords ¶

func AVMetadataQuickTimeUserDataKeyKeywords() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyLocationISO6709 ¶

func AVMetadataQuickTimeUserDataKeyLocationISO6709() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyMake ¶

func AVMetadataQuickTimeUserDataKeyMake() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyModel ¶

func AVMetadataQuickTimeUserDataKeyModel() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyOriginalArtist ¶

func AVMetadataQuickTimeUserDataKeyOriginalArtist() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyOriginalFormat ¶

func AVMetadataQuickTimeUserDataKeyOriginalFormat() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyOriginalSource ¶

func AVMetadataQuickTimeUserDataKeyOriginalSource() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyPerformers ¶

func AVMetadataQuickTimeUserDataKeyPerformers() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyPhonogramRights ¶

func AVMetadataQuickTimeUserDataKeyPhonogramRights() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyProducer ¶

func AVMetadataQuickTimeUserDataKeyProducer() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyProduct ¶

func AVMetadataQuickTimeUserDataKeyProduct() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyPublisher ¶

func AVMetadataQuickTimeUserDataKeyPublisher() *foundation.NSString

func AVMetadataQuickTimeUserDataKeySoftware ¶

func AVMetadataQuickTimeUserDataKeySoftware() *foundation.NSString

func AVMetadataQuickTimeUserDataKeySpecialPlaybackRequirements ¶

func AVMetadataQuickTimeUserDataKeySpecialPlaybackRequirements() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyTaggedCharacteristic ¶

func AVMetadataQuickTimeUserDataKeyTaggedCharacteristic() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyTrack ¶

func AVMetadataQuickTimeUserDataKeyTrack() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyTrackName ¶

func AVMetadataQuickTimeUserDataKeyTrackName() *foundation.NSString
func AVMetadataQuickTimeUserDataKeyURLLink() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyWarning ¶

func AVMetadataQuickTimeUserDataKeyWarning() *foundation.NSString

func AVMetadataQuickTimeUserDataKeyWriter ¶

func AVMetadataQuickTimeUserDataKeyWriter() *foundation.NSString

func AVMetadataiTunesMetadataKeyAccountKind ¶

func AVMetadataiTunesMetadataKeyAccountKind() *foundation.NSString

func AVMetadataiTunesMetadataKeyAcknowledgement ¶

func AVMetadataiTunesMetadataKeyAcknowledgement() *foundation.NSString

func AVMetadataiTunesMetadataKeyAlbum ¶

func AVMetadataiTunesMetadataKeyAlbum() *foundation.NSString

func AVMetadataiTunesMetadataKeyAlbumArtist ¶

func AVMetadataiTunesMetadataKeyAlbumArtist() *foundation.NSString

func AVMetadataiTunesMetadataKeyAppleID ¶

func AVMetadataiTunesMetadataKeyAppleID() *foundation.NSString

func AVMetadataiTunesMetadataKeyArranger ¶

func AVMetadataiTunesMetadataKeyArranger() *foundation.NSString

func AVMetadataiTunesMetadataKeyArtDirector ¶

func AVMetadataiTunesMetadataKeyArtDirector() *foundation.NSString

func AVMetadataiTunesMetadataKeyArtist ¶

func AVMetadataiTunesMetadataKeyArtist() *foundation.NSString

func AVMetadataiTunesMetadataKeyArtistID ¶

func AVMetadataiTunesMetadataKeyArtistID() *foundation.NSString

func AVMetadataiTunesMetadataKeyAuthor ¶

func AVMetadataiTunesMetadataKeyAuthor() *foundation.NSString

func AVMetadataiTunesMetadataKeyBeatsPerMin ¶

func AVMetadataiTunesMetadataKeyBeatsPerMin() *foundation.NSString

func AVMetadataiTunesMetadataKeyComposer ¶

func AVMetadataiTunesMetadataKeyComposer() *foundation.NSString

func AVMetadataiTunesMetadataKeyConductor ¶

func AVMetadataiTunesMetadataKeyConductor() *foundation.NSString

func AVMetadataiTunesMetadataKeyContentRating ¶

func AVMetadataiTunesMetadataKeyContentRating() *foundation.NSString

func AVMetadataiTunesMetadataKeyCopyright ¶

func AVMetadataiTunesMetadataKeyCopyright() *foundation.NSString

func AVMetadataiTunesMetadataKeyCoverArt ¶

func AVMetadataiTunesMetadataKeyCoverArt() *foundation.NSString

func AVMetadataiTunesMetadataKeyCredits ¶

func AVMetadataiTunesMetadataKeyCredits() *foundation.NSString

func AVMetadataiTunesMetadataKeyDescription ¶

func AVMetadataiTunesMetadataKeyDescription() *foundation.NSString

func AVMetadataiTunesMetadataKeyDirector ¶

func AVMetadataiTunesMetadataKeyDirector() *foundation.NSString

func AVMetadataiTunesMetadataKeyDiscCompilation ¶

func AVMetadataiTunesMetadataKeyDiscCompilation() *foundation.NSString

func AVMetadataiTunesMetadataKeyDiscNumber ¶

func AVMetadataiTunesMetadataKeyDiscNumber() *foundation.NSString

func AVMetadataiTunesMetadataKeyEQ ¶

func AVMetadataiTunesMetadataKeyEQ() *foundation.NSString

func AVMetadataiTunesMetadataKeyEncodedBy ¶

func AVMetadataiTunesMetadataKeyEncodedBy() *foundation.NSString

func AVMetadataiTunesMetadataKeyEncodingTool ¶

func AVMetadataiTunesMetadataKeyEncodingTool() *foundation.NSString

func AVMetadataiTunesMetadataKeyExecProducer ¶

func AVMetadataiTunesMetadataKeyExecProducer() *foundation.NSString

func AVMetadataiTunesMetadataKeyGenreID ¶

func AVMetadataiTunesMetadataKeyGenreID() *foundation.NSString

func AVMetadataiTunesMetadataKeyGrouping ¶

func AVMetadataiTunesMetadataKeyGrouping() *foundation.NSString

func AVMetadataiTunesMetadataKeyLinerNotes ¶

func AVMetadataiTunesMetadataKeyLinerNotes() *foundation.NSString

func AVMetadataiTunesMetadataKeyLyrics ¶

func AVMetadataiTunesMetadataKeyLyrics() *foundation.NSString

func AVMetadataiTunesMetadataKeyOnlineExtras ¶

func AVMetadataiTunesMetadataKeyOnlineExtras() *foundation.NSString

func AVMetadataiTunesMetadataKeyOriginalArtist ¶

func AVMetadataiTunesMetadataKeyOriginalArtist() *foundation.NSString

func AVMetadataiTunesMetadataKeyPerformer ¶

func AVMetadataiTunesMetadataKeyPerformer() *foundation.NSString

func AVMetadataiTunesMetadataKeyPhonogramRights ¶

func AVMetadataiTunesMetadataKeyPhonogramRights() *foundation.NSString

func AVMetadataiTunesMetadataKeyPlaylistID ¶

func AVMetadataiTunesMetadataKeyPlaylistID() *foundation.NSString

func AVMetadataiTunesMetadataKeyPredefinedGenre ¶

func AVMetadataiTunesMetadataKeyPredefinedGenre() *foundation.NSString

func AVMetadataiTunesMetadataKeyProducer ¶

func AVMetadataiTunesMetadataKeyProducer() *foundation.NSString

func AVMetadataiTunesMetadataKeyPublisher ¶

func AVMetadataiTunesMetadataKeyPublisher() *foundation.NSString

func AVMetadataiTunesMetadataKeyRecordCompany ¶

func AVMetadataiTunesMetadataKeyRecordCompany() *foundation.NSString

func AVMetadataiTunesMetadataKeyReleaseDate ¶

func AVMetadataiTunesMetadataKeyReleaseDate() *foundation.NSString

func AVMetadataiTunesMetadataKeySoloist ¶

func AVMetadataiTunesMetadataKeySoloist() *foundation.NSString

func AVMetadataiTunesMetadataKeySongID ¶

func AVMetadataiTunesMetadataKeySongID() *foundation.NSString

func AVMetadataiTunesMetadataKeySongName ¶

func AVMetadataiTunesMetadataKeySongName() *foundation.NSString

func AVMetadataiTunesMetadataKeySoundEngineer ¶

func AVMetadataiTunesMetadataKeySoundEngineer() *foundation.NSString

func AVMetadataiTunesMetadataKeyThanks ¶

func AVMetadataiTunesMetadataKeyThanks() *foundation.NSString

func AVMetadataiTunesMetadataKeyTrackNumber ¶

func AVMetadataiTunesMetadataKeyTrackNumber() *foundation.NSString

func AVMetadataiTunesMetadataKeyTrackSubTitle ¶

func AVMetadataiTunesMetadataKeyTrackSubTitle() *foundation.NSString

func AVMetadataiTunesMetadataKeyUserComment ¶

func AVMetadataiTunesMetadataKeyUserComment() *foundation.NSString

func AVMetadataiTunesMetadataKeyUserGenre ¶

func AVMetadataiTunesMetadataKeyUserGenre() *foundation.NSString

func AVMovieMovieTypes ¶

func AVMovieMovieTypes() *foundation.NSArray[*foundation.NSString]

@method movieTypes @abstract Provides the file types the AVMovie class understands. @result An NSArray of UTIs identifying the file types the AVMovie class understands.

func AVMovieReferenceRestrictionsKey ¶

func AVMovieReferenceRestrictionsKey() uintptr

@constant AVMovieReferenceRestrictionsKey @abstract Indicates the restrictions used by the movie when resolving references to external media data. The value of this key is an NSNumber wrapping an AVAssetReferenceRestrictions enum value or the logical combination of multiple such values. See AVAsset.h for the declaration of the AVAssetReferenceRestrictions enum. @discussion Some movies can contain references to media data stored outside the movie's container, for example in another file. This key can be used to specify a policy to use when these references are encountered. If a movie contains one or more references of a type that is forbidden by the reference restrictions, loading of movie properties will fail. In addition, such a movie cannot be used with other AVFoundation modules, such as AVPlayerItem or AVAssetExportSession.

func AVMovieShouldSupportAliasDataReferencesKey ¶

func AVMovieShouldSupportAliasDataReferencesKey() uintptr

@constant AVMovieShouldSupportAliasDataReferencesKey @abstract Indicates whether alias data references in the movie should be parsed and resolved. @discussion Default is NO. Although the majority of QuickTime movie files contain all of the media data they require, some contain references to media stored in other files. While AVFoundation and CoreMedia typically employ a URL reference for this purpose, older implementations such as QuickTime 7 have commonly employed a Macintosh alias instead, as documented in the QuickTime File Format specification. If your application must work with legacy QuickTime movie files containing alias-based references to media data stored in other files, the use of this AVMovie initialization option is appropriate. AVMovie and AVMutableMovie do not create movies using alias data references to external media files. If you provide a value for AVMovieReferenceRestrictionsKey, restrictions will be observed for resolved alias references just as they are for URL references. For more details about alias resolution, consult documentation of the bookmark-related interfaces of NSURL.

func AVMutableVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandlerCompletionHandler ¶

func AVMutableVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandlerCompletionHandler(asset *AVAsset, applier func(*AVAsynchronousCIImageFilteringRequest), completionHandler func(*AVMutableVideoComposition, unsafe.Pointer))

Vends a new instance of AVMutableVideoComposition with values and instructions that will apply the specified handler block to video frames represented as instances of CIImage. The new AVMutableVideoComposition will cause the specified handler block to be called to filter each frame of the asset's first enabled video track. The handler block should use the properties of the provided AVAsynchronousCIImageFilteringRequest and respond using finishWithImage:context: with a "filtered" new CIImage (or the provided source image for no affect). In the event of an error, respond to the request using finishWithError:. The error can be observed via AVPlayerItemFailedToPlayToEndTimeNotification, see AVPlayerItemFailedToPlayToEndTimeErrorKey in notification payload. The client can set sourceTrackIDForFrameTiming to kCMPersistentTrackID_Invalid and frameDuration to an appropriate value in order to specify the maximum output frame rate independent of the source track timing. The video composition will also have the following values for its properties: - The original timing of the asset's first enabled video track will be used. - A renderSize that encompasses the asset's first enabled video track respecting the track's preferredTransform. - A renderScale of 1.0. The default CIContext has the following properties: - iOS: Device RGB color space - macOS: sRGB color space Example usage: ```objc [AVMutableVideoComposition videoCompositionWithAsset:srcAsset applyingCIFiltersWithHandler: ^(AVAsynchronousCIImageFilteringRequest *request) { NSError *err = nil; CIImage *filtered = myRenderer(request, &err); if (filtered) [request finishWithImage:filtered context:nil]; else [request finishWithError:err]; } completionHandler: ^(AVMutableVideoComposition * _Nullable videoComposition, NSError * _Nullable error) { if (videoComposition != nil) { playerItem.videoComposition = videoComposition else { // handle error }]; ``` - Parameter asset: An instance of AVAsset. - Parameter completionHandler: A block that is invoked when the new video composition has finished being created. If the `videoComposition` parameter is nil, the `error` parameter describes the failure that occurred.

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAssetCompletionHandler ¶

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAssetCompletionHandler(asset *AVAsset, completionHandler func(*AVMutableVideoComposition, unsafe.Pointer))

Vends a new instance of AVMutableVideoComposition with values and instructions suitable for presenting the video tracks of the specified asset according to its temporal and geometric properties and those of its tracks. The new AVMutableVideoComposition will have instructions that respect the spatial properties and timeRanges of the specified asset's video tracks. The client can set sourceTrackIDForFrameTiming to kCMPersistentTrackID_Invalid and frameDuration to an appropriate value in order to specify the maximum output frame rate independent of the source track timing. It will also have the following values for its properties: - If the asset has exactly one video track, the original timing of the source video track will be used. If the asset has more than one video track, and the nominal frame rate of any of video tracks is known, the reciprocal of the greatest known nominalFrameRate will be used as the value of frameDuration. Otherwise, a default framerate of 30fps is used. - If the specified asset is an instance of AVComposition, the renderSize will be set to the naturalSize of the AVComposition; otherwise the renderSize will be set to a value that encompasses all of the asset's video tracks. - A renderScale of 1.0. - A nil animationTool. If the specified asset has no video tracks, this method will return an AVMutableVideoComposition instance with an empty collection of instructions. - Parameter asset: An instance of AVAsset. - Parameter completionHandler: A block that is invoked when the new video composition has finished being created. If the `videoComposition` parameter is nil, the `error` parameter describes the failure that occurred.

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAssetPrototypeInstructionCompletionHandler ¶

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAssetPrototypeInstructionCompletionHandler(asset *AVAsset, prototypeInstruction *AVVideoCompositionInstruction, completionHandler func(*AVMutableVideoComposition, unsafe.Pointer))

Vends a new instance of AVMutableVideoComposition with values and instructions suitable for presenting the video tracks of the specified asset according to its temporal and geometric properties and those of its tracks, and also overrides default properties with those from a prototypeInstruction. Also see videoCompositionWithPropertiesOfAsset:completionHandler:. The new AVMutableVideoComposition will have instructions that respect the spatial properties and timeRanges of the specified asset's video tracks. Anything not pertaining to spatial layout and timing, such as background color for their composition or post-processing behaviors, is eligible to be specified via a prototype instruction. Example: To add a background color, ```objc myPrototypeInstruction = [[AVMutableVideoCompositionInstruction alloc] init]; myPrototypeInstruction.backgroundColor = myCGColorRef; // Do not use constant CGColorRef colors here. myVideoComposition = [AVVideoComposition videoCompositionWithPropertiesOfAsset:myAsset prototypeInstruction:myPrototypeInstruction completionHandler:^(AVMutableVideoComposition * _Nullable myVideoComposition, NSError * _Nullable error) { if (myVideoComposition != nil) { // use myVideoComposition } else { // handle error } }]; ``` - Parameter asset: An instance of AVAsset. - Parameter prototypeInstruction: Custom instructions that the client can choose to override. - Parameter completionHandler: A block that is invoked when the new video composition has finished being created. If the `videoComposition` parameter is nil, the `error` parameter describes the failure that occurred.

func AVOutputSettingsAssistantAvailableOutputSettingsPresets ¶

func AVOutputSettingsAssistantAvailableOutputSettingsPresets() *foundation.NSArray[*foundation.NSString]

@method availableOutputSettingsPresets @abstract Returns the list of presets that can be used to create an instance of AVOutputSettingsAssistant @result An NSArray of NSString objects, each of which is a preset identifier @discussion Each preset in the returned list can be passed in to +outputSettingsAssistantWithPreset: to create a new instance of AVOutputSettingsAssistant. On iOS, the returned array may be different between different device models.

func AVOutputSettingsPreset640x480 ¶

func AVOutputSettingsPreset640x480() uintptr

func AVOutputSettingsPreset960x540 ¶

func AVOutputSettingsPreset960x540() uintptr

func AVOutputSettingsPreset1280x720 ¶

func AVOutputSettingsPreset1280x720() uintptr

func AVOutputSettingsPreset1920x1080 ¶

func AVOutputSettingsPreset1920x1080() uintptr

func AVOutputSettingsPreset3840x2160 ¶

func AVOutputSettingsPreset3840x2160() uintptr

func AVOutputSettingsPresetHEVC1920x1080 ¶

func AVOutputSettingsPresetHEVC1920x1080() uintptr

func AVOutputSettingsPresetHEVC1920x1080WithAlpha ¶

func AVOutputSettingsPresetHEVC1920x1080WithAlpha() uintptr

func AVOutputSettingsPresetHEVC3840x2160 ¶

func AVOutputSettingsPresetHEVC3840x2160() uintptr

func AVOutputSettingsPresetHEVC3840x2160WithAlpha ¶

func AVOutputSettingsPresetHEVC3840x2160WithAlpha() uintptr

func AVOutputSettingsPresetHEVC4320x2160 ¶

func AVOutputSettingsPresetHEVC4320x2160() *foundation.NSString

func AVOutputSettingsPresetHEVC7680x4320 ¶

func AVOutputSettingsPresetHEVC7680x4320() *foundation.NSString

func AVOutputSettingsPresetMVHEVC960x960 ¶

func AVOutputSettingsPresetMVHEVC960x960() uintptr

func AVOutputSettingsPresetMVHEVC1440x1440 ¶

func AVOutputSettingsPresetMVHEVC1440x1440() uintptr

func AVOutputSettingsPresetMVHEVC4320x4320 ¶

func AVOutputSettingsPresetMVHEVC4320x4320() *foundation.NSString

func AVOutputSettingsPresetMVHEVC7680x7680 ¶

func AVOutputSettingsPresetMVHEVC7680x7680() *foundation.NSString

func AVPlaybackCoordinatorOtherParticipantsDidChangeNotification ¶

func AVPlaybackCoordinatorOtherParticipantsDidChangeNotification() uintptr

Posted by the playback coordinator when its otherParticipants property changes.

func AVPlaybackCoordinatorSuspensionReasonsDidChangeNotification ¶

func AVPlaybackCoordinatorSuspensionReasonsDidChangeNotification() uintptr

Posted by the playback coordinator when its suspensionReasons property changes.

func AVPlayerEligibleForHDRPlayback ¶

func AVPlayerEligibleForHDRPlayback() bool

Indicates whether HDR content can be played to an appropriate display. This property is YES if an HDR display is available and the device is capable of playing HDR content from an appropriate AVAsset, NO otherwise. This property does not indicate whether video contains HDR content, whether HDR video is currently playing, or whether video is playing on an HDR display. This property is not KVO observable.

func AVPlayerEligibleForHDRPlaybackDidChangeNotification ¶

func AVPlayerEligibleForHDRPlaybackDidChangeNotification() *foundation.NSString

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncNotification ¶

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncNotification() *foundation.NSString

@constant AVPlayerIntegratedTimelineSnapshotsOutOfSyncNotification @abstract A notification which is posted when the snapshot objects provided by this timeline would be out of sync with the current timeline state. See keys below.

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonCurrentSegmentChanged ¶

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonCurrentSegmentChanged() *foundation.NSString

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonKey ¶

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonKey() uintptr

@constant AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonKey @abstract Indicates the reason for the snapshot out of sync notification.

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonLoadedTimeRangesChanged ¶

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonLoadedTimeRangesChanged() *foundation.NSString

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonSegmentsChanged ¶

func AVPlayerIntegratedTimelineSnapshotsOutOfSyncReasonSegmentsChanged() *foundation.NSString

func AVPlayerInterstitialEventJoinCue ¶

func AVPlayerInterstitialEventJoinCue() *foundation.NSString

Event playback should occur before starting primary playback, regardless of initial primary playback position.

func AVPlayerInterstitialEventLeaveCue ¶

func AVPlayerInterstitialEventLeaveCue() *foundation.NSString

Event playback should occur after primary playback ends without error, either at the end of the primary asset or at the client-specified forward playback end time.

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeErrorKey ¶

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeErrorKey() uintptr

The dictionary key for the NSError in the payload of the AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeNotification. The value corresponding to this key is of type NSError. This key only exists in the payload of AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeNotification if AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeStatusKey in the same payload points to a value of AVPlayerInterstitialEventAssetListResponseStatusUnavailable.

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeEventKey ¶

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeEventKey() uintptr

The dictionary key for the AVPlayerInterstitial event that had its asset list response status changed in the payload of the AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeNotification. The value corresponding to this key is of type AVPlayerInterstitialEvent.

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeNotification ¶

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeNotification() *foundation.NSString

A notification that is posted whenever an AVPlayerInterstitialEvent's asset list response status changes. Carries a userInfo dictionary that can contain the following keys and values: 1. AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeEventKey, with a value that indicates the AVPlayerInterstitialEvent for which the asset response status has changed. 2. AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeStatusKey, with a value of type AVPlayerInterstitialEventAssetListResponseStatus, indicating the changed asset response status. 3. AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeErrorKey, with a value of type NSError that carries additional information about the failure to read the asset list. This key is only present when the new AVPlayerInterstitialEventAssetListResponseStatus is AVPlayerInterstitialEventAssetListResponseStatusUnavailable.

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeStatusKey ¶

func AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeStatusKey() uintptr

The dictionary key for the asset list response status in the payload of the AVPlayerInterstitialEventMonitorAssetListResponseStatusDidChangeNotification. The value corresponding to this key is of type AVPlayerInterstitialEventAssetListResponseStatus.

func AVPlayerInterstitialEventMonitorCurrentEventDidChangeNotification ¶

func AVPlayerInterstitialEventMonitorCurrentEventDidChangeNotification() *foundation.NSString

A notification that's posted whenever the currentEvent of an AVPlayerInterstitialEventMonitor changes.

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeEventKey ¶

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeEventKey() uintptr

The dictionary key for the AVPlayerInterstitial event that had its skippable event state changed in the payload of the AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeNotification. The value corresponding to this key is of type AVPlayerInterstitialEvent.

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeNotification ¶

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeNotification() *foundation.NSString

A notification that's posted whenever the currentEventSkippableState of an AVPlayerInterstitialEventMonitor changes.

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeSkipControlLabelKey ¶

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeSkipControlLabelKey() uintptr

The dictionary key for the skip label of the event in the payload of the AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeNotification. The value corresponding to this key is an NSString that's the localized skip label if a localizedStringsBundle is set on the AVPlayerInterstitialEventController and a skipControlLocalizedLabelBundleKey on the AVPlayerInterstitialEvent whose skippable event state changed. Note that this key will not be present if there is no localizedStringsBundle set, or if the currentEventSkippableState changed to AVPlayerInterstitialEventSkippableEventStateNotSkippable.

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeStateKey ¶

func AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeStateKey() uintptr

The dictionary key for the skippable event state in the payload of the AVPlayerInterstitialEventMonitorCurrentEventSkippableStateDidChangeNotification. The value corresponding to this key is an NSNumber containing type AVPlayerInterstitialEventSkippableEventState.

func AVPlayerInterstitialEventMonitorCurrentEventSkippedEventKey ¶

func AVPlayerInterstitialEventMonitorCurrentEventSkippedEventKey() uintptr

The dictionary key for the AVPlayerInterstitialEvent that was skipped in the payload of the AVPlayerInterstitialEventMonitorCurrentEventSkippedNotification. The value corresponding to this key is of type AVPlayerInterstitialEvent.

func AVPlayerInterstitialEventMonitorCurrentEventSkippedNotification ¶

func AVPlayerInterstitialEventMonitorCurrentEventSkippedNotification() *foundation.NSString

A notification that's posted whenever an event was skipped via skip control.

func AVPlayerInterstitialEventMonitorEventsDidChangeNotification ¶

func AVPlayerInterstitialEventMonitorEventsDidChangeNotification() *foundation.NSString

A notification that's posted whenever the value of events of an AVPlayerInterstitialEventMonitor is changed.

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishDidPlayEntireEventKey ¶

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishDidPlayEntireEventKey() uintptr

The dictionary key to indicate whether the event that finished playing was fully played out in the payload of the AVPlayerInterstitialEventMonitorInterstitialEventDidFinishNotification. The value corresponding to this key is of type NSNumber with a BOOL value.

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishEventKey ¶

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishEventKey() uintptr

The dictionary key for the AVPlayerInterstitialEvent that finished playing in the payload of the AVPlayerInterstitialEventMonitorInterstitialEventDidFinishNotification. The value corresponding to this key is of type AVPlayerInterstitialEvent.

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishNotification ¶

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishNotification() *foundation.NSString

A notification that is posted whenever an AVPlayerInterstitialEvent finished playing. Carries a userInfo dictionary that can contain the following keys and values: 1. AVPlayerInterstitialEventMonitorInterstitialEventDidFinishEventKey, with a value that indicates the AVPlayerInterstitialEvent that finished playing. 2. AVPlayerInterstitialEventMonitorInterstitialEventDidFinishPlayoutTimeKey, with a value that indicates how long that AVPlayerInterstitialEvent played out for. 3. AVPlayerInterstitialEventMonitorInterstitialEventDidFinishDidPlayEntireEventKey, with a value that indicates whether the AVPlayerInterstitialEvent was fully played out. Note that cancelling an AVPlayerInterstitialEvent after playback started but prior to playback finishing will also trigger this event.

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishPlayoutTimeKey ¶

func AVPlayerInterstitialEventMonitorInterstitialEventDidFinishPlayoutTimeKey() uintptr

The dictionary key for the playout time of the event that finished playing in the payload of the AVPlayerInterstitialEventMonitorInterstitialEventDidFinishNotification. The value corresponding to this key is of type CMTime as a NSDictionary.

func AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledErrorKey ¶

func AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledErrorKey() uintptr

The dictionary key to indicate whether the event that was unscheduled was due to an error. The value corresponding to this key is of type NSError. This key only exists in the payload of AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledNotification if the interstitial event was unscheduled due to an error.

func AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledEventKey ¶

func AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledEventKey() uintptr

The dictionary key for the AVPlayerInterstitialEvent that was unscheduled in the payload of the AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledNotification. The value corresponding to this key is of type AVPlayerInterstitialEvent.

func AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledNotification ¶

func AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledNotification() *foundation.NSString

A notification that is posted whenever an AVPlayerInterstitialEvent with loaded assets was unscheduled prior to playing. Carries a userInfo dictionary that can contain the following keys and values: 1. AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledEventKey, with a value that indicates which AVPlayerInterstitialEvent was unscheduled. 2. AVPlayerInterstitialEventMonitorInterstitialEventWasUnscheduledErrorKey, with an NSError value. This key will only be present if the AVPlayerInterstitialEvent was unscheduled due to an error.

func AVPlayerInterstitialEventMonitorScheduleRequestCompletedNotification ¶

func AVPlayerInterstitialEventMonitorScheduleRequestCompletedNotification() *foundation.NSString

A notification that is posted whenever a daterange-schedule request completes. The userInfo dictionary can contain the following keys and values: 1. AVPlayerInterstitialEventMonitorScheduleRequestIdentifierKey, whose value is an NSString identifying the schedule. 2. AVPlayerInterstitialEventMonitorScheduleRequestResponseKey, whose value is an NSData carrying the JSON response. Absent if request failed. 3. AVPlayerInterstitialEventMonitorScheduleRequestErrorKey, whose value is an NSError.

func AVPlayerInterstitialEventMonitorScheduleRequestErrorKey ¶

func AVPlayerInterstitialEventMonitorScheduleRequestErrorKey() uintptr

userInfo dictionary key for the AVPlayerInterstitialEventMonitorScheduleRequestCompletedNotification. Value is NSError. Absent if the request succeeded

func AVPlayerInterstitialEventMonitorScheduleRequestIdentifierKey ¶

func AVPlayerInterstitialEventMonitorScheduleRequestIdentifierKey() uintptr

userInfo dictionary key for the AVPlayerInterstitialEventMonitorScheduleRequestCompletedNotification. Value is NSString.

func AVPlayerInterstitialEventMonitorScheduleRequestResponseKey ¶

func AVPlayerInterstitialEventMonitorScheduleRequestResponseKey() uintptr

userInfo dictionary key for the AVPlayerInterstitialEventMonitorScheduleRequestCompletedNotification. Value is NSData. Absent if the request failed.

func AVPlayerInterstitialEventNoCue ¶

func AVPlayerInterstitialEventNoCue() *foundation.NSString

No cue specified; event playback should start at event time (or date).

func AVPlayerIsObservationEnabled ¶

func AVPlayerIsObservationEnabled() bool

func AVPlayerItemDidPlayToEndTimeNotification ¶

func AVPlayerItemDidPlayToEndTimeNotification() *foundation.NSString

func AVPlayerItemFailedToPlayToEndTimeErrorKey ¶

func AVPlayerItemFailedToPlayToEndTimeErrorKey() uintptr

func AVPlayerItemFailedToPlayToEndTimeNotification ¶

func AVPlayerItemFailedToPlayToEndTimeNotification() *foundation.NSString

func AVPlayerItemLegibleOutputTextStylingResolutionDefault ¶

func AVPlayerItemLegibleOutputTextStylingResolutionDefault() uintptr

@constant AVPlayerItemLegibleOutputTextStylingResolutionDefault @abstract Specify this level of text styling resolution to receive attributed strings from an AVPlayerItemLegibleOutput that include the same level of styling information that AVFoundation would use itself to render text within an AVPlayerLayer. The text styling will accommodate user-level Media Accessibility settings.

func AVPlayerItemLegibleOutputTextStylingResolutionSourceAndRulesOnly ¶

func AVPlayerItemLegibleOutputTextStylingResolutionSourceAndRulesOnly() uintptr

@constant AVPlayerItemLegibleOutputTextStylingResolutionSourceAndRulesOnly @abstract Specify this level of text styling resolution to receive only the styling present in the source media and the styling provided via AVPlayerItem.textStyleRules. @discussion This level of resolution excludes styling provided by the user-level Media Accessibility settings. You would typically use it if you wish to override the styling specified in source media. If you do this, you are strongly encouraged to allow your custom styling in turn to be overriden by user preferences for text styling that are available as Media Accessibility settings.

func AVPlayerItemMediaSelectionDidChangeNotification ¶

func AVPlayerItemMediaSelectionDidChangeNotification() *foundation.NSString

func AVPlayerItemNewAccessLogEntryNotification ¶

func AVPlayerItemNewAccessLogEntryNotification() *foundation.NSString

func AVPlayerItemNewErrorLogEntryNotification ¶

func AVPlayerItemNewErrorLogEntryNotification() *foundation.NSString

func AVPlayerItemPlaybackStalledNotification ¶

func AVPlayerItemPlaybackStalledNotification() *foundation.NSString

func AVPlayerItemRecommendedTimeOffsetFromLiveDidChangeNotification ¶

func AVPlayerItemRecommendedTimeOffsetFromLiveDidChangeNotification() *foundation.NSString

func AVPlayerItemTimeJumpedNotification ¶

func AVPlayerItemTimeJumpedNotification() *foundation.NSString

func AVPlayerItemTimeJumpedOriginatingParticipantKey ¶

func AVPlayerItemTimeJumpedOriginatingParticipantKey() uintptr

Indicates a time jump was caused by another participant connected through AVPlayerPlaybackCoordinator. Informs the receiver of an AVPlayerItemTimeJumpedNotification that a time jump originated from another AVCoordinatedPlaybackParticipant connected through AVPlayerPlaybackCoordinator. This can be used to inform UI showing why the current time changed. The type of the value for this key is an AVCoordinatedPlaybackParticipant, which is part of the AVPlayerPlaybackCoordinator.otherParticipants array.

func AVPlayerItemTrackVideoFieldModeDeinterlaceFields ¶

func AVPlayerItemTrackVideoFieldModeDeinterlaceFields() uintptr

@constant AVPlayerItemTrackVideoFieldModeDeinterlaceFields @abstract Use with videoFieldMode property to request deinterlacing of video fields.

func AVPlayerRateDidChangeNotification ¶

func AVPlayerRateDidChangeNotification() *foundation.NSString

Indicates a player rate change. Posted by the player when its rate changes. Similar to KVO of AVPlayer.rate, but providing additional information about the rate change in the userInfo. See keys below.

func AVPlayerRateDidChangeOriginatingParticipantKey ¶

func AVPlayerRateDidChangeOriginatingParticipantKey() uintptr

Indicates a rate change was caused by another participant connected through AVPlayerPlaybackCoordinator. Informs the receiver of an AVPlayerRateDidChangeNotification about a rate change originated from another AVCoordinatedPlaybackParticipant connected through AVPlayerPlaybackCoordinator. This can be used to inform UI showing why the playback rate changed. The type of the value for this key is an AVCoordinatedPlaybackParticipant, which is part of the AVPlayerPlaybackCoordinator.otherParticipants array.

func AVPlayerRateDidChangeReasonAppBackgrounded ¶

func AVPlayerRateDidChangeReasonAppBackgrounded() uintptr

func AVPlayerRateDidChangeReasonAudioSessionInterrupted ¶

func AVPlayerRateDidChangeReasonAudioSessionInterrupted() uintptr

func AVPlayerRateDidChangeReasonKey ¶

func AVPlayerRateDidChangeReasonKey() uintptr

Indicates a reason for the rate change notification. The value corresponding to this key is of type AVPlayerRateDidChangeReason.

func AVPlayerRateDidChangeReasonPlayheadReachedLiveEdge ¶

func AVPlayerRateDidChangeReasonPlayheadReachedLiveEdge() *foundation.NSString

func AVPlayerRateDidChangeReasonReversePlaybackReachedStartOfSeekableRange ¶

func AVPlayerRateDidChangeReasonReversePlaybackReachedStartOfSeekableRange() *foundation.NSString

func AVPlayerRateDidChangeReasonSetRateCalled ¶

func AVPlayerRateDidChangeReasonSetRateCalled() uintptr

func AVPlayerRateDidChangeReasonSetRateFailed ¶

func AVPlayerRateDidChangeReasonSetRateFailed() uintptr

func AVPlayerSetObservationEnabled ¶

func AVPlayerSetObservationEnabled(observationEnabled bool)

func AVPlayerWaitingDuringInterstitialEventReason ¶

func AVPlayerWaitingDuringInterstitialEventReason() *foundation.NSString

Indicates that the player is waiting for the completion of an interstitial event. The player is waiting for playback because an interstitial event is currently in progress. Interstitial events can be monitored via use of an AVPlayerInterstitialEventMonitor.

func AVPlayerWaitingForCoordinatedPlaybackReason ¶

func AVPlayerWaitingForCoordinatedPlaybackReason() uintptr

Indicates that the player is waiting for another participant connected through its AVPlayerPlaybackCoordinator. The player is waiting for playback because its connected AVPlayerPlaybackCoordinator requires information from one of the other participants before playback can start.

func AVPlayerWaitingToMinimizeStallsReason ¶

func AVPlayerWaitingToMinimizeStallsReason() *foundation.NSString

Indicates that the player is waiting for appropriate playback buffer conditions before starting playback The player is waiting for playback because automaticallyWaitToMinimizeStalling is YES and playback at the specified rate would likely cause the playback buffer to become empty before playback completes. Playback will resume when 1) playback at the specified rate will likely complete without a stall or 2) the playback buffer becomes full, meaning no forther buffering of media data is possible. When the value of automaticallyWaitsToMinimizeStalling is NO, timeControlStatus cannot become AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate for this reason.

func AVPlayerWaitingWhileEvaluatingBufferingRateReason ¶

func AVPlayerWaitingWhileEvaluatingBufferingRateReason() *foundation.NSString

Indicates that the player is monitoring the playback buffer fill rate to determine if playback is likely to complete without interruptions. The player is waiting for playback because automaticallyWaitToMinimizeStalling is YES and it has not yet determined if starting playback at the specified rate would likely cause the buffer to become empty. When the brief initial monitoring period is over, either playback will begin or the value of reasonForWaitingToPlayAtSpecifiedRate will switch to AVPlayerWaitingToMinimizeStallsReason. Recommended practice is not to show UI indicating the waiting state to the user while the value of reasonForWaitingToPlayAtSpecifiedRate is AVPlayerWaitingWhileEvaluatingBufferingRateReason.

func AVPlayerWaitingWithNoItemToPlayReason ¶

func AVPlayerWaitingWithNoItemToPlayReason() *foundation.NSString

Indicates that the AVPlayer is waiting because its currentItem is nil The player is waiting for playback because automaticallyWaitToMinimizeStalling is YES and the value of currentItem is nil. When an item becomes available, either because of a call to -replaceCurrentItemWithPlayerItem: or -insertItem: afterItem:, playback will begin or the value of reasonForWaitingToPlay will change.

func AVRouteDetectorMultipleRoutesDetectedDidChangeNotification ¶

func AVRouteDetectorMultipleRoutesDetectedDidChangeNotification() uintptr

@constant AVRouteDetectorMultipleRoutesDetectedDidChangeNotification @abstract Posted when the value of multipleRoutesDetected changes.

func AVSampleBufferAttachContentKey ¶

func AVSampleBufferAttachContentKey(sbuf unsafe.Pointer, contentKey *AVContentKey, outError unsafe.Pointer) bool

Attaches an AVContentKey to a CMSampleBuffer for the purpose of content decryption. The client is expected to attach AVContentKeys to CMSampleBuffers that have been created by the client for enqueueing with AVSampleBufferDisplayLayer or AVSampleBufferAudioRenderer, for which the AVContentKeySpecifier matches indications of suitability that are available to the client according to the content key system that's in use. - Parameter sbuf: The sample buffer to which the content key is to be attached. - Parameter contentKey: The content key to be attached. - Parameter outError: If the result is NO and errorOut is non-NULL, the location referenced by errorOut receives an instance of NSError that describes the reason for failure to attach the content key.

func AVSampleBufferAudioRendererFlushTimeKey ¶

func AVSampleBufferAudioRendererFlushTimeKey() uintptr

@constant AVSampleBufferAudioRendererFlushTimeKey @abstract The presentation timestamp of the first enqueued sample that was flushed. @discussion The value of this key is an NSValue wrapping a CMTime.

func AVSampleBufferAudioRendererOutputConfigurationDidChangeNotification ¶

func AVSampleBufferAudioRendererOutputConfigurationDidChangeNotification() *foundation.NSString

@constant AVSampleBufferAudioRendererOutputConfigurationDidChangeNotification @abstract A notification that indicates the hardware configuration does not match the enqueued data format. @discussion The output configuration of the playback hardware might change during the playback session if other clients play content with different format. In such cases, if the media content format does not match the hardware configuration it would produce suboptimal rendering of the enqueued media data. When the framework detects such mismatch it will issue this notification, so the client can flush the renderer and re-enqueue the sample buffers from the current media playhead, which will configure the hardware based on the format of newly enqueued sample buffers.

func AVSampleBufferAudioRendererWasFlushedAutomaticallyNotification ¶

func AVSampleBufferAudioRendererWasFlushedAutomaticallyNotification() *foundation.NSString

@constant AVSampleBufferAudioRendererWasFlushedAutomaticallyNotification @abstract A notification that fires whenever the receiver's enqueued media data has been flushed for a reason other than a call to the -flush method. @discussion The renderer may flush enqueued media data when the user routes playback to a new destination. The renderer may also flush enqueued media data when the playback rate of the attached AVSampleBufferRenderSynchronizer is changed (e.g. 1.0 -> 2.0 or 1.0 -> 0.0 -> 2.0), however no flush will occur for normal pauses (non-zero -> 0.0) and resumes (0.0 -> same non-zero rate as before). When an automatic flush occurs, the attached render synchronizer's timebase will remain running at its current rate. It is typically best to respond to this notification by enqueueing media data with timestamps starting at the timebase's current time. To the listener, this will sound similar to muting the audio for a short period of time. If it is more desirable to ensure that all audio is played than to keep the timeline moving, you may also stop the synchronizer, set the synchronizer's current time to the value of AVSampleBufferAudioRendererFlushTimeKey, start reenqueueing sample buffers with timestamps starting at that time, and restart the synchronizer. To the listener, this will sound similar to pausing the audio for a short period of time. This notification is delivered on an arbitrary thread. If sample buffers are being enqueued with the renderer concurrently with the receipt of this notification, it is possible that one or more sample buffers will remain enqueued in the renderer. This is generally undesirable, because the sample buffers that remain will likely have timestamps far ahead of the timebase's current time and so won't be rendered for some time. The best practice is to invoke the -flush method, in a manner that is serialized with enqueueing sample buffers, after receiving this notification and before resuming the enqueueing of sample buffers.

func AVSampleBufferDisplayLayerFailedToDecodeNotification ¶

func AVSampleBufferDisplayLayerFailedToDecodeNotification() uintptr

func AVSampleBufferDisplayLayerFailedToDecodeNotificationErrorKey ¶

func AVSampleBufferDisplayLayerFailedToDecodeNotificationErrorKey() uintptr

func AVSampleBufferDisplayLayerOutputObscuredDueToInsufficientExternalProtectionDidChangeNotification ¶

func AVSampleBufferDisplayLayerOutputObscuredDueToInsufficientExternalProtectionDidChangeNotification() *foundation.NSString

func AVSampleBufferDisplayLayerReadyForDisplayDidChangeNotification ¶

func AVSampleBufferDisplayLayerReadyForDisplayDidChangeNotification() uintptr

func AVSampleBufferDisplayLayerRequiresFlushToResumeDecodingDidChangeNotification ¶

func AVSampleBufferDisplayLayerRequiresFlushToResumeDecodingDidChangeNotification() uintptr

func AVSampleBufferGeneratorNotifyOfDataReadyForSampleBufferCompletionHandler ¶

func AVSampleBufferGeneratorNotifyOfDataReadyForSampleBufferCompletionHandler(sbuf unsafe.Pointer, completionHandler func(bool, unsafe.Pointer))

func AVSampleBufferRenderSynchronizerRateDidChangeNotification ¶

func AVSampleBufferRenderSynchronizerRateDidChangeNotification() *foundation.NSString

A notification that fires whenever the value of the "rate" property changes. The rate can change as a result of setting the rate property, either by directly setting the property or calling -setRate:time:. The rate can also change at any time, without any action by the client of the render synchronizer. For example, on iOS if the app's playback is interrupted (e.g. by a phone call or another non-mixable app starting playback), the rate will automatically be set to zero. This notification will be sent in all of those cases.

func AVSampleBufferVideoRendererDidFailToDecodeNotification ¶

func AVSampleBufferVideoRendererDidFailToDecodeNotification() uintptr

func AVSampleBufferVideoRendererDidFailToDecodeNotificationErrorKey ¶

func AVSampleBufferVideoRendererDidFailToDecodeNotificationErrorKey() uintptr

func AVSampleBufferVideoRendererRequiresFlushToResumeDecodingDidChangeNotification ¶

func AVSampleBufferVideoRendererRequiresFlushToResumeDecodingDidChangeNotification() uintptr

func AVSemanticSegmentationMatteTypeGlasses ¶

func AVSemanticSegmentationMatteTypeGlasses() *foundation.NSString

@constant AVSemanticSegmentationMatteTypeGlasses A matting image segmenting all glasses ( e.g. eyeglasses, sunglasses ) from all persons wearing glasses in the visible field-of-view of an image.

func AVSemanticSegmentationMatteTypeHair ¶

func AVSemanticSegmentationMatteTypeHair() *foundation.NSString

@constant AVSemanticSegmentationMatteTypeHair A matting image segmenting all hair from all persons in the visible field-of-view of an image.

func AVSemanticSegmentationMatteTypeSkin ¶

func AVSemanticSegmentationMatteTypeSkin() *foundation.NSString

@constant AVSemanticSegmentationMatteTypeSkin A matting image segmenting all skin from all persons in the visible field-of-view of an image.

func AVSemanticSegmentationMatteTypeTeeth ¶

func AVSemanticSegmentationMatteTypeTeeth() *foundation.NSString

@constant AVSemanticSegmentationMatteTypeTeeth A matting image segmenting all teeth from all persons in the visible field-of-view of an image.

func AVSpatialCaptureDiscomfortReasonNotEnoughLight ¶

func AVSpatialCaptureDiscomfortReasonNotEnoughLight() uintptr

@constant AVSpatialCaptureDiscomfortReasonNotEnoughLight The lighting of the current scene is not bright enough; the playback experience will likely be uncomfortable due to noise differences between the two cameras.

func AVSpatialCaptureDiscomfortReasonSubjectTooClose ¶

func AVSpatialCaptureDiscomfortReasonSubjectTooClose() uintptr

@constant AVSpatialCaptureDiscomfortReasonSubjectTooClose The focus point of the current scene is too close; the playback experience will likely be uncomfortable due to the subject being closer than the minimum focus distance of one or both of the lenses.

func AVStreamingKeyDeliveryContentKeyType ¶

func AVStreamingKeyDeliveryContentKeyType() uintptr

A UTI for streaming key delivery content keys The value of this UTI is @"com.apple.streamingkeydelivery.contentkey".

func AVStreamingKeyDeliveryPersistentContentKeyType ¶

func AVStreamingKeyDeliveryPersistentContentKeyType() uintptr

A UTI for persistent streaming key delivery content keys The value of this UTI is @"com.apple.streamingkeydelivery.persistentcontentkey".

func AVTextStyleRulePropertyListForTextStyleRules ¶

func AVTextStyleRulePropertyListForTextStyleRules(textStyleRules *foundation.NSArray[*AVTextStyleRule]) objc.ID

@method propertyListForTextStyleRules: @abstract Converts an NSArray of AVTextStyleRules into a serializable property list that can be used for persistent storage. @param textStyleRules An array of AVTextStyleRules. @result A serializable property list. @discussion For serialization utilities, see NSPropertyList.h.

func AVTextStyleRuleTextStyleRulesFromPropertyList ¶

func AVTextStyleRuleTextStyleRulesFromPropertyList(plist objc.ID) *foundation.NSArray[*AVTextStyleRule]

@method textStyleRulesFromPropertyList: @abstract Converts a property list into an NSArray of AVTextStyleRules. @param plist A property list, normally obtained previously via an invocation of +propertyListForTextStyleRules:. @result An NSArray of AVTextStyleRules

func AVTrackAssociationTypeAudioFallback ¶

func AVTrackAssociationTypeAudioFallback() *foundation.NSString

Indicates an association between an audio track with another audio track that contains the same content but is typically encoded in a different format that's more widely supported, used to nominate a track that should be used in place of an unsupported track. Associations of type AVTrackAssociationTypeAudioFallback are supported only between audio tracks. This association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the receiver should be an instance of AVAssetWriterInput with a corresponding track that has content that's less widely supported, and the input parameter should be an instance of AVAssetWriterInput with a corresponding track that has content that's more widely supported. Example: Using AVTrackAssociationTypeAudioFallback, a stereo audio track with media subtype kAudioFormatMPEG4AAC could be nominated as the "fallback" for an audio track encoding the same source material but with media subtype kAudioFormatAC3 and a 5.1 channel layout. This would ensure that all clients are capable of playing back some form of the audio.

func AVTrackAssociationTypeChapterList ¶

func AVTrackAssociationTypeChapterList() *foundation.NSString

Indicates an association between a track with another track that contains chapter information. The track containing chapter information may be a text track, a video track, or a timed metadata track. This association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the receiver should be an instance of AVAssetWriterInput with a corresponding track that has renderable content while the input parameter should be an instance of AVAssetWriterInput with a corresponding track that contains chapter metadata.

func AVTrackAssociationTypeForcedSubtitlesOnly ¶

func AVTrackAssociationTypeForcedSubtitlesOnly() *foundation.NSString

Indicates an association between a subtitle track typically containing both forced and non-forced subtitles with another subtitle track that contains only forced subtitles, for use when the user indicates that only essential subtitles should be displayed. When such an association is established, the forced subtitles in both tracks are expected to present the same content in the same language but may have different timing. Associations of type AVTrackAssociationTypeForcedSubtitlesOnly are supported only between subtitle tracks. This association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the receiver should be an instance of AVAssetWriterInput with a corresponding subtitle track that contains non-forced subtitles, and the input parameter should be an instance of AVAssetWriterInput with a corresponding subtitle track that contains forced subtitles only.

func AVTrackAssociationTypeMetadataReferent ¶

func AVTrackAssociationTypeMetadataReferent() *foundation.NSString

Indicates an association between a metadata track and the track that's described or annotated via the contents of the metadata track. This track association is optional for AVAssetTracks with the mediaType AVMediaTypeMetadata. When a metadata track lacks this track association, its contents are assumed to describe or annotate the asset as a whole. This association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the receiver should be an instance of AVAssetWriterInput with mediaType AVMediaTypeMetadata while the input parameter should be an instance of AVAssetWriterInput that's used to create the track to which the contents of the receiver's corresponding metadata track refer.

func AVTrackAssociationTypeRenderMetadataSource ¶

func AVTrackAssociationTypeRenderMetadataSource() *foundation.NSString

Indicates an association between a metadata track and another track where the metadata provides additional information for rendering of that track. This track association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the receiver should be an instance of AVAssetWriterInput with mediaType, AVMediaTypeMetadata, while the input parameter should be an instance of AVAssetWriterInput for the target track that would be rendered (for example, a video track).

func AVTrackAssociationTypeSelectionFollower ¶

func AVTrackAssociationTypeSelectionFollower() *foundation.NSString

Indicates an association between a pair of tracks that specifies that, when the first of the pair is selected, the second of the pair should be considered an appropriate default for selection also. Example: a subtitle track in the same language as an audio track may be associated with that audio track using AVTrackAssociationTypeSelectionFollower, to indicate that selection of the subtitle track, in the absence of a directive for subtitle selection from the user, can "follow" the selection of the audio track. This association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the input parameter should be an instance of AVAssetWriterInput whose selection may depend on the selection of the receiver. In the example above, the receiver would be the instance of AVAssetWriterInput corresponding with the audio track and the input parameter would be the instance of AVAssetWriterInput corresponding with the subtitle track.

func AVTrackAssociationTypeTimecode ¶

func AVTrackAssociationTypeTimecode() *foundation.NSString

Indicates an association between a track with another track that contains timecode information. The track containing timecode information should be a timecode track. This association is not symmetric; when used with -[AVAssetWriterInput addTrackAssociationWithTrackOfInput:type:], the receiver should be an instance of AVAssetWriterInput with a corresponding track that may be a video track or an audio track while the input parameter should be an instance of AVAssetWriterInput with a corresponding timecode track.

func AVURLAssetAllowsCellularAccessKey ¶

func AVURLAssetAllowsCellularAccessKey() uintptr

Indicates whether network requests on behalf of this asset are allowed to use the cellular interface. Default is YES.

func AVURLAssetAllowsConstrainedNetworkAccessKey ¶

func AVURLAssetAllowsConstrainedNetworkAccessKey() uintptr

Indicates whether network requests on behalf of this asset are allowed to use the constrained interface (e.g. interfaces marked as being in data saver mode). Default is YES.

func AVURLAssetAllowsExpensiveNetworkAccessKey ¶

func AVURLAssetAllowsExpensiveNetworkAccessKey() uintptr

Indicates whether network requests on behalf of this asset are allowed to use the expensive interface (e.g. cellular, tethered, constrained). Default is YES.

func AVURLAssetAudiovisualContentTypes ¶

func AVURLAssetAudiovisualContentTypes() *foundation.NSArray[*uniformtypeidentifiers.UTType]

Provides the content types the AVURLAsset class understands. - Returns: An NSArray of UTTypes identifying the content types the AVURLAsset class understands.

func AVURLAssetAudiovisualMIMETypes ¶

func AVURLAssetAudiovisualMIMETypes() *foundation.NSArray[*foundation.NSString]

Provides the MIME types the AVURLAsset class understands. - Returns: An NSArray of NSStrings containing MIME types the AVURLAsset class understands.

func AVURLAssetAudiovisualTypes ¶

func AVURLAssetAudiovisualTypes() *foundation.NSArray[*foundation.NSString]

Provides the file types the AVURLAsset class understands. - Returns: An NSArray of UTIs identifying the file types the AVURLAsset class understands. Deprecated: Use audiovisualContentTypes instead

func AVURLAssetHTTPCookiesKey ¶

func AVURLAssetHTTPCookiesKey() uintptr

HTTP cookies that the AVURLAsset may send with HTTP requests Standard cross-site policy still applies: cookies will only be sent to domains to which they apply. By default, an AVURLAsset will only have access to cookies in the client's default cookie storage that apply to the AVURLAsset's URL. You can supplement the cookies available to the asset via use of this initialization option HTTP cookies do not apply to non-HTTP(S) URLS. In HLS, many HTTP requests (e.g., media, crypt key, variant index) might be issued to different paths or hosts. In both of these cases, HTTP requests will be missing any cookies that do not apply to the AVURLAsset's URL. This init option allows the AVURLAsset to use additional HTTP cookies for those HTTP(S) requests.

func AVURLAssetHTTPUserAgentKey ¶

func AVURLAssetHTTPUserAgentKey() uintptr

Specifies the value of the User-Agent header to add to HTTP requests made by this asset. Value is an NSString Default value is the systems's default User-Agent.

func AVURLAssetIsPlayableExtendedMIMEType ¶

func AVURLAssetIsPlayableExtendedMIMEType(extendedMIMEType *foundation.NSString) bool

Returns YES if asset is playable with the codec(s) and container type specified in extendedMIMEType. Returns NO otherwise. On releases prior to macOS 14, iOS 17, tvOS 17, and watchOS 10, regardless of the specified MIME type this method interprets all codecs parameters according to the ISO family syntax defined by RFC 6381 and evaluates playability according to whether the indicated codecs are supported when carried in container formats that conform to the ISO BMFF specification, such as the MPEG-4 file format. On releases starting with macOS 14, iOS 17, tvOS 17, and watchOS 10, this method interprets codecs parameters according to the syntax and namespace determined by the specified MIME type and evaluates playability according to whether the indicated codecs are supported when carried in the container format indicated by that MIME type. Codecs parameters for each of the following MIME types are supported: video/mp4 (per RFC 6381, ISO/IEC 14496-15 Annex E, et al), video/quicktime (RFC 6381 et al), video/mp2t (ISO/IEC 13818-1), audio/vnd.wave (RFC 2361), audio/aiff (using the CoreAudio AudioFormatID namespace), audio/x-caf (also using the CoreAudio AudioFormatID namespace), and audio/mpeg (e.g. codecs="mp3"). MIME types supported as alternatives for the same container formats, e.g audio/mp4, are equivalently treated. If the indicated MIME type defines no supported syntax and namespace for codecs parameters, when any codecs parameter is present this method returns NO. - Parameter extendedMIMEType: - Returns: YES or NO.

func AVURLAssetOverrideMIMETypeKey ¶

func AVURLAssetOverrideMIMETypeKey() uintptr

Indicates the MIME type that should be used to identify the format of the media resource. When a value for this key is provided, only the specified MIME type is considered in determining how to handle or parse the media resource. Any other information that may be available, such as the URL path extension or a server-provided MIME type, is ignored.

func AVURLAssetPreferPreciseDurationAndTimingKey ¶

func AVURLAssetPreferPreciseDurationAndTimingKey() uintptr

Indicates whether the asset should be prepared to indicate a precise duration and provide precise random access by time. The value for this key is a boolean NSNumber. If nil is passed as the value of the options parameter to -[AVURLAsset initWithURL:options:], or if a dictionary that lacks a value for the key AVURLAssetPreferPreciseDurationAndTimingKey is passed instead, a default value of NO is assumed. If the asset is intended to be played only, because AVPlayer will support approximate random access by time when full precision isn't available, the default value of NO will suffice. Pass YES if longer loading times are acceptable in cases in which precise timing is required. If the asset is intended to be inserted into an AVMutableComposition, precise random access is typically desirable and the value of YES is recommended. Note that such precision may require additional parsing of the resource in advance of operations that make use of any portion of it, depending on the specifics of its container format. Many container formats provide sufficient summary information for precise timing and do not require additional parsing to prepare for it; QuickTime movie files and MPEG-4 files are examples of such formats. Other formats do not provide sufficient summary information, and precise random access for them is possible only after a preliminary examination of a file's contents. If you pass YES for an asset that you intend to play via an instance of AVPlayerItem and you are prepared for playback to commence before the value of -[AVPlayerItem duration] becomes available, you can omit the key @"duration" from the array of AVAsset keys you pass to -[AVPlayerItem initWithAsset:automaticallyLoadedAssetKeys:] in order to prevent AVPlayerItem from automatically loading the value of duration while the item becomes ready to play. If precise duration and timing is not possible for the timed media resource referenced by the asset's URL, AVAsset.providesPreciseDurationAndTiming will be NO even if precise timing is requested via the use of this key.

func AVURLAssetPrimarySessionIdentifierKey ¶

func AVURLAssetPrimarySessionIdentifierKey() uintptr

Specifies a UUID to append as the value of the query parameter "_HLS_primary_id" to selected HTTP requests issued on behalf of the asset. Supported for HLS assets only. Value is an NSUUID. Its UUID string value will be used as the query parameter. If you create AVURLAssets for the templateItems of AVPlayerInterstitialEvents and you want the instances of AVURLAsset that you create to be used during interstitial playback rather than equivalent AVURLAssets with the same URL, you must provide a value for this key that's equal to the httpSessionIdentifier of the primary AVPlayerItem's asset. See AVPlayerInterstitialEventController.h. This is especially useful if you require the use of a custom AVAssetResourceLoader delegate for interstitial assets.

func AVURLAssetReferenceRestrictionsKey ¶

func AVURLAssetReferenceRestrictionsKey() uintptr

Indicates the restrictions used by the asset when resolving references to external media data. The value of this key is an NSNumber wrapping an AVAssetReferenceRestrictions enum value or the logical combination of multiple such values. Some assets can contain references to media data stored outside the asset's container file, for example in another file. This key can be used to specify a policy to use when these references are encountered. If an asset contains one or more references of a type that is forbidden by the reference restrictions, loading of asset properties will fail. In addition, such an asset cannot be used with other AVFoundation modules, such as AVPlayerItem or AVAssetExportSession.

func AVURLAssetShouldParseExternalSphericalTagsKey ¶

func AVURLAssetShouldParseExternalSphericalTagsKey() uintptr

Indicates whether additional projected media signaling in the asset should be parsed and resolved as format description extensions. Default is NO.

func AVURLAssetShouldSupportAliasDataReferencesKey ¶

func AVURLAssetShouldSupportAliasDataReferencesKey() uintptr

Indicates whether alias data references in the asset should be parsed and resolved. Default is NO. Although the majority of QuickTime movie files contain all of the media data they require, some contain references to media stored in other files. While AVFoundation and CoreMedia typically employ a URL reference for this purpose, older implementations such as QuickTime 7 have commonly employed a Macintosh alias instead, as documented in the QuickTime File Format specification. If your application must work with legacy QuickTime movie files containing alias-based references to media data stored in other files, the use of this AVURLAsset initialization option is appropriate. If you provide a value for AVURLAssetReferenceRestrictionsKey, restrictions will be observed for resolved alias references just as they are for URL references. For more details about alias resolution, consult documentation of the bookmark-related interfaces of NSURL.

func AVURLAssetURLRequestAttributionKey ¶

func AVURLAssetURLRequestAttributionKey() uintptr

Specifies the attribution of the URLs requested by this asset. Value is an NSNumber whose value is an NSURLRequestAttribution (see NSURLRequest.h). Default value is NSURLRequestAttributionDeveloper. All NSURLRequests issed on behalf of this AVURLAsset will be attributed with this value and follow the App Privacy Policy accordingly.

func AVVideoAllowFrameReorderingKey ¶

func AVVideoAllowFrameReorderingKey() uintptr

@constant AVVideoAllowFrameReorderingKey @abstract Enables or disables frame reordering. @discussion In order to achieve the best compression while maintaining image quality, some video encoders can reorder frames. This means that the order in which the frames will be emitted and stored (the decode order) will be different from the order in which they are presented to the video encoder (the display order). Encoding using frame reordering requires more system resources than encoding without frame reordering, so encoding performance should be taken into account when deciding whether to enable frame reordering. This is especially important when encoding video data from a real-time source, such as AVCaptureVideoDataOutput. In this situation, using a value of @NO for AVVideoAllowFrameReorderingKey may yield the best results. The default is @YES, which means that the encoder decides whether to enable frame reordering.

func AVVideoAllowWideColorKey ¶

func AVVideoAllowWideColorKey() uintptr

@constant AVVideoAllowWideColorKey @abstract Indicates whether the client can process wide color @discussion Clients who wish to process wide color content should set the value of this key to @YES, or specify AVVideoColorPropertiesKey. The default value, @NO, permits implicit color conversions to occur to a non-wide gamut color space.

func AVVideoApertureModeCleanAperture ¶

func AVVideoApertureModeCleanAperture() *foundation.NSString

@constant AVVideoApertureModeCleanAperture @abstract Both pixel aspect ratio and clean aperture will be applied. @discussion An image's clean aperture is a region of video free from transition artifacts caused by the encoding of the signal.

func AVVideoApertureModeEncodedPixels ¶

func AVVideoApertureModeEncodedPixels() *foundation.NSString

@constant AVVideoApertureModeEncodedPixels @abstract Neither pixel aspect ratio nor clean aperture will be applied. @discussion The image is not cropped to the clean aperture region and is not scaled according to the pixel aspect ratio. The encoded dimensions of the image description are displayed.

func AVVideoApertureModeProductionAperture ¶

func AVVideoApertureModeProductionAperture() *foundation.NSString

@constant AVVideoApertureModeProductionAperture @abstract Only pixel aspect ratio will be applied. @discussion The image is not cropped to the clean aperture region, but it is scaled according to the pixel aspect ratio. Use this option when you want to see all the pixels in your video, including the edges.

func AVVideoAppleProRAWBitDepthKey ¶

func AVVideoAppleProRAWBitDepthKey() uintptr

func AVVideoAverageBitRateKey ¶

func AVVideoAverageBitRateKey() uintptr

func AVVideoAverageNonDroppableFrameRateKey ¶

func AVVideoAverageNonDroppableFrameRateKey() uintptr

@constant AVVideoAverageNonDroppableFrameRateKey @abstract The desired average number of non-droppable frames to be encoded for each second of video. @discussion Some video encoders can produce a flexible mixture of non-droppable frames and droppable frames. The difference between these types is that it is necessary for a video decoder to decode a non-droppable frame in order to successfully decode subsequent frames, whereas droppable frames are optional and can be skipped without impact on decode of subsequent frames. Having a proportion of droppable frames in a sequence has advantages for temporal scalability: at playback time more or fewer frames may be decoded depending on the play rate. This property requests that the encoder emit an overall proportion of non-droppable and droppable frames so that there are the specified number of non-droppable frames per second. For example, to specify that the encoder should include an average of 30 non-droppable frames for each second of video: [myVideoSettings setObject:@30 forKey:AVVideoAverageNonDroppableFrameRateKey];

func AVVideoCleanApertureHeightKey ¶

func AVVideoCleanApertureHeightKey() uintptr

func AVVideoCleanApertureHorizontalOffsetKey ¶

func AVVideoCleanApertureHorizontalOffsetKey() uintptr

func AVVideoCleanApertureKey ¶

func AVVideoCleanApertureKey() uintptr

@constant AVVideoCleanApertureKey @abstract Defines the region within the video dimensions that will be displayed during playback @discussion The value for this key is an NSDictionary containing AVVideoCleanAperture*Key keys. AVVideoCleanApertureWidthKey and AVVideoCleanApertureHeightKey define a clean rectangle which is centered on the video frame. To offset this rectangle from center, use AVVideoCleanApertureHorizontalOffsetKey and AVVideoCleanApertureVerticalOffsetKey. A positive value for AVVideoCleanApertureHorizontalOffsetKey moves the clean aperture region to the right, and a positive value for AVVideoCleanApertureVerticalOffsetKey moves the clean aperture region down. If no clean aperture region is specified, the entire frame will be displayed during playback. Note that prior to macOS 10.9 and iOS 7.0, this key could only be specified as part of the dictionary given for AVVideoCompressionPropertiesKey. As of macOS 10.9 and iOS 7.0, the top level of an AVVideoSettings dictionary is the preferred place to specify this key.

func AVVideoCleanApertureVerticalOffsetKey ¶

func AVVideoCleanApertureVerticalOffsetKey() uintptr

func AVVideoCleanApertureWidthKey ¶

func AVVideoCleanApertureWidthKey() uintptr

func AVVideoCodecAppleProRes422 deprecated

func AVVideoCodecAppleProRes422() uintptr

Deprecated: since macOS 10.13.

func AVVideoCodecAppleProRes4444 deprecated

func AVVideoCodecAppleProRes4444() uintptr

Deprecated: since macOS 10.13.

func AVVideoCodecH264 deprecated

func AVVideoCodecH264() uintptr

Deprecated: since macOS 10.13.

func AVVideoCodecHEVC deprecated

func AVVideoCodecHEVC() uintptr

Deprecated: since macOS 10.13.

func AVVideoCodecJPEG deprecated

func AVVideoCodecJPEG() uintptr

Deprecated: since macOS 10.13.

func AVVideoCodecKey ¶

func AVVideoCodecKey() uintptr

func AVVideoCodecTypeAppleProRes422 ¶

func AVVideoCodecTypeAppleProRes422() *foundation.NSString

func AVVideoCodecTypeAppleProRes422HQ ¶

func AVVideoCodecTypeAppleProRes422HQ() *foundation.NSString

func AVVideoCodecTypeAppleProRes422LT ¶

func AVVideoCodecTypeAppleProRes422LT() *foundation.NSString

func AVVideoCodecTypeAppleProRes422Proxy ¶

func AVVideoCodecTypeAppleProRes422Proxy() *foundation.NSString

func AVVideoCodecTypeAppleProRes4444 ¶

func AVVideoCodecTypeAppleProRes4444() *foundation.NSString

func AVVideoCodecTypeAppleProRes4444XQ ¶

func AVVideoCodecTypeAppleProRes4444XQ() *foundation.NSString

func AVVideoCodecTypeAppleProResRAW ¶

func AVVideoCodecTypeAppleProResRAW() *foundation.NSString

func AVVideoCodecTypeAppleProResRAWHQ ¶

func AVVideoCodecTypeAppleProResRAWHQ() *foundation.NSString

func AVVideoCodecTypeH264 ¶

func AVVideoCodecTypeH264() *foundation.NSString

func AVVideoCodecTypeHEVC ¶

func AVVideoCodecTypeHEVC() *foundation.NSString

func AVVideoCodecTypeHEVCWithAlpha ¶

func AVVideoCodecTypeHEVCWithAlpha() *foundation.NSString

func AVVideoCodecTypeJPEG ¶

func AVVideoCodecTypeJPEG() *foundation.NSString

func AVVideoCodecTypeJPEGXL ¶

func AVVideoCodecTypeJPEGXL() *foundation.NSString

func AVVideoColorPrimariesKey ¶

func AVVideoColorPrimariesKey() uintptr

func AVVideoColorPrimaries_EBU_3213 ¶

func AVVideoColorPrimaries_EBU_3213() uintptr

func AVVideoColorPrimaries_ITU_R_709_2 ¶

func AVVideoColorPrimaries_ITU_R_709_2() uintptr

func AVVideoColorPrimaries_ITU_R_2020 ¶

func AVVideoColorPrimaries_ITU_R_2020() uintptr

func AVVideoColorPrimaries_P3_D65 ¶

func AVVideoColorPrimaries_P3_D65() uintptr

func AVVideoColorPrimaries_SMPTE_C ¶

func AVVideoColorPrimaries_SMPTE_C() uintptr

func AVVideoColorPropertiesKey ¶

func AVVideoColorPropertiesKey() uintptr

func AVVideoCompositionPerFrameHDRDisplayMetadataPolicyGenerate ¶

func AVVideoCompositionPerFrameHDRDisplayMetadataPolicyGenerate() *foundation.NSString

AVVideoComposition may generate HDR metadata and attach it to the rendered frame. HDR metadata generation is influenced by the color space of the rendered frame, device, and HDR metadata format platform support. Any previously attached HDR metadata of the same metadata format will be overwritten.

func AVVideoCompositionPerFrameHDRDisplayMetadataPolicyPropagate ¶

func AVVideoCompositionPerFrameHDRDisplayMetadataPolicyPropagate() *foundation.NSString

Default. Pass the HDR metadata through, if present on the composed frame.

func AVVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandlerCompletionHandler ¶

func AVVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandlerCompletionHandler(asset *AVAsset, applier func(*AVAsynchronousCIImageFilteringRequest), completionHandler func(*AVVideoComposition, unsafe.Pointer))

Vends a new instance of AVVideoComposition with values and instructions that will apply the specified handler block to video frames represented as instances of CIImage. The new AVVideoComposition will cause the specified handler block to be called to filter each frame of the asset's first enabled video track. The handler block should use the properties of the provided AVAsynchronousCIImageFilteringRequest and respond using finishWithImage:context: with a "filtered" new CIImage (or the provided source image for no affect). In the event of an error, respond to the request using finishWithError:. The error can be observed via AVPlayerItemFailedToPlayToEndTimeNotification, see AVPlayerItemFailedToPlayToEndTimeErrorKey in notification payload. NOTE: The returned AVVideoComposition's properties are private and support only CIFilter-based operations. Mutations are not supported, either in the values of properties of the AVVideoComposition itself or in its private instructions. If rotations or other transformations are desired, they must be accomplished via the application of CIFilters during the execution of your specified handler. The video composition will also have the following values for its properties: - The original timing of the asset's first enabled video track will be used. - A renderSize that encompasses the asset's first enabled video track respecting the track's preferredTransform. - A renderScale of 1.0. The default CIContext has the following properties: - iOS: Device RGB color space - macOS: sRGB color space Example usage: ```objc [AVVideoComposition videoCompositionWithAsset:srcAsset applyingCIFiltersWithHandler: ^(AVAsynchronousCIImageFilteringRequest *request) { NSError *err = nil; CIImage *filtered = myRenderer(request, &err); if (filtered) [request finishWithImage:filtered context:nil]; else [request finishWithError:err]; } completionHandler: ^(AVVideoComposition * _Nullable videoComposition, NSError * _Nullable error) { if (videoComposition != nil) { playerItem.videoComposition = videoComposition else { // handle error }]; ``` - Parameter asset: An instance of AVAsset. - Parameter completionHandler: A block that is invoked when the new video composition has finished being created. If the `videoComposition` parameter is nil, the `error` parameter describes the failure that occurred.

func AVVideoCompositionVideoCompositionWithPropertiesOfAssetCompletionHandler ¶

func AVVideoCompositionVideoCompositionWithPropertiesOfAssetCompletionHandler(asset *AVAsset, completionHandler func(*AVVideoComposition, unsafe.Pointer))

Vends a new instance of AVVideoComposition with values and instructions suitable for presenting the video tracks of the specified asset according to its temporal and geometric properties and those of its tracks. The new AVVideoComposition will have instructions that respect the spatial properties and timeRanges of the specified asset's video tracks. It will also have the following values for its properties: - If the asset has exactly one video track, the original timing of the source video track will be used. If the asset has more than one video track, and the nominal frame rate of any of video tracks is known, the reciprocal of the greatest known nominalFrameRate will be used as the value of frameDuration. Otherwise, a default framerate of 30fps is used. - If the specified asset is an instance of AVComposition, the renderSize will be set to the naturalSize of the AVComposition; otherwise the renderSize will be set to a value that encompasses all of the asset's video tracks. - A renderScale of 1.0. - A nil animationTool. If the specified asset has no video tracks, this method will return an AVVideoComposition instance with an empty collection of instructions. - Parameter asset: An instance of AVAsset. - Parameter completionHandler: A block that is invoked when the new video composition has finished being created. If the `videoComposition` parameter is nil, the `error` parameter describes the failure that occurred.

func AVVideoCompressionPropertiesKey ¶

func AVVideoCompressionPropertiesKey() uintptr

@constant AVVideoCompressionPropertiesKey @abstract The value for this key is an instance of NSDictionary, containing properties to be passed down to the video encoder. @discussion Package the below keys in an instance of NSDictionary and use it as the value for AVVideoCompressionPropertiesKey in the top-level AVVideoSettings dictionary. In addition to the keys listed below, you can also include keys from VideoToolbox/VTCompressionProperties.h. Most keys can only be used for certain encoders. Look at individual keys for details.

func AVVideoDecompressionPropertiesKey ¶

func AVVideoDecompressionPropertiesKey() uintptr

@constant AVVideoDecompressionPropertiesKey @abstract The value for this key is an instance of NSDictionary, containing properties to be passed down to the video decoder. @discussion Package the below keys in an instance of NSDictionary and use it as the value for AVVideoDecompressionPropertiesKey in the top-level AVVideoSettings dictionary. In addition to the keys listed below, you can also include keys from VideoToolbox/VTDecompressionProperties.h. Most keys can only be used for certain decoders. Look at individual keys for details.

func AVVideoEncoderSpecificationKey ¶

func AVVideoEncoderSpecificationKey() uintptr

@constant AVVideoEncoderSpecificationKey @abstract The video encoder specification includes options for choosing a specific video encoder. @discussion The value for this key is a dictionary containing kVTVideoEncoderSpecification_* keys specified in the VideoToolbox framework. This key should be specified at the top level of an AVVideoSettings dictionary.

func AVVideoExpectedSourceFrameRateKey ¶

func AVVideoExpectedSourceFrameRateKey() uintptr

@constant AVVideoExpectedSourceFrameRateKey @abstract Indicates the expected source frame rate, if known. @discussion The frame rate is measured in frames per second. This is not used to control the frame rate; it is provided as a hint to the video encoder so that it can set up internal configuration before compression begins. The actual frame rate will depend on frame durations and may vary. This should be set if an AutoLevel AVVideoProfileLevelKey is used, or if the source content has a high frame rate (higher than 30 fps). The encoder might have to drop frames to satisfy bit stream requirements if this key is not specified.

func AVVideoH264EntropyModeCABAC ¶

func AVVideoH264EntropyModeCABAC() uintptr

func AVVideoH264EntropyModeCAVLC ¶

func AVVideoH264EntropyModeCAVLC() uintptr

func AVVideoH264EntropyModeKey ¶

func AVVideoH264EntropyModeKey() uintptr

@constant AVVideoH264EntropyModeKey @abstract The entropy encoding mode for H.264 compression. @discussion If supported by an H.264 encoder, this property controls whether the encoder should use Context-based Adaptive Variable Length Coding (CAVLC) or Context-based Adaptive Binary Arithmetic Coding (CABAC). CABAC generally gives better compression at the expense of higher computational overhead. The default value is encoder-specific and may change depending on other encoder settings. Care should be taken when using this property -- changes may result in a configuration which is not compatible with a requested Profile and Level. Results in this case are undefined, and could include encode errors or a non-compliant output stream.

func AVVideoHeightKey ¶

func AVVideoHeightKey() uintptr

func AVVideoMaxKeyFrameIntervalDurationKey ¶

func AVVideoMaxKeyFrameIntervalDurationKey() uintptr

func AVVideoMaxKeyFrameIntervalKey ¶

func AVVideoMaxKeyFrameIntervalKey() uintptr

func AVVideoPixelAspectRatioHorizontalSpacingKey ¶

func AVVideoPixelAspectRatioHorizontalSpacingKey() uintptr

func AVVideoPixelAspectRatioKey ¶

func AVVideoPixelAspectRatioKey() uintptr

@constant AVVideoPixelAspectRatioKey @abstract The aspect ratio of the pixels in the video frame @discussion The value for this key is an NSDictionary containing AVVideoPixelAspectRatio*Key keys. If no value is specified for this key, the default value for the codec is used. Usually this is 1:1, meaning square pixels. Note that prior to macOS 10.9 and iOS 7.0, this key could only be specified as part of the dictionary given for AVVideoCompressionPropertiesKey. As of macOS 10.9 and iOS 7.0, the top level of an AVVideoSettings dictionary is the preferred place to specify this key.

func AVVideoPixelAspectRatioVerticalSpacingKey ¶

func AVVideoPixelAspectRatioVerticalSpacingKey() uintptr

func AVVideoProfileLevelH264Baseline30 ¶

func AVVideoProfileLevelH264Baseline30() uintptr

func AVVideoProfileLevelH264Baseline31 ¶

func AVVideoProfileLevelH264Baseline31() uintptr

func AVVideoProfileLevelH264Baseline41 ¶

func AVVideoProfileLevelH264Baseline41() uintptr

func AVVideoProfileLevelH264BaselineAutoLevel ¶

func AVVideoProfileLevelH264BaselineAutoLevel() uintptr

func AVVideoProfileLevelH264High40 ¶

func AVVideoProfileLevelH264High40() uintptr

func AVVideoProfileLevelH264High41 ¶

func AVVideoProfileLevelH264High41() uintptr

func AVVideoProfileLevelH264HighAutoLevel ¶

func AVVideoProfileLevelH264HighAutoLevel() uintptr

func AVVideoProfileLevelH264Main30 ¶

func AVVideoProfileLevelH264Main30() uintptr

func AVVideoProfileLevelH264Main31 ¶

func AVVideoProfileLevelH264Main31() uintptr

func AVVideoProfileLevelH264Main32 ¶

func AVVideoProfileLevelH264Main32() uintptr

func AVVideoProfileLevelH264Main41 ¶

func AVVideoProfileLevelH264Main41() uintptr

func AVVideoProfileLevelH264MainAutoLevel ¶

func AVVideoProfileLevelH264MainAutoLevel() uintptr

func AVVideoProfileLevelKey ¶

func AVVideoProfileLevelKey() uintptr

func AVVideoQualityKey ¶

func AVVideoQualityKey() uintptr

func AVVideoRangeHLG ¶

func AVVideoRangeHLG() *foundation.NSString

Indicates that the video range as HLG

func AVVideoRangePQ ¶

func AVVideoRangePQ() *foundation.NSString

Indicates that the video range as PQ

func AVVideoRangeSDR ¶

func AVVideoRangeSDR() *foundation.NSString

Indicates that the video range as SDR

func AVVideoScalingModeFit ¶

func AVVideoScalingModeFit() uintptr

func AVVideoScalingModeKey ¶

func AVVideoScalingModeKey() uintptr

func AVVideoScalingModeResize ¶

func AVVideoScalingModeResize() uintptr

func AVVideoScalingModeResizeAspect ¶

func AVVideoScalingModeResizeAspect() uintptr

func AVVideoScalingModeResizeAspectFill ¶

func AVVideoScalingModeResizeAspectFill() uintptr

func AVVideoTransferFunctionKey ¶

func AVVideoTransferFunctionKey() uintptr

func AVVideoTransferFunction_IEC_sRGB ¶

func AVVideoTransferFunction_IEC_sRGB() uintptr

func AVVideoTransferFunction_ITU_R_709_2 ¶

func AVVideoTransferFunction_ITU_R_709_2() uintptr

func AVVideoTransferFunction_ITU_R_2100_HLG ¶

func AVVideoTransferFunction_ITU_R_2100_HLG() uintptr

func AVVideoTransferFunction_Linear ¶

func AVVideoTransferFunction_Linear() uintptr

func AVVideoTransferFunction_SMPTE_240M_1995 ¶

func AVVideoTransferFunction_SMPTE_240M_1995() uintptr

func AVVideoTransferFunction_SMPTE_ST_2084_PQ ¶

func AVVideoTransferFunction_SMPTE_ST_2084_PQ() uintptr

func AVVideoWidthKey ¶

func AVVideoWidthKey() uintptr

func AVVideoYCbCrMatrixKey ¶

func AVVideoYCbCrMatrixKey() uintptr

func AVVideoYCbCrMatrix_ITU_R_601_4 ¶

func AVVideoYCbCrMatrix_ITU_R_601_4() uintptr

func AVVideoYCbCrMatrix_ITU_R_709_2 ¶

func AVVideoYCbCrMatrix_ITU_R_709_2() uintptr

func AVVideoYCbCrMatrix_ITU_R_2020 ¶

func AVVideoYCbCrMatrix_ITU_R_2020() uintptr

func AVVideoYCbCrMatrix_SMPTE_240M_1995 ¶

func AVVideoYCbCrMatrix_SMPTE_240M_1995() uintptr

func CMTagCollectionCreateWithVideoOutputPreset ¶

func CMTagCollectionCreateWithVideoOutputPreset(allocator unsafe.Pointer, preset CMTagCollectionVideoOutputPreset, newCollectionOut unsafe.Pointer) int

func SymbolAvailable ¶

func SymbolAvailable(symbol string) bool

SymbolAvailable reports whether the named C symbol was bound when the library loaded. Calling a generated wrapper whose symbol is unavailable dereferences a nil function variable and panics.

Types ¶

type AVAggregateAssetDownloadTask ¶

type AVAggregateAssetDownloadTask struct {
	foundation.NSURLSessionTask
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avaggregateassetdownloadtask Deprecated: Use assetDownloadTaskWithConfiguration: instead

func AVAggregateAssetDownloadTaskFromID ¶

func AVAggregateAssetDownloadTaskFromID(id objc.ID) *AVAggregateAssetDownloadTask

func (*AVAggregateAssetDownloadTask) URLAsset ¶

The asset supplied to the download task upon initialization. Deprecated: Use assetDownloadTaskWithConfiguration: instead

type AVAsset ¶

type AVAsset struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avasset

func AVAssetAssetWithURL ¶

func AVAssetAssetWithURL(uRL *foundation.NSURL) *AVAsset

Returns an instance of AVAsset for inspection of a media resource. Returns a newly allocated instance of a subclass of AVAsset initialized with the specified URL. - Parameter URL: An instance of NSURL that references a media resource. - Returns: An instance of AVAsset.

func AVAssetFromID ¶

func AVAssetFromID(id objc.ID) *AVAsset

func (*AVAsset) AllMediaSelections ¶

func (o *AVAsset) AllMediaSelections() *foundation.NSArray[*AVMediaSelection]

Provides an array of all permutations of AVMediaSelection for this asset.

func (*AVAsset) AvailableChapterLocales ¶

func (o *AVAsset) AvailableChapterLocales() *foundation.NSArray[*foundation.NSLocale]

array of NSLocale

func (*AVAsset) AvailableMediaCharacteristicsWithMediaSelectionOptions ¶

func (o *AVAsset) AvailableMediaCharacteristicsWithMediaSelectionOptions() *foundation.NSArray[*foundation.NSString]

Provides an NSArray of NSStrings, each NSString indicating a media characteristic for which a media selection option is available.

func (*AVAsset) AvailableMetadataFormats ¶

func (o *AVAsset) AvailableMetadataFormats() *foundation.NSArray[*foundation.NSString]

Provides an NSArray of NSStrings, each representing a metadata format that's available to the asset (e.g. ID3, iTunes metadata, etc.). Metadata formats are defined in AVMetadataFormat.h.

func (*AVAsset) CanContainFragments ¶

func (o *AVAsset) CanContainFragments() bool

Indicates whether the asset is capable of being extended by fragments. For QuickTime movie files and MPEG-4 files, the value of canContainFragments is YES if an 'mvex' box is present in the 'moov' box. For those types, the 'mvex' box signals the possible presence of later 'moof' boxes.

func (*AVAsset) CancelLoading ¶

func (o *AVAsset) CancelLoading()

Cancels the loading of all values for all observers. Deallocation or finalization of an instance of AVAsset will implicitly cancel loading if any loading requests are still outstanding.

func (*AVAsset) ChapterMetadataGroupsBestMatchingPreferredLanguages ¶

func (o *AVAsset) ChapterMetadataGroupsBestMatchingPreferredLanguages(preferredLanguages *foundation.NSArray[*foundation.NSString]) *foundation.NSArray[*AVTimedMetadataGroup]

Tests, in order of preference, for a match between language identifiers in the specified array of preferred languages and the available chapter locales, and returns the array of chapters corresponding to the first match that's found. Safe to call without blocking when the AVAsset key availableChapterLocales has status AVKeyValueStatusLoaded. Returns an array of AVTimedMetadataGroup objects. Each object in the array always contains an AVMetadataItem representing the chapter title; the timeRange property of the AVTimedMetadataGroup object is equal to the time range of the chapter title item. All of the available chapter metadata is included in the metadata groups, including items with the common key AVMetadataCommonKeyArtwork, if such items are present. Items not carrying chapter titles will be added to an existing AVTimedMetadataGroup object if the time range (timestamp and duration) of the metadata item and that of the metadata group overlaps. The locale of such items need not match the locale of the chapter titles. Further filtering of the metadata items in AVTimedMetadataGroups according to language can be accomplished using +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:]; filtering of the metadata items according to locale can be accomplished using +[AVMetadataItem metadataItemsFromArray:withLocale:]. - Parameter preferredLanguages: An array of language identifiers in order of preference, each of which is an IETF BCP 47 (RFC 4646) language identifier. If your goal is to provide the best match for the end user's preferred languages without consideration of your app's available localizations, pass [NSLocale preferredLanguages] as the value of preferredLanguages. However, if you want to filter the available choices in order to obtain the best match among the localizations that are available for your app, pass [NSBundle preferredLocalizationsFromArray:[[NSBundle mainBundle] localizations] forPreferences:[NSLocale preferredLanguages]] instead. The latter choice is normally more appropriate for strings intended for display as part of the app's UI. - Returns: An NSArray of AVTimedMetadataGroup. Deprecated: Use loadChapterMetadataGroupsBestMatchingPreferredLanguages:completionHandler: instead

func (*AVAsset) ChapterMetadataGroupsWithTitleLocaleContainingItemsWithCommonKeys ¶

func (o *AVAsset) ChapterMetadataGroupsWithTitleLocaleContainingItemsWithCommonKeys(locale *foundation.NSLocale, commonKeys *foundation.NSArray[*foundation.NSString]) *foundation.NSArray[*AVTimedMetadataGroup]

Provides an array of chapters. This method returns an array of AVTimedMetadataGroup objects. Each object in the array always contains an AVMetadataItem representing the chapter title; the timeRange property of the AVTimedMetadataGroup object is equal to the time range of the chapter title item. An AVMetadataItem with the specified common key will be added to an existing AVTimedMetadataGroup object if the time range (timestamp and duration) of the metadata item and the metadata group overlaps. The locale of items not carrying chapter titles need not match the specified locale parameter. Further filtering of the metadata items in AVTimedMetadataGroups according to language can be accomplished using +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:]; filtering of the metadata items according to locale can be accomplished using +[AVMetadataItem metadataItemsFromArray:withLocale:]. - Parameter locale: Locale of the metadata items carrying chapter titles to be returned (supports the IETF BCP 47 specification). - Parameter commonKeys: Array of common keys of AVMetadataItem to be included; can be nil. AVMetadataCommonKeyArtwork is the only supported key for now. - Returns: An NSArray of AVTimedMetadataGroup. Deprecated: Use loadChapterMetadataGroupsWithTitleLocale:containingItemsWithCommonKeys:completionHandler: instead

func (*AVAsset) CommonMetadata ¶

func (o *AVAsset) CommonMetadata() *foundation.NSArray[*AVMetadataItem]

Provides access to an array of AVMetadataItems for each common metadata key for which a value is available; items can be filtered according to language via +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:] and according to identifier via +[AVMetadataItem metadataItemsFromArray:filteredByIdentifier:].

func (*AVAsset) ContainsFragments ¶

func (o *AVAsset) ContainsFragments() bool

Indicates whether the asset is extended by at least one fragment. For QuickTime movie files and MPEG-4 files, the value of this property is YES if canContainFragments is YES and at least one 'moof' box is present after the 'moov' box.

func (*AVAsset) CreationDate ¶

func (o *AVAsset) CreationDate() *AVMetadataItem

Indicates the creation date of the asset as an AVMetadataItem. May be nil. If a creation date has been stored by the asset in a form that can be converted to an NSDate, the dateValue property of the AVMetadataItem will provide an instance of NSDate. Otherwise the creation date is available only as a string value, via -[AVMetadataItem stringValue].

func (*AVAsset) Duration ¶

func (o *AVAsset) Duration() coremedia.CMTime

Indicates the duration of the asset. If @"providesPreciseDurationAndTiming" is NO, a best-available estimate of the duration is returned. The degree of precision preferred for timing-related properties can be set at initialization time for assets initialized with URLs - Seealso: AVURLAssetPreferPreciseDurationAndTimingKey for AVURLAsset below.

func (*AVAsset) FindUnusedTrackIDWithCompletionHandler ¶

func (o *AVAsset) FindUnusedTrackIDWithCompletionHandler(completionHandler func(int32, unsafe.Pointer))

Loads a track ID that will not collide with any existing track - Parameter completionHandler: A block that is invoked when loading is complete, vending the track ID or an error.

func (*AVAsset) HasProtectedContent ¶

func (o *AVAsset) HasProtectedContent() bool

Indicates whether or not the asset has protected content. Assets containing protected content may not be playable without successful authorization, even if the value of the "playable" property is YES. See the properties in the AVAssetUsability category for details on how such an asset may be used. On macOS, clients can use the interfaces in AVPlayerItemProtectedContentAdditions.h to request authorization to play the asset.

func (*AVAsset) IsCompatibleWithAirPlayVideo ¶

func (o *AVAsset) IsCompatibleWithAirPlayVideo() bool

Indicates whether the asset is compatible with AirPlay Video. YES if an AVPlayerItem initialized with the receiver can be played by an external device via AirPlay Video.

func (*AVAsset) IsComposable ¶

func (o *AVAsset) IsComposable() bool

Indicates whether the receiver can be used to build an AVMutableComposition

func (*AVAsset) IsExportable ¶

func (o *AVAsset) IsExportable() bool

Indicates whether an AVAssetExportSession can be used with the receiver for export

func (*AVAsset) IsPlayable ¶

func (o *AVAsset) IsPlayable() bool

Indicates whether an AVPlayer can play the contents of the asset in a manner that meets user expectations. A client can attempt playback when playable is NO, this however may lead to a substandard playback experience.

func (*AVAsset) IsReadable ¶

func (o *AVAsset) IsReadable() bool

Indicates whether an AVAssetReader can be used with the receiver for extracting media data

func (*AVAsset) LoadChapterMetadataGroupsBestMatchingPreferredLanguagesCompletionHandler ¶

func (o *AVAsset) LoadChapterMetadataGroupsBestMatchingPreferredLanguagesCompletionHandler(preferredLanguages *foundation.NSArray[*foundation.NSString], completionHandler func(*foundation.NSArray[*AVTimedMetadataGroup], unsafe.Pointer))

Tests, in order of preference, for a match between language identifiers in the specified array of preferred languages and the available chapter locales, and loads the array of chapters corresponding to the first match that's found. Returns an array of AVTimedMetadataGroup objects. Each object in the array always contains an AVMetadataItem representing the chapter title; the timeRange property of the AVTimedMetadataGroup object is equal to the time range of the chapter title item. All of the available chapter metadata is included in the metadata groups, including items with the common key AVMetadataCommonKeyArtwork, if such items are present. Items not carrying chapter titles will be added to an existing AVTimedMetadataGroup object if the time range (timestamp and duration) of the metadata item and that of the metadata group overlaps. The locale of such items need not match the locale of the chapter titles. Further filtering of the metadata items in AVTimedMetadataGroups according to language can be accomplished using +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:]; filtering of the metadata items according to locale can be accomplished using +[AVMetadataItem metadataItemsFromArray:withLocale:]. - Parameter preferredLanguages: An array of language identifiers in order of preference, each of which is an IETF BCP 47 (RFC 4646) language identifier. If your goal is to provide the best match for the end user's preferred languages without consideration of your app's available localizations, pass [NSLocale preferredLanguages] as the value of preferredLanguages. However, if you want to filter the available choices in order to obtain the best match among the localizations that are available for your app, pass [NSBundle preferredLocalizationsFromArray:[[NSBundle mainBundle] localizations] forPreferences:[NSLocale preferredLanguages]] instead. The latter choice is normally more appropriate for strings intended for display as part of the app's UI. - Parameter completionHandler: A block that is invoked when loading is complete, vending the array of timed metadata groups or an error.

func (*AVAsset) LoadChapterMetadataGroupsWithTitleLocaleContainingItemsWithCommonKeysCompletionHandler ¶

func (o *AVAsset) LoadChapterMetadataGroupsWithTitleLocaleContainingItemsWithCommonKeysCompletionHandler(locale *foundation.NSLocale, commonKeys *foundation.NSArray[*foundation.NSString], completionHandler func(*foundation.NSArray[*AVTimedMetadataGroup], unsafe.Pointer))

Loads an array of chapters. This method vends an array of AVTimedMetadataGroup objects. Each object in the array always contains an AVMetadataItem representing the chapter title; the timeRange property of the AVTimedMetadataGroup object is equal to the time range of the chapter title item. An AVMetadataItem with the specified common key will be added to an existing AVTimedMetadataGroup object if the time range (timestamp and duration) of the metadata item and the metadata group overlaps. The locale of items not carrying chapter titles need not match the specified locale parameter. Further filtering of the metadata items in AVTimedMetadataGroups according to language can be accomplished using +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:]; filtering of the metadata items according to locale can be accomplished using +[AVMetadataItem metadataItemsFromArray:withLocale:]. - Parameter locale: Locale of the metadata items carrying chapter titles to be returned (supports the IETF BCP 47 specification). - Parameter commonKeys: Array of common keys of AVMetadataItem to be included; if no common keys are required, send an empty list. AVMetadataCommonKeyArtwork is the only supported key for now. - Parameter completionHandler: A block that is invoked when loading is complete, vending the array of timed metadata groups or an error.

func (*AVAsset) LoadMediaSelectionGroupForMediaCharacteristicCompletionHandler ¶

func (o *AVAsset) LoadMediaSelectionGroupForMediaCharacteristicCompletionHandler(mediaCharacteristic *foundation.NSString, completionHandler func(unsafe.Pointer, unsafe.Pointer))

Loads an instance of AVMediaSelectionGroup that contains one or more options with the specified media characteristic. If the asset has no AVMediaSelectionGroup containing options with the specified media characteristic, the return value will be nil. Filtering of the options in the returned AVMediaSelectionGroup according to playability, locale, and additional media characteristics can be accomplished using the category AVMediaSelectionOptionFiltering defined on AVMediaSelectionGroup. - Parameter mediaCharacteristic: A media characteristic for which you wish to obtain the available media selection options. AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, and AVMediaCharacteristicVisual are currently supported. Pass AVMediaCharacteristicAudible to obtain the group of available options for audio media in various languages and for various purposes, such as descriptive audio. Pass AVMediaCharacteristicLegible to obtain the group of available options for subtitles in various languages and for various purposes Pass AVMediaCharacteristicVisual to obtain the group of available options for video media. - Parameter completionHandler: A block that is invoked when loading is complete, vending an instance of AVMediaSelectionGroup (which may be nil) or an error.

func (*AVAsset) LoadMetadataForFormatCompletionHandler ¶

func (o *AVAsset) LoadMetadataForFormatCompletionHandler(format *foundation.NSString, completionHandler func(*foundation.NSArray[*AVMetadataItem], unsafe.Pointer))

Loads an NSArray of AVMetadataItems, one for each metadata item in the container of the specified format; can subsequently be filtered according to language via +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:], according to locale via +[AVMetadataItem metadataItemsFromArray:withLocale:], or according to key via +[AVMetadataItem metadataItemsFromArray:withKey:keySpace:]. - Parameter format: The metadata format for which items are requested. - Parameter completionHandler: A block that is invoked when loading is complete, vending the array of metadata items (which may be empty if there is no metadata of the specified format) or an error.

func (*AVAsset) LoadTrackWithTrackIDCompletionHandler ¶

func (o *AVAsset) LoadTrackWithTrackIDCompletionHandler(trackID int32, completionHandler func(unsafe.Pointer, unsafe.Pointer))

Loads an instance of AVAssetTrack that represents the track of the specified trackID. - Parameter trackID: The trackID of the requested AVAssetTrack. - Parameter completionHandler: A block that is called when the loading is finished, with either the loaded track (which may be nil if no track of the specified trackID is available) or an error.

func (*AVAsset) LoadTracksWithMediaCharacteristicCompletionHandler ¶

func (o *AVAsset) LoadTracksWithMediaCharacteristicCompletionHandler(mediaCharacteristic *foundation.NSString, completionHandler func(*foundation.NSArray[*AVAssetTrack], unsafe.Pointer))

Loads an array of AVAssetTracks of the asset that present media with the specified characteristic. - Parameter mediaCharacteristic: The media characteristic according to which AVAsset filters its AVAssetTracks. (Media characteristics are defined in AVMediaFormat.h.) - Parameter completionHandler: A block that is called when the loading is finished, with either the loaded tracks (which may be empty if no tracks with the specified characteristic are available) or an error.

func (*AVAsset) LoadTracksWithMediaTypeCompletionHandler ¶

func (o *AVAsset) LoadTracksWithMediaTypeCompletionHandler(mediaType *foundation.NSString, completionHandler func(*foundation.NSArray[*AVAssetTrack], unsafe.Pointer))

Loads an array of AVAssetTracks of the asset that present media of the specified media type. - Parameter mediaType: The media type according to which AVAsset filters its AVAssetTracks. (Media types are defined in AVMediaFormat.h.) - Parameter completionHandler: A block that is called when the loading is finished, with either the loaded tracks (which may be empty if no tracks of the specified media type are available) or an error.

func (*AVAsset) Lyrics ¶

func (o *AVAsset) Lyrics() *foundation.NSString

Provides access to the lyrics of the asset suitable for the current locale.

func (*AVAsset) MediaSelectionGroupForMediaCharacteristic ¶

func (o *AVAsset) MediaSelectionGroupForMediaCharacteristic(mediaCharacteristic *foundation.NSString) *AVMediaSelectionGroup

Provides an instance of AVMediaSelectionGroup that contains one or more options with the specified media characteristic. Becomes callable without blocking when the key @"availableMediaCharacteristicsWithMediaSelectionOptions" has been loaded. If the asset has no AVMediaSelectionGroup containing options with the specified media characteristic, the return value will be nil. Filtering of the options in the returned AVMediaSelectionGroup according to playability, locale, and additional media characteristics can be accomplished using the category AVMediaSelectionOptionFiltering defined on AVMediaSelectionGroup. - Parameter mediaCharacteristic: A media characteristic for which you wish to obtain the available media selection options. AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, and AVMediaCharacteristicVisual are currently supported. Pass AVMediaCharacteristicAudible to obtain the group of available options for audio media in various languages and for various purposes, such as descriptive audio. Pass AVMediaCharacteristicLegible to obtain the group of available options for subtitles in various languages and for various purposes. Pass AVMediaCharacteristicVisual to obtain the group of available options for video media. - Returns: An instance of AVMediaSelectionGroup. May be nil. Deprecated: Use loadMediaSelectionGroupForMediaCharacteristic:completionHandler: instead

func (*AVAsset) Metadata ¶

func (o *AVAsset) Metadata() *foundation.NSArray[*AVMetadataItem]

Provides access to an array of AVMetadataItems for all metadata identifiers for which a value is available; items can be filtered according to language via +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:] and according to identifier via +[AVMetadataItem metadataItemsFromArray:filteredByIdentifier:].

func (*AVAsset) MetadataForFormat ¶

func (o *AVAsset) MetadataForFormat(format *foundation.NSString) *foundation.NSArray[*AVMetadataItem]

Provides an NSArray of AVMetadataItems, one for each metadata item in the container of the specified format; can subsequently be filtered according to language via +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:], according to locale via +[AVMetadataItem metadataItemsFromArray:withLocale:], or according to key via +[AVMetadataItem metadataItemsFromArray:withKey:keySpace:]. Becomes callable without blocking when the key @"availableMetadataFormats" has been loaded - Parameter format: The metadata format for which items are requested. - Returns: An NSArray containing AVMetadataItems; may be empty if there is no metadata of the specified format. Deprecated: Use loadMetadataForFormat:completionHandler: instead

func (*AVAsset) MinimumTimeOffsetFromLive ¶

func (o *AVAsset) MinimumTimeOffsetFromLive() coremedia.CMTime

Indicates how close to the latest content in a live stream playback can be sustained. For non-live assets this value is kCMTimeInvalid.

func (*AVAsset) NaturalSize ¶

func (o *AVAsset) NaturalSize() corefoundation.CGSize

The following property is deprecated. Instead, use the naturalSize and preferredTransform, as appropriate, of the receiver's video tracks. See -tracksWithMediaType: below. Deprecated: Use the naturalSize and preferredTransform, as appropriate, of the receiver's video tracks. See -tracksWithMediaType:

func (*AVAsset) OverallDurationHint ¶

func (o *AVAsset) OverallDurationHint() coremedia.CMTime

Indicates the total duration of fragments that either exist now or may be appended in the future in order to extend the duration of the asset. For QuickTime movie files and MPEG-4 files, the value of this property is obtained from the 'mehd' box of the 'mvex' box, if present. If no total fragment duration hint is available, the value of this property is kCMTimeInvalid.

func (*AVAsset) PreferredMediaSelection ¶

func (o *AVAsset) PreferredMediaSelection() *AVMediaSelection

Provides an instance of AVMediaSelection with default selections for each of the receiver's media selection groups.

func (*AVAsset) PreferredRate ¶

func (o *AVAsset) PreferredRate() float32

Indicates the natural rate at which the asset is to be played; often but not always 1.0

func (*AVAsset) PreferredTransform ¶

func (o *AVAsset) PreferredTransform() corefoundation.CGAffineTransform

Indicates the preferred transform to apply to the visual content of the asset for presentation or processing; the value is often but not always the identity transform

func (*AVAsset) PreferredVolume ¶

func (o *AVAsset) PreferredVolume() float32

Indicates the preferred volume at which the audible media of an asset is to be played; often but not always 1.0

func (*AVAsset) ProvidesPreciseDurationAndTiming ¶

func (o *AVAsset) ProvidesPreciseDurationAndTiming() bool

Indicates that the asset provides precise timing. See @"duration" above and AVURLAssetPreferPreciseDurationAndTimingKey below.

func (*AVAsset) ReferenceRestrictions ¶

func (o *AVAsset) ReferenceRestrictions() AVAssetReferenceRestrictions

func (*AVAsset) TrackGroups ¶

func (o *AVAsset) TrackGroups() *foundation.NSArray[*AVAssetTrackGroup]

All track groups in the receiver. The value of this property is an NSArray of AVAssetTrackGroups, each representing a different grouping of tracks in the receiver.

func (*AVAsset) TrackWithTrackID ¶

func (o *AVAsset) TrackWithTrackID(trackID int32) *AVAssetTrack

Provides an instance of AVAssetTrack that represents the track of the specified trackID. Becomes callable without blocking when the key @"tracks" has been loaded - Parameter trackID: The trackID of the requested AVAssetTrack. - Returns: An instance of AVAssetTrack; may be nil if no track of the specified trackID is available. Deprecated: Use loadTrackWithTrackID:completionHandler: instead

func (*AVAsset) Tracks ¶

func (o *AVAsset) Tracks() *foundation.NSArray[*AVAssetTrack]

Provides the array of AVAssetTracks contained by the asset

func (*AVAsset) TracksWithMediaCharacteristic ¶

func (o *AVAsset) TracksWithMediaCharacteristic(mediaCharacteristic *foundation.NSString) *foundation.NSArray[*AVAssetTrack]

Provides an array of AVAssetTracks of the asset that present media with the specified characteristic. Becomes callable without blocking when the key @"tracks" has been loaded - Parameter mediaCharacteristic: The media characteristic according to which AVAsset filters its AVAssetTracks. (Media characteristics are defined in AVMediaFormat.h.) - Returns: An NSArray of AVAssetTracks; may be empty if no tracks with the specified characteristic are available. Deprecated: Use loadTracksWithMediaCharacteristic:completionHandler: instead

func (*AVAsset) TracksWithMediaType ¶

func (o *AVAsset) TracksWithMediaType(mediaType *foundation.NSString) *foundation.NSArray[*AVAssetTrack]

Provides an array of AVAssetTracks of the asset that present media of the specified media type. Becomes callable without blocking when the key @"tracks" has been loaded - Parameter mediaType: The media type according to which AVAsset filters its AVAssetTracks. (Media types are defined in AVMediaFormat.h.) - Returns: An NSArray of AVAssetTracks; may be empty if no tracks of the specified media type are available. Deprecated: Use loadTracksWithMediaType:completionHandler: instead

func (*AVAsset) UnusedTrackID deprecated

func (o *AVAsset) UnusedTrackID() int32

Deprecated: Use findUnusedTrackIDWithCompletionHandler: instead

type AVAssetCache ¶

type AVAssetCache struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetcache

func AVAssetCacheFromID ¶

func AVAssetCacheFromID(id objc.ID) *AVAssetCache

func (*AVAssetCache) IsPlayableOffline ¶

func (o *AVAssetCache) IsPlayableOffline() bool

Returns YES if a complete rendition of an AVAsset is available to be played without a network connection. An answer of YES does not indicate that any given media selection is available for offline playback. To determine if a specific media selection is available offline, see mediaSelectionOptionsInMediaSelectionGroup:.

func (*AVAssetCache) MediaPresentationLanguagesForMediaSelectionGroup ¶

func (o *AVAssetCache) MediaPresentationLanguagesForMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *foundation.NSArray[*foundation.NSString]

Returns an array of extended language tags for languages that can be selected for offline operations via use of the AVMediaSelectionGroup's AVCustomMediaSelectionScheme.

func (*AVAssetCache) MediaPresentationSettingsForMediaSelectionGroup ¶

func (o *AVAssetCache) MediaPresentationSettingsForMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *foundation.NSDictionary[*AVMediaPresentationSelector, objc.ID]

For each AVMediaPresentationSelector defined by the AVCustomMediaSelectionScheme of an AVMediaSelectionGroup, returns the AVMediaPresentationSettings that can be satisfied for offline operations, e.g. playback.

func (*AVAssetCache) MediaSelectionOptionsInMediaSelectionGroup ¶

func (o *AVAssetCache) MediaSelectionOptionsInMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *foundation.NSArray[*AVMediaSelectionOption]

Returns an array of AVMediaSelectionOptions in an AVMediaSelectionGroup that are available for offline operations, e.g. playback.

type AVAssetDownloadConfiguration ¶

type AVAssetDownloadConfiguration struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetdownloadconfiguration

func AVAssetDownloadConfigurationDownloadConfigurationWithAssetTitle ¶

func AVAssetDownloadConfigurationDownloadConfigurationWithAssetTitle(asset *AVURLAsset, title *foundation.NSString) *AVAssetDownloadConfiguration

Creates and initializes a download configuration object. This method will throw an exception if AVURLAsset has been invalidated. - Parameter asset: The asset to create the download configuration for. - Parameter title: A human readable title for this asset, expected to be as suitable as possible for the user's preferred languages. Will show up in the usage pane of the settings app.

func AVAssetDownloadConfigurationFromID ¶

func AVAssetDownloadConfigurationFromID(id objc.ID) *AVAssetDownloadConfiguration

func (*AVAssetDownloadConfiguration) ArtworkData ¶

NSData representing artwork data for this asset. Optional. May be displayed, for example, by the usage pane of the Settings app. Must work with +[UIImage imageWithData:].

func (*AVAssetDownloadConfiguration) AuxiliaryContentConfigurations ¶

The auxiliary content for the download. Optional. By default, auxiliaryContentConfigurations will have one or more default auxiliary content configurations. These content configurations can be augmented with additional content configurations or removed entirely if no auxiliary content is desired.

func (*AVAssetDownloadConfiguration) DownloadsInterstitialAssets ¶

func (o *AVAssetDownloadConfiguration) DownloadsInterstitialAssets() bool

Download interstitial assets as listed in the index file. False by default. Ordinarily, interstitial assets are skipped when downloading content for later playback. Setting this property to true will cause interstitial assets to be downloaded as well. Playback of the downloaded content can then match the experience of online streaming playback as closely as possible.

func (*AVAssetDownloadConfiguration) OptimizesAuxiliaryContentConfigurations ¶

func (o *AVAssetDownloadConfiguration) OptimizesAuxiliaryContentConfigurations() bool

Optimizes auxiliary content selection depending on the primary to minimize total number of video renditions downloaded. True by default. For example, if the primary content configuration represents stereo renditions and auxiliary content configuration represents multichannel audio renditions, auxiliary multichannel variant will be chosen so as to avoid downloading duplicate video renditions.

func (*AVAssetDownloadConfiguration) PrimaryContentConfiguration ¶

func (o *AVAssetDownloadConfiguration) PrimaryContentConfiguration() *AVAssetDownloadContentConfiguration

The primary content for the download.

func (*AVAssetDownloadConfiguration) SetArtworkData ¶

func (o *AVAssetDownloadConfiguration) SetArtworkData(artworkData *foundation.NSData)

func (*AVAssetDownloadConfiguration) SetAuxiliaryContentConfigurations ¶

func (o *AVAssetDownloadConfiguration) SetAuxiliaryContentConfigurations(auxiliaryContentConfigurations *foundation.NSArray[*AVAssetDownloadContentConfiguration])

func (*AVAssetDownloadConfiguration) SetDownloadsInterstitialAssets ¶

func (o *AVAssetDownloadConfiguration) SetDownloadsInterstitialAssets(downloadsInterstitialAssets bool)

func (*AVAssetDownloadConfiguration) SetInterstitialMediaSelectionCriteriaForMediaCharacteristic ¶

func (o *AVAssetDownloadConfiguration) SetInterstitialMediaSelectionCriteriaForMediaCharacteristic(criteria *foundation.NSArray[*AVPlayerMediaSelectionCriteria], mediaCharacteristic *foundation.NSString)

Sets media selection on interstitials for this asset Typically, interstitial assets have not been discovered when the main download is initiated. This method allows the user to specify AVMediaSelectionCriteria for all interstitials that are discovered. Each AVPlayerMediaSelectionCriteria in the array of criteria specfies a set of criteria for a variant to download. - Parameter criteria: The array of selection criteria to set - Parameter mediaCharacteristic: The AVMediaCharacteristic to which the criteria will be applied

func (*AVAssetDownloadConfiguration) SetOptimizesAuxiliaryContentConfigurations ¶

func (o *AVAssetDownloadConfiguration) SetOptimizesAuxiliaryContentConfigurations(optimizesAuxiliaryContentConfigurations bool)

type AVAssetDownloadContentConfiguration ¶

type AVAssetDownloadContentConfiguration struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetdownloadcontentconfiguration

func AVAssetDownloadContentConfigurationFromID ¶

func AVAssetDownloadContentConfigurationFromID(id objc.ID) *AVAssetDownloadContentConfiguration

func (*AVAssetDownloadContentConfiguration) MediaSelections ¶

An array of media selections obtained from the AVAsset. If a media selection is not provided, automatic media selection associated with the asset will be used.

func (*AVAssetDownloadContentConfiguration) SetMediaSelections ¶

func (o *AVAssetDownloadContentConfiguration) SetMediaSelections(mediaSelections *foundation.NSArray[*AVMediaSelection])

func (*AVAssetDownloadContentConfiguration) SetVariantQualifiers ¶

func (o *AVAssetDownloadContentConfiguration) SetVariantQualifiers(variantQualifiers *foundation.NSArray[*AVAssetVariantQualifier])

func (*AVAssetDownloadContentConfiguration) VariantQualifiers ¶

An array of variant qualifiers. The qualifiers are expected to be added in the preferential order and will be evaluated in that order until the qualifier matches one or more AVAssetVariants. Only those variants which can be played on the current device configuration will be initially chosen for evaluation. If there is more than one match, automatic variant selection will be used to choose among the matched. If a variant qualifier is constructed to explicitly choose a variant, no evaluation is performed and the variant provided will be downloaded as is, even if it is not playable on current device configuration. If a variant qualifier has not been provided, or if the variant qualifier when evaluated does not match any of the variants which can be played according to the current device configuration, automatic variant selection will be used.

type AVAssetDownloadDelegate ¶

type AVAssetDownloadDelegate interface {
	foundation.NSURLSessionTaskDelegate
}

AVAssetDownloadDelegate wraps the ObjC protocol AVAssetDownloadDelegate.

type AVAssetDownloadStorageManagementPolicy ¶

type AVAssetDownloadStorageManagementPolicy struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetdownloadstoragemanagementpolicy

func AVAssetDownloadStorageManagementPolicyFromID ¶

func AVAssetDownloadStorageManagementPolicyFromID(id objc.ID) *AVAssetDownloadStorageManagementPolicy

func (*AVAssetDownloadStorageManagementPolicy) ExpirationDate ¶

Returns the expiration date of asset.

func (*AVAssetDownloadStorageManagementPolicy) Priority ¶

Indicates the eviction priority of downloaded asset. Assets with default priority will be purged first before assets with higher priorities. In case this is not set, default priority is used.

type AVAssetDownloadStorageManager ¶

type AVAssetDownloadStorageManager struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetdownloadstoragemanager

func AVAssetDownloadStorageManagerFromID ¶

func AVAssetDownloadStorageManagerFromID(id objc.ID) *AVAssetDownloadStorageManager

func AVAssetDownloadStorageManagerSharedDownloadStorageManager ¶

func AVAssetDownloadStorageManagerSharedDownloadStorageManager() *AVAssetDownloadStorageManager

returns singleton instance.

func (*AVAssetDownloadStorageManager) SetStorageManagementPolicyForURL ¶

func (o *AVAssetDownloadStorageManager) SetStorageManagementPolicyForURL(storageManagementPolicy *AVAssetDownloadStorageManagementPolicy, downloadStorageURL *foundation.NSURL)

Sets the policy for asset with disk backing at downloadStorageURL. - Parameter downloadStorageURL: The location of downloaded asset.

func (*AVAssetDownloadStorageManager) StorageManagementPolicyForURL ¶

func (o *AVAssetDownloadStorageManager) StorageManagementPolicyForURL(downloadStorageURL *foundation.NSURL) *AVAssetDownloadStorageManagementPolicy

Returns the storage management policy for asset downloaded at downloadStorageURL. This may be nil if a storageManagementPolicy was never set on the downloaded asset. - Parameter downloadStorageURL: The location of downloaded asset.

type AVAssetDownloadTask ¶

type AVAssetDownloadTask struct {
	foundation.NSURLSessionTask
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetdownloadtask

func AVAssetDownloadTaskFromID ¶

func AVAssetDownloadTaskFromID(id objc.ID) *AVAssetDownloadTask

func (*AVAssetDownloadTask) LoadedTimeRanges ¶

func (o *AVAssetDownloadTask) LoadedTimeRanges() *foundation.NSArray[*foundation.NSValue]

This property provides a collection of time ranges for which the download task has media data already downloaded and playable. The ranges provided might be discontinuous. Returns an NSArray of NSValues containing CMTimeRanges. Deprecated: Use NSURLSessionTask.progress instead

func (*AVAssetDownloadTask) Options ¶

The options supplied to the download task upon initialization. Deprecated: Use AVAssetDownloadConfiguration instead

func (*AVAssetDownloadTask) URLAsset ¶

func (o *AVAssetDownloadTask) URLAsset() *AVURLAsset

The asset supplied to the download task upon initialization.

type AVAssetDownloadURLSession ¶

type AVAssetDownloadURLSession struct {
	foundation.NSURLSession
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetdownloadurlsession

func AVAssetDownloadURLSessionFromID ¶

func AVAssetDownloadURLSessionFromID(id objc.ID) *AVAssetDownloadURLSession

func AVAssetDownloadURLSessionSessionWithConfigurationAssetDownloadDelegateDelegateQueue ¶

func AVAssetDownloadURLSessionSessionWithConfigurationAssetDownloadDelegateDelegateQueue(configuration *foundation.NSURLSessionConfiguration, delegate AVAssetDownloadDelegate, delegateQueue *foundation.NSOperationQueue) *AVAssetDownloadURLSession

Creates and initializes an AVAssetDownloadURLSession for use with AVAssetDownloadTasks. - Parameter configuration: The configuration for this URLSession. Must be a background configuration. - Parameter delegate: The delegate object to handle asset download progress updates and other session related events. - Parameter delegateQueue: The queue to receive delegate callbacks on. If nil, a serial queue will be provided.

func (*AVAssetDownloadURLSession) AggregateAssetDownloadTaskWithURLAssetMediaSelectionsAssetTitleAssetArtworkDataOptions ¶

func (o *AVAssetDownloadURLSession) AggregateAssetDownloadTaskWithURLAssetMediaSelectionsAssetTitleAssetArtworkDataOptions(uRLAsset *AVURLAsset, mediaSelections *foundation.NSArray[*AVMediaSelection], title *foundation.NSString, artworkData *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAggregateAssetDownloadTask

Creates and initializes an AVAggregateAssetDownloadTask to download multiple AVMediaSelections on an AVURLAsset. This method may return nil if the URLSession has been invalidated. The value of AVAssetDownloadTaskMediaSelectionKey will be ignored. - Parameter URLAsset: The AVURLAsset to download locally. - Parameter mediaSelections: A list of AVMediaSelections. Each AVMediaSelection will correspond to a childAssetDownloadTask. Use -[AVAsset allMediaSelections] to download all AVMediaSelections on this AVAsset. - Parameter title: A human readable title for this asset, expected to be as suitable as possible for the user's preferred languages. Will show up in the usage pane of the settings app. - Parameter artworkData: Artwork data for this asset. Optional. Will show up in the usage pane of the settings app. - Parameter options: See AVAssetDownloadTask*Key above. Configures non-default behavior for the download task. Deprecated: Use assetDownloadTaskWithConfiguration: instead

func (*AVAssetDownloadURLSession) AssetDownloadTaskWithConfiguration ¶

func (o *AVAssetDownloadURLSession) AssetDownloadTaskWithConfiguration(downloadConfiguration *AVAssetDownloadConfiguration) *AVAssetDownloadTask

Creates and initializes an AVAssetDownloadTask to be used with this AVAssetDownloadURLSession. This method will throw an exception if the URLSession has been invalidated. - Parameter downloadConfiguration: The configuration to be used to create the download task.

func (*AVAssetDownloadURLSession) AssetDownloadTaskWithURLAssetAssetTitleAssetArtworkDataOptions ¶

func (o *AVAssetDownloadURLSession) AssetDownloadTaskWithURLAssetAssetTitleAssetArtworkDataOptions(uRLAsset *AVURLAsset, title *foundation.NSString, artworkData *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetDownloadTask

Creates and initializes an AVAssetDownloadTask to be used with this AVAssetDownloadURLSession. This method may return nil if the URLSession has been invalidated. - Parameter URLAsset: The AVURLAsset to download locally. - Parameter title: A human readable title for this asset, expected to be as suitable as possible for the user's preferred languages. Will show up in the usage pane of the settings app. - Parameter artworkData: NSData representing artwork data for this asset. Optional. Will show up in the usage pane of the settings app. Must work with +[UIImage imageWithData:]. - Parameter options: See AVAssetDownloadTask*Key above. Configures non-default behavior for the download task. Using this parameter is required for downloading non-default media selections for HLS assets. Deprecated: Use assetDownloadTaskWithConfiguration: instead

type AVAssetExportSession ¶

type AVAssetExportSession struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetexportsession

func AVAssetExportSessionExportSessionWithAssetPresetName ¶

func AVAssetExportSessionExportSessionWithAssetPresetName(asset *AVAsset, presetName *foundation.NSString) *AVAssetExportSession

@method exportSessionWithAsset:presetName: @abstract Returns an instance of AVAssetExportSession for the specified source asset and preset. @param asset An AVAsset object that is intended to be exported. @param presetName An NSString specifying the name of the preset template for the export. @result An instance of AVAssetExportSession. @discussion If the specified asset belongs to a mutable subclass of AVAsset, AVMutableComposition or AVMutableMovie, the results of any export-related operation are undefined if you mutate the asset after the operation commences. These operations include but are not limited to: 1) testing the compatibility of export presets with the asset, 2) calculating the maximum duration or estimated length of the output file, and 3) the export operation itself.

func AVAssetExportSessionFromID ¶

func AVAssetExportSessionFromID(id objc.ID) *AVAssetExportSession

func (*AVAssetExportSession) AllowsParallelizedExport ¶

func (o *AVAssetExportSession) AllowsParallelizedExport() bool

@property allowsParallelizedExport @abstract Determines whether or not parallelization can be employed in the export. @discussion On select platforms, there may be opportunities to expedite the export by using additional resources in parallel. If set to YES, export parallelization will be enabled, only if parallelization requirements are met. There will be no error signaled if export parallelization is not achievable, and instead the export will proceed as normal (without parallelization). If set to NO, export parallelization will not be used.

func (*AVAssetExportSession) Asset ¶

func (o *AVAssetExportSession) Asset() *AVAsset

func (*AVAssetExportSession) AudioMix ¶

func (o *AVAssetExportSession) AudioMix() *AVAudioMix

func (*AVAssetExportSession) AudioTimePitchAlgorithm ¶

func (o *AVAssetExportSession) AudioTimePitchAlgorithm() *foundation.NSString

func (*AVAssetExportSession) AudioTrackGroupHandling ¶

func (o *AVAssetExportSession) AudioTrackGroupHandling() AVAssetTrackGroupOutputHandling

@property audioTrackGroupHandling @abstract Defines export policy for handling alternate audio tracks @discussion Specifies the handling of audio tracks that are members of the same alternate track group corresponding to an exported audio track in the source asset. If no audio track group is present, the value of this property has no effect. If necessary, use the trackGroups property of AVAsset to determine whether any audio track groups are present. The AVAudioMix property is not allowed to be used when also specifying alternate track output handling. An exception will be thrown if both are specified.

func (*AVAssetExportSession) CanPerformMultiplePassesOverSourceMediaData ¶

func (o *AVAssetExportSession) CanPerformMultiplePassesOverSourceMediaData() bool

@property canPerformMultiplePassesOverSourceMediaData @abstract Determines whether the export session can perform multiple passes over the source media to achieve better results. @discussion When the value for this property is YES, the export session can produce higher quality results at the expense of longer export times. Setting this property to YES may also require the export session to write temporary data to disk during the export. To control the location of temporary data, use the property directoryForTemporaryFiles. The default value is NO. Not all export session configurations can benefit from performing multiple passes over the source media. In these cases, setting this property to YES has no effect. This property cannot be set after the export has started.

func (*AVAssetExportSession) CancelExport ¶

func (o *AVAssetExportSession) CancelExport()

@method cancelExport @abstract Cancels the execution of an export session. @discussion Cancel can be invoked when the export is running.

func (*AVAssetExportSession) CustomVideoCompositor ¶

func (o *AVAssetExportSession) CustomVideoCompositor() AVVideoCompositing

func (*AVAssetExportSession) DetermineCompatibleFileTypesWithCompletionHandler ¶

func (o *AVAssetExportSession) DetermineCompatibleFileTypesWithCompletionHandler(handler objc.Block)

@method determineCompatibleFileTypesWithCompletionHandler: @abstract Performs an inspection on the AVAsset and Preset the object was initialized with to determine a list of file types the ExportSession can write. @param handler Called when the inspection completes with an array of file types the ExportSession can write. Note that this may have a count of zero. @discussion This method is different than the supportedFileTypes property in that it performs an inspection of the AVAsset in order to determine its compatibility with each of the session's supported file types.

func (*AVAssetExportSession) DirectoryForTemporaryFiles ¶

func (o *AVAssetExportSession) DirectoryForTemporaryFiles() *foundation.NSURL

@property directoryForTemporaryFiles @abstract Specifies a directory that is suitable for containing temporary files generated during the export process @discussion AVAssetExportSession may need to write temporary files when configured in certain ways, such as when canPerformMultiplePassesOverSourceMediaData is set to YES. This property can be used to control where in the filesystem those temporary files are created. All temporary files will be deleted when the export is completed, is canceled, or fails. When the value of this property is nil, the export session will choose a suitable location when writing temporary files. The default value is nil. This property cannot be set after the export has started. The export will fail if the URL points to a location that is not a directory, does not exist, is not on the local file system, or if a file cannot be created in this directory (for example, due to insufficient permissions or sandboxing restrictions).

func (*AVAssetExportSession) Error ¶

func (o *AVAssetExportSession) Error() unsafe.Pointer

func (*AVAssetExportSession) EstimateMaximumDurationWithCompletionHandler ¶

func (o *AVAssetExportSession) EstimateMaximumDurationWithCompletionHandler(handler objc.Block)

@method estimateMaximumDurationWithCompletionHandler: @abstract Starts the asynchronous execution of estimating the maximum duration of the export based on the asset, preset, and fileLengthLimit associated with the export session. @discussion If fileLengthLimit is not set on the export session, fileLengthLimit will be assumed to be the maximum file size specified by the preset (if any); else infinite. @param handler A block called with the estimated maximum duration, or kCMTimeInvalid if an error occurs. The error parameter will be non-nil if an error occurs.

func (*AVAssetExportSession) EstimateOutputFileLengthWithCompletionHandler ¶

func (o *AVAssetExportSession) EstimateOutputFileLengthWithCompletionHandler(handler func(int64, unsafe.Pointer))

@method estimateOutputFileLengthWithCompletionHandler: @abstract Starts the asynchronous execution of estimating the output file length of the export based on the asset, preset, and timeRange associated with the export session. @discussion If timeRange is not set on the export session, timeRange will be assumed to be the full time range of the asset. @param handler A block called with the estimated output file length in bytes, if it can be determined; 0 otherwise. The error parameter will be non-nil if an error occurs.

func (*AVAssetExportSession) EstimatedOutputFileLength deprecated

func (o *AVAssetExportSession) EstimatedOutputFileLength() int64

Deprecated: Use estimateOutputFileLengthWithCompletionHandler: instead

func (*AVAssetExportSession) ExportAsynchronouslyWithCompletionHandler ¶

func (o *AVAssetExportSession) ExportAsynchronouslyWithCompletionHandler(handler func())

@method exportAsynchronouslyWithCompletionHandler: @abstract Starts the asynchronous execution of an export session. @param handler If internal preparation for export fails, the handler will be invoked synchronously. The handler may also be called asynchronously after -exportAsynchronouslyWithCompletionHandler: returns, in the following cases: 1) if a failure occurs during the export, including failures of loading, re-encoding, or writing media data to the output, 2) if -cancelExport is invoked, 3) if export session succeeds, having completely written its output to the outputURL. In each case, AVAssetExportSession.status will signal the terminal state of the asset reader, and if a failure occurs, the NSError that describes the failure can be obtained from the error property. @discussion Initiates an asynchronous export operation and returns immediately.

func (*AVAssetExportSession) FileLengthLimit ¶

func (o *AVAssetExportSession) FileLengthLimit() int64

func (*AVAssetExportSession) InitWithAssetPresetName ¶

func (o *AVAssetExportSession) InitWithAssetPresetName(asset *AVAsset, presetName *foundation.NSString) *AVAssetExportSession

@method initWithAsset:presetName: @abstract Initialize an AVAssetExportSession with the specified preset and set the source to the contents of the asset. @param asset An AVAsset object that is intended to be exported. @param presetName An NSString specifying the name of the preset template for the export. @result Returns the initialized AVAssetExportSession. @discussion If the specified asset belongs to a mutable subclass of AVAsset, AVMutableComposition or AVMutableMovie, the results of any export-related operation are undefined if you mutate the asset after the operation commences. These operations include but are not limited to: 1) testing the compatibility of export presets with the asset, 2) calculating the maximum duration or estimated length of the output file, and 3) the export operation itself.

func (*AVAssetExportSession) MaxDuration deprecated

func (o *AVAssetExportSession) MaxDuration() coremedia.CMTime

Deprecated: Use estimateMaximumDurationWithCompletionHandler: instead

func (*AVAssetExportSession) Metadata ¶

func (*AVAssetExportSession) MetadataItemFilter ¶

func (o *AVAssetExportSession) MetadataItemFilter() *AVMetadataItemFilter

func (*AVAssetExportSession) OutputFileType ¶

func (o *AVAssetExportSession) OutputFileType() *foundation.NSString

func (*AVAssetExportSession) OutputURL deprecated

func (o *AVAssetExportSession) OutputURL() *foundation.NSURL

Deprecated: Use export(to:as:) async throws instead

func (*AVAssetExportSession) PresetName ¶

func (o *AVAssetExportSession) PresetName() *foundation.NSString

func (*AVAssetExportSession) Progress ¶

func (o *AVAssetExportSession) Progress() float32

func (*AVAssetExportSession) SetAllowsParallelizedExport ¶

func (o *AVAssetExportSession) SetAllowsParallelizedExport(allowsParallelizedExport bool)

func (*AVAssetExportSession) SetAudioMix ¶

func (o *AVAssetExportSession) SetAudioMix(audioMix *AVAudioMix)

func (*AVAssetExportSession) SetAudioTimePitchAlgorithm ¶

func (o *AVAssetExportSession) SetAudioTimePitchAlgorithm(audioTimePitchAlgorithm *foundation.NSString)

func (*AVAssetExportSession) SetAudioTrackGroupHandling ¶

func (o *AVAssetExportSession) SetAudioTrackGroupHandling(audioTrackGroupHandling AVAssetTrackGroupOutputHandling)

func (*AVAssetExportSession) SetCanPerformMultiplePassesOverSourceMediaData ¶

func (o *AVAssetExportSession) SetCanPerformMultiplePassesOverSourceMediaData(canPerformMultiplePassesOverSourceMediaData bool)

func (*AVAssetExportSession) SetDirectoryForTemporaryFiles ¶

func (o *AVAssetExportSession) SetDirectoryForTemporaryFiles(directoryForTemporaryFiles *foundation.NSURL)

func (*AVAssetExportSession) SetFileLengthLimit ¶

func (o *AVAssetExportSession) SetFileLengthLimit(fileLengthLimit int64)

func (*AVAssetExportSession) SetMetadata ¶

func (o *AVAssetExportSession) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVAssetExportSession) SetMetadataItemFilter ¶

func (o *AVAssetExportSession) SetMetadataItemFilter(metadataItemFilter *AVMetadataItemFilter)

func (*AVAssetExportSession) SetOutputFileType ¶

func (o *AVAssetExportSession) SetOutputFileType(outputFileType *foundation.NSString)

func (*AVAssetExportSession) SetOutputURL ¶

func (o *AVAssetExportSession) SetOutputURL(outputURL *foundation.NSURL)

func (*AVAssetExportSession) SetShouldOptimizeForNetworkUse ¶

func (o *AVAssetExportSession) SetShouldOptimizeForNetworkUse(shouldOptimizeForNetworkUse bool)

func (*AVAssetExportSession) SetTimeRange ¶

func (o *AVAssetExportSession) SetTimeRange(timeRange coremedia.CMTimeRange)

func (*AVAssetExportSession) SetVideoComposition ¶

func (o *AVAssetExportSession) SetVideoComposition(videoComposition *AVVideoComposition)

func (*AVAssetExportSession) ShouldOptimizeForNetworkUse deprecated

func (o *AVAssetExportSession) ShouldOptimizeForNetworkUse() bool

Deprecated: Use export(to:as:) async throws instead

func (*AVAssetExportSession) Status ¶

func (*AVAssetExportSession) SupportedFileTypes ¶

func (o *AVAssetExportSession) SupportedFileTypes() *foundation.NSArray[*foundation.NSString]

func (*AVAssetExportSession) TimeRange ¶

func (*AVAssetExportSession) VideoComposition ¶

func (o *AVAssetExportSession) VideoComposition() *AVVideoComposition

type AVAssetExportSessionStatus ¶

type AVAssetExportSessionStatus int64
const (
	AVAssetExportSessionStatusUnknown   AVAssetExportSessionStatus = 0
	AVAssetExportSessionStatusWaiting   AVAssetExportSessionStatus = 1
	AVAssetExportSessionStatusExporting AVAssetExportSessionStatus = 2
	AVAssetExportSessionStatusCompleted AVAssetExportSessionStatus = 3
	AVAssetExportSessionStatusFailed    AVAssetExportSessionStatus = 4
	AVAssetExportSessionStatusCancelled AVAssetExportSessionStatus = 5
)

func (AVAssetExportSessionStatus) String ¶

type AVAssetImageGenerator ¶

type AVAssetImageGenerator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetimagegenerator

func AVAssetImageGeneratorAssetImageGeneratorWithAsset ¶

func AVAssetImageGeneratorAssetImageGeneratorWithAsset(asset *AVAsset) *AVAssetImageGenerator

@method assetImageGeneratorWithAsset: @abstract Returns an instance of AVAssetImageGenerator for use with the specified asset. @param asset The asset from which images will be extracted. @result An instance of AVAssetImageGenerator @discussion This method may succeed even if the asset possesses no visual tracks at the time of initialization. Clients may wish to test whether an asset has any tracks with the visual characteristic via -[AVAsset tracksWithMediaCharacteristic:]. Note also that assets that belong to a mutable subclass of AVAsset, AVMutableComposition or AVMutableMovie, may gain visual tracks after initialization of an associated AVAssetImageGenerator. However, the results of image generation are undefined if mutations of the asset occur while images are being generated. AVAssetImageGenerator will use the default enabled video track(s) to generate images.

func AVAssetImageGeneratorFromID ¶

func AVAssetImageGeneratorFromID(id objc.ID) *AVAssetImageGenerator

func (*AVAssetImageGenerator) ApertureMode ¶

func (o *AVAssetImageGenerator) ApertureMode() *foundation.NSString

func (*AVAssetImageGenerator) AppliesPreferredTrackTransform ¶

func (o *AVAssetImageGenerator) AppliesPreferredTrackTransform() bool

func (*AVAssetImageGenerator) Asset ¶

func (o *AVAssetImageGenerator) Asset() *AVAsset

func (*AVAssetImageGenerator) CancelAllCGImageGeneration ¶

func (o *AVAssetImageGenerator) CancelAllCGImageGeneration()

@method cancelAllCGImageGeneration @abstract Cancels all outstanding image generation requests. @discussion Calls the handler block with AVAssetImageGeneratorCancelled for each image time in every previous invocation of -generateCGImagesAsynchronouslyForTimes:completionHandler: for which images have not yet been supplied.

func (*AVAssetImageGenerator) CopyCGImageAtTimeActualTimeError ¶

func (o *AVAssetImageGenerator) CopyCGImageAtTimeActualTimeError(requestedTime coremedia.CMTime, actualTime *coremedia.CMTime) (unsafe.Pointer, error)

@method copyCGImageAtTime:actualTime:error: @abstract Returns a CFRetained CGImageRef for an asset at or near the specified time. @param requestedTime The time at which the image of the asset is to be created. @param actualTime A pointer to a CMTime to receive the time at which the image was actually generated. If you are not interested in this information, pass NULL. @param outError An error object describing the reason for failure, in the event that this method returns NULL. @result A CGImageRef. @discussion Returns the CGImage synchronously. Ownership follows the Create Rule. Because of the nature of timed audiovisual media, generating an image may take significant time. AVAssetImageGenerator may have to block the calling thread in order to do so. In order to avoid blocking, clients can use -generateCGImagesAsynchronouslyForTimes:completionHandler: to request that one or more images be generated asynchronously and to be notified when they become available. On iOS and tvOS, it is particularly important to avoid blocking. To preserve responsiveness, a synchronous request that blocks for too long (eg, a request to generate an image from an asset on a slow HTTP server) may lead to media services being reset. Deprecated: Use generateCGImageAsynchronouslyForTime:completionHandler: instead

func (*AVAssetImageGenerator) CustomVideoCompositor ¶

func (o *AVAssetImageGenerator) CustomVideoCompositor() AVVideoCompositing

func (*AVAssetImageGenerator) DynamicRangePolicy ¶

func (o *AVAssetImageGenerator) DynamicRangePolicy() *foundation.NSString

@property dynamicRangePolicy @abstract Configures the video dynamic range for the output CGImage @discussion Default is AVAssetImageGeneratorDynamicRangePolicyForceSDR

func (*AVAssetImageGenerator) GenerateCGImageAsynchronouslyForTimeCompletionHandler ¶

func (o *AVAssetImageGenerator) GenerateCGImageAsynchronouslyForTimeCompletionHandler(requestedTime coremedia.CMTime, handler objc.Block)

@method generateCGImageAsynchronouslyForTime:completionHandler: @abstract Returns a CGImageRef for an asset at or near the specified time. @param requestedTime A CMTime, specifying the asset time at which an image is requested. @param handler A block that will be called when the image request is complete. @discussion The client will receive exactly one handler callback for requestedTime. Changes to generator properties (snap behavior, maximum size, etc...) will not affect outstanding asynchronous image generation requests. The generated image is not retained. Clients should retain the image if they wish it to persist after the completion handler returns. If image generation succeeds, the `image` parameter to the completion handler will be non-NULL and the `error` parameter will be nil. If image generation fails or was cancelled, the `image` parameter will be NULL and the `error` parameter will describe what went wrong. For cancelled images, the returned error will be AVErrorOperationCancelled.

func (*AVAssetImageGenerator) GenerateCGImagesAsynchronouslyForTimesCompletionHandler ¶

func (o *AVAssetImageGenerator) GenerateCGImagesAsynchronouslyForTimesCompletionHandler(requestedTimes *foundation.NSArray[*foundation.NSValue], handler objc.Block)

@method generateCGImagesAsynchronouslyForTimes:completionHandler: @abstract Returns a series of CGImageRefs for an asset at or near the specified times. @param requestedTimes An NSArray of NSValues, each containing a CMTime, specifying the asset times at which an image is requested. @param handler A block that will be called when an image request is complete. @discussion Employs an efficient "batch mode" for getting images in time order. The client will receive exactly one handler callback for each requested time in requestedTimes. Changes to generator properties (snap behavior, maximum size, etc...) will not affect outstanding asynchronous image generation requests. The generated image is not retained. Clients should retain the image if they wish it to persist after the completion handler returns.

func (*AVAssetImageGenerator) InitWithAsset ¶

func (o *AVAssetImageGenerator) InitWithAsset(asset *AVAsset) *AVAssetImageGenerator

@method initWithAsset: @abstract Initializes an instance of AVAssetImageGenerator for use with the specified asset. @param asset The asset from which images will be extracted. @result An instance of AVAssetImageGenerator @discussion This method may succeed even if the asset possesses no visual tracks at the time of initialization. Clients may wish to test whether an asset has any tracks with the visual characteristic via -[AVAsset tracksWithMediaCharacteristic:]. Note also that assets that belong to a mutable subclass of AVAsset, AVMutableComposition or AVMutableMovie, may gain visual tracks after initialization of an associated AVAssetImageGenerator. However, the results of image generation are undefined if mutations of the asset occur while images are being generated. AVAssetImageGenerator will use the default enabled video track(s) to generate images.

func (*AVAssetImageGenerator) MaximumSize ¶

func (o *AVAssetImageGenerator) MaximumSize() corefoundation.CGSize

func (*AVAssetImageGenerator) RequestedTimeToleranceAfter ¶

func (o *AVAssetImageGenerator) RequestedTimeToleranceAfter() coremedia.CMTime

func (*AVAssetImageGenerator) RequestedTimeToleranceBefore ¶

func (o *AVAssetImageGenerator) RequestedTimeToleranceBefore() coremedia.CMTime

func (*AVAssetImageGenerator) SetApertureMode ¶

func (o *AVAssetImageGenerator) SetApertureMode(apertureMode *foundation.NSString)

func (*AVAssetImageGenerator) SetAppliesPreferredTrackTransform ¶

func (o *AVAssetImageGenerator) SetAppliesPreferredTrackTransform(appliesPreferredTrackTransform bool)

func (*AVAssetImageGenerator) SetDynamicRangePolicy ¶

func (o *AVAssetImageGenerator) SetDynamicRangePolicy(dynamicRangePolicy *foundation.NSString)

func (*AVAssetImageGenerator) SetMaximumSize ¶

func (o *AVAssetImageGenerator) SetMaximumSize(maximumSize corefoundation.CGSize)

func (*AVAssetImageGenerator) SetRequestedTimeToleranceAfter ¶

func (o *AVAssetImageGenerator) SetRequestedTimeToleranceAfter(requestedTimeToleranceAfter coremedia.CMTime)

func (*AVAssetImageGenerator) SetRequestedTimeToleranceBefore ¶

func (o *AVAssetImageGenerator) SetRequestedTimeToleranceBefore(requestedTimeToleranceBefore coremedia.CMTime)

func (*AVAssetImageGenerator) SetVideoComposition ¶

func (o *AVAssetImageGenerator) SetVideoComposition(videoComposition *AVVideoComposition)

func (*AVAssetImageGenerator) VideoComposition ¶

func (o *AVAssetImageGenerator) VideoComposition() *AVVideoComposition

@property videoComposition @abstract Specifies the video composition to use when extracting images from assets with multiple video tracks. @discussion If no videoComposition is specified, only the first enabled video track will be used. If a videoComposition is specified, the value of appliesPreferredTrackTransform is ignored. This property throws an exception if a video composition is set with any of the following property values: - "renderScale" is not equal to one - "renderSize" width or height is less than zero - "frameDuration" is invalid or less than or equal to zero - "sourceTrackIDForFrameTiming" is less than zero - "outputBufferDescription" is non-nil

type AVAssetImageGeneratorResult ¶

type AVAssetImageGeneratorResult int64
const (
	AVAssetImageGeneratorSucceeded AVAssetImageGeneratorResult = 0
	AVAssetImageGeneratorFailed    AVAssetImageGeneratorResult = 1
	AVAssetImageGeneratorCancelled AVAssetImageGeneratorResult = 2
)

func (AVAssetImageGeneratorResult) String ¶

type AVAssetPlaybackAssistant ¶

type AVAssetPlaybackAssistant struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetplaybackassistant

func AVAssetPlaybackAssistantAssetPlaybackAssistantWithAsset ¶

func AVAssetPlaybackAssistantAssetPlaybackAssistantWithAsset(asset *AVAsset) *AVAssetPlaybackAssistant

Returns an instance of AVAssetPlaybackAssistant for inspection of an AVAsset object. - Parameter asset: An instance of AVAsset. - Returns: An instance of AVAssetPlaybackAssistant.

func AVAssetPlaybackAssistantFromID ¶

func AVAssetPlaybackAssistantFromID(id objc.ID) *AVAssetPlaybackAssistant

func (*AVAssetPlaybackAssistant) LoadPlaybackConfigurationOptionsWithCompletionHandler ¶

func (o *AVAssetPlaybackAssistant) LoadPlaybackConfigurationOptionsWithCompletionHandler(completionHandler objc.Block)

Calls the completionHandler with information about the asset. completionHandler is called when all of the AVAssetPlaybackConfigurationOption values have been loaded. If AVAssetPlaybackAssistant encounters failures when inspecting the contents of the asset, it will return no AVAssetPlaybackConfigurationOptions associated with those contents. - Parameter completionHandler: Called with an array of AVAssetPlaybackConfigurationOption values describing capabilities of the asset.

type AVAssetReader ¶

type AVAssetReader struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreader

func AVAssetReaderAssetReaderWithAssetError ¶

func AVAssetReaderAssetReaderWithAssetError(asset *AVAsset) (*AVAssetReader, error)

@method assetReaderWithAsset:error: @abstract Returns an instance of AVAssetReader for reading media data from the specified asset. @param asset The asset from which media data is to be read. @param outError On return, if initialization of the AVAssetReader fails, points to an NSError describing the nature of the failure. @result An instance of AVAssetReader. @discussion If the specified asset belongs to a mutable subclass of AVAsset, AVMutableComposition or AVMutableMovie, the results of any asset reading operation are undefined if you mutate the asset after invoking -startReading.

func AVAssetReaderFromID ¶

func AVAssetReaderFromID(id objc.ID) *AVAssetReader

func (*AVAssetReader) AddOutput ¶

func (o *AVAssetReader) AddOutput(output *AVAssetReaderOutput)

@method addOutput: @abstract Adds an output to the receiver. @param output The AVAssetReaderOutput object to be added. @discussion Outputs are created with a reference to one or more AVAssetTrack objects. These tracks must be owned by the asset returned by the receiver's asset property. This method throws an exception if the output has already been added to an AVAssetReader or if reading has started (`status` has progressed beyond AVAssetReaderStatusUnknown).

func (*AVAssetReader) Asset ¶

func (o *AVAssetReader) Asset() *AVAsset

@property asset @abstract The asset from which the receiver's outputs read sample buffers. @discussion The value of this property is an AVAsset. Concrete instances of AVAssetReader that are created with specific AVAssetTrack instances must obtain those tracks from the asset returned by this property.

func (*AVAssetReader) CanAddOutput ¶

func (o *AVAssetReader) CanAddOutput(output *AVAssetReaderOutput) bool

@method canAddOutput: @abstract Tests whether an output can be added to the receiver. @param output The AVAssetReaderOutput object to be tested. @result A BOOL indicating whether the output can be added to the receiver. @discussion An output that reads from a track of an asset other than the asset used to initialize the receiver cannot be added.

func (*AVAssetReader) CancelReading ¶

func (o *AVAssetReader) CancelReading()

@method cancelReading @abstract Cancels any background work and prevents the receiver's outputs from reading more samples. @discussion Clients that want to stop reading samples from the receiver before reaching the end of its time range should call this method to stop any background read ahead operations that the may have been in progress. This method should not be called concurrently with any calls to -[AVAssetReaderOutput copyNextSampleBuffer].

func (*AVAssetReader) Error ¶

func (o *AVAssetReader) Error() unsafe.Pointer

@property error @abstract If the receiver's status is AVAssetReaderStatusFailed, this describes the error that caused the failure. @discussion The value of this property is an NSError that describes what caused the receiver to no longer be able to read its asset. If the receiver's status is not AVAssetReaderStatusFailed, the value of this property is nil. This property is thread safe.

func (*AVAssetReader) InitWithAssetError ¶

func (o *AVAssetReader) InitWithAssetError(asset *AVAsset) (*AVAssetReader, error)

@method initWithAsset:error: @abstract Creates an instance of AVAssetReader for reading media data from the specified asset. @param asset The asset from which media data is to be read. @param outError On return, if initialization of the AVAssetReader fails, points to an NSError describing the nature of the failure. @result An instance of AVAssetReader. @discussion If the specified asset belongs to a mutable subclass of AVAsset, AVMutableComposition or AVMutableMovie, the results of any asset reading operation are undefined if you mutate the asset after invoking -startReading.

func (*AVAssetReader) Outputs ¶

@property outputs @abstract The outputs from which clients of receiver can read media data. @discussion The value of this property is an NSArray containing concrete instances of AVAssetReaderOutput. Outputs can be added to the receiver using the addOutput: method.

func (*AVAssetReader) SetTimeRange ¶

func (o *AVAssetReader) SetTimeRange(timeRange coremedia.CMTimeRange)

func (*AVAssetReader) StartReading ¶

func (o *AVAssetReader) StartReading() bool

@method startReading @abstract Prepares the receiver for reading sample buffers from the asset. @result A BOOL indicating whether reading could be started. @discussion This method validates the entire collection of settings for outputs for tracks, for audio mixing, and for video composition and initiates reading from the receiver's asset. If this method returns NO, clients can determine the nature of the failure by checking the value of the status and error properties. This method throws an exception if reading has already started (`status` has progressed beyond AVAssetReaderStatusUnknown).

func (*AVAssetReader) Status ¶

func (o *AVAssetReader) Status() AVAssetReaderStatus

@property status @abstract The status of reading sample buffers from the receiver's asset. @discussion The value of this property is an AVAssetReaderStatus that indicates whether reading is in progress, has completed successfully, has been canceled, or has failed. Clients of AVAssetReaderOutput objects should check the value of this property after -[AVAssetReaderOutput copyNextSampleBuffer] returns NULL to determine why no more samples could be read. This property is thread safe.

func (*AVAssetReader) TimeRange ¶

func (o *AVAssetReader) TimeRange() coremedia.CMTimeRange

@property timeRange @abstract Specifies a range of time that may limit the temporal portion of the receiver's asset from which media data will be read. @discussion The intersection of the value of timeRange and CMTimeRangeMake(kCMTimeZero, asset.duration) will determine the time range of the asset from which media data will be read. The default value of timeRange is CMTimeRangeMake(kCMTimeZero, kCMTimePositiveInfinity). This property throws an exception if a value is set after reading has started.

type AVAssetReaderAudioMixOutput ¶

type AVAssetReaderAudioMixOutput struct {
	AVAssetReaderOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreaderaudiomixoutput

func AVAssetReaderAudioMixOutputAssetReaderAudioMixOutputWithAudioTracksAudioSettings ¶

func AVAssetReaderAudioMixOutputAssetReaderAudioMixOutputWithAudioTracksAudioSettings(audioTracks *foundation.NSArray[*AVAssetTrack], audioSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetReaderAudioMixOutput

@method assetReaderAudioMixOutputWithAudioTracks:audioSettings: @abstract Returns an instance of AVAssetReaderAudioMixOutput for reading mixed audio from the specified audio tracks, with optional audio settings. @param tracks An NSArray of AVAssetTrack objects from which the created object should read sample buffers to be mixed. @param audioSettings An NSDictionary of audio settings to be used for audio output. @result An instance of AVAssetReaderAudioMixOutput. @discussion Each track must be one of the tracks owned by the target AVAssetReader's asset and must be of media type AVMediaTypeAudio. For non-nil values of audioSettings, the audio settings dictionary must contain values for keys in AVAudioSettings.h (linear PCM only). Initialization will fail if the audio settings cannot be used with the specified tracks. AVSampleRateConverterAudioQualityKey is not supported. A value of nil for audioSettings configures the output to return samples in a convenient uncompressed format, with sample rate and other properties determined according to the properties of the specified audio tracks as well as other considerations that may vary according to device capabilities, operating system version, and other factors. Therefore if you wish to perform any processing on the output, you must examine the CMAudioFormatDescription of the CMSampleBuffers that are provided in order to ensure that your processing is appropriately configured for the output format.

func AVAssetReaderAudioMixOutputFromID ¶

func AVAssetReaderAudioMixOutputFromID(id objc.ID) *AVAssetReaderAudioMixOutput

func (*AVAssetReaderAudioMixOutput) AudioMix ¶

func (o *AVAssetReaderAudioMixOutput) AudioMix() *AVAudioMix

@property audioMix @abstract The audio mix used by the receiver. @discussion The value of this property is an AVAudioMix that can be used to specify how the volume of audio samples read from each source track will change over the timeline of the source asset. This property throws an exception for any of the following reasons: - an audio mix is set after reading has started (the asset reader has progressed beyond AVAssetReaderStatusUnknown) - setting an audio mix containing a track that was not used to create the receiver - an audio mix is set containing an invalid audio time pitch algorithm

func (*AVAssetReaderAudioMixOutput) AudioSettings ¶

@property audioSettings @abstract The audio settings used by the receiver. @discussion The value of this property is an NSDictionary that contains values for keys from AVAudioSettings.h (linear PCM only). A value of nil indicates that the receiver will return audio samples in a convenient uncompressed format, with sample rate and other properties determined according to the properties of the receiver's audio tracks.

func (*AVAssetReaderAudioMixOutput) AudioTimePitchAlgorithm ¶

func (o *AVAssetReaderAudioMixOutput) AudioTimePitchAlgorithm() *foundation.NSString

@property audioTimePitchAlgorithm @abstract Indicates the processing algorithm used to manage audio pitch for scaled audio edits. @discussion Constants for various time pitch algorithms, e.g. AVAudioTimePitchAlgorithmSpectral, are defined in AVAudioProcessingSettings.h. An NSInvalidArgumentException will be raised if this property is set to a value other than the constants defined in that file. The default value is AVAudioTimePitchAlgorithmSpectral.

func (*AVAssetReaderAudioMixOutput) AudioTracks ¶

@property audioTracks @abstract The tracks from which the receiver reads mixed audio. @discussion The value of this property is an NSArray of AVAssetTracks owned by the target AVAssetReader's asset.

func (*AVAssetReaderAudioMixOutput) InitWithAudioTracksAudioSettings ¶

func (o *AVAssetReaderAudioMixOutput) InitWithAudioTracksAudioSettings(audioTracks *foundation.NSArray[*AVAssetTrack], audioSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetReaderAudioMixOutput

@method initWithAudioTracks:audioSettings: @abstract Creates an instance of AVAssetReaderAudioMixOutput for reading mixed audio from the specified audio tracks, with optional audio settings. @param tracks An NSArray of AVAssetTrack objects from which the created object should read sample buffers to be mixed. @param audioSettings An NSDictionary of audio settings to be used for audio output. @result An instance of AVAssetReaderAudioMixOutput. @discussion Each track must be one of the tracks owned by the target AVAssetReader's asset and must be of media type AVMediaTypeAudio. For non-nil values of audioSettings, the audio settings dictionary must contain values for keys in AVAudioSettings.h (linear PCM only). Initialization will fail if the audio settings cannot be used with the specified tracks. AVSampleRateConverterAudioQualityKey is not supported. A value of nil for audioSettings configures the output to return samples in a convenient uncompressed format, with sample rate and other properties determined according to the properties of the specified audio tracks as well as other considerations that may vary according to device capabilities, operating system version, and other factors. Therefore if you wish to perform any processing on the output, you must examine the CMAudioFormatDescription of the CMSampleBuffers that are provided in order to ensure that your processing is appropriately configured for the output format. This method throws an exception for any of the following reasons: - an audio track does not have media type AVMediaTypeAudio - an audio track belongs to a different AVAsset - the audio settings contains an AVSampleRateConverterAudioQualityKey - the output would be compressed

func (*AVAssetReaderAudioMixOutput) SetAudioMix ¶

func (o *AVAssetReaderAudioMixOutput) SetAudioMix(audioMix *AVAudioMix)

func (*AVAssetReaderAudioMixOutput) SetAudioTimePitchAlgorithm ¶

func (o *AVAssetReaderAudioMixOutput) SetAudioTimePitchAlgorithm(audioTimePitchAlgorithm *foundation.NSString)

type AVAssetReaderCaptionValidationHandling ¶

type AVAssetReaderCaptionValidationHandling interface {
}

AVAssetReaderCaptionValidationHandling wraps the ObjC protocol AVAssetReaderCaptionValidationHandling.

type AVAssetReaderOutput ¶

type AVAssetReaderOutput struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreaderoutput

func AVAssetReaderOutputFromID ¶

func AVAssetReaderOutputFromID(id objc.ID) *AVAssetReaderOutput

func (*AVAssetReaderOutput) AlwaysCopiesSampleData ¶

func (o *AVAssetReaderOutput) AlwaysCopiesSampleData() bool

@property alwaysCopiesSampleData @abstract Indicates whether or not the data in buffers gets copied before being vended to the client. @discussion When the value of this property is YES, the AVAssetReaderOutput will always vend a buffer with copied data to the client. Data in such buffers can be freely modified by the client. When the value of this property is NO, the buffers vended to the client may not be copied. Such buffers may still be referenced by other entities. The result of modifying a buffer whose data hasn't been copied is undefined. Requesting buffers whose data hasn't been copied when possible can lead to performance improvements. The default value is YES. This property throws an exception if a value is set after reading has started (the asset reader has progressed beyond AVAssetReaderStatusUnknown).

func (*AVAssetReaderOutput) CopyNextSampleBuffer ¶

func (o *AVAssetReaderOutput) CopyNextSampleBuffer() unsafe.Pointer

@method copyNextSampleBuffer @abstract Copies the next sample buffer for the output synchronously. @result A CMSampleBuffer object referencing the output sample buffer. @discussion The client is responsible for calling CFRelease on the returned CMSampleBuffer object when finished with it. This method will return NULL if there are no more sample buffers available for the receiver within the time range specified by its AVAssetReader's timeRange property, or if there is an error that prevents the AVAssetReader from reading more media data. When this method returns NULL, clients should check the value of the associated AVAssetReader's status property to determine why no more samples could be read. In certain configurations, such as when outputSettings is nil, copyNextSampleBuffer may return marker-only sample buffers as well as sample buffers containing media data. Marker-only sample buffers can be identified by CMSampleBufferGetNumSamples returning 0. Clients who do not need the information attached to marker-only sample buffers may skip them. This method throws an exception if this output is not added to an instance of AVAssetReader (using -addOutput:) and -startReading is not called on that asset reader.

func (*AVAssetReaderOutput) MarkConfigurationAsFinal ¶

func (o *AVAssetReaderOutput) MarkConfigurationAsFinal()

@method markConfigurationAsFinal @abstract Informs the receiver that no more reconfiguration of time ranges is necessary and allows the attached AVAssetReader to advance to AVAssetReaderStatusCompleted. @discussion When the value of supportsRandomAccess is YES, the attached asset reader will not advance to AVAssetReaderStatusCompleted until this method is called. When the destination of media data vended by the receiver is an AVAssetWriterInput configured for multi-pass encoding, a convenient time to invoke this method is after the asset writer input indicates that no more passes will be performed. Once this method has been called, further invocations of -resetForReadingTimeRanges: are disallowed.

func (*AVAssetReaderOutput) MediaType ¶

func (o *AVAssetReaderOutput) MediaType() *foundation.NSString

@property mediaType @abstract The media type of the samples that can be read from the receiver. @discussion The value of this property is one of the media type strings defined in AVMediaFormat.h.

func (*AVAssetReaderOutput) ResetForReadingTimeRanges ¶

func (o *AVAssetReaderOutput) ResetForReadingTimeRanges(timeRanges *foundation.NSArray[*foundation.NSValue])

@method resetForReadingTimeRanges: @abstract Starts reading over with a new set of time ranges. @param timeRanges An NSArray of NSValue objects, each representing a single CMTimeRange structure @discussion This method may only be used if supportsRandomAccess has been set to YES and may not be called after -markConfigurationAsFinal has been invoked. This method is often used in conjunction with AVAssetWriter multi-pass (see AVAssetWriterInput category AVAssetWriterInputMultiPass). In this usage, the caller will invoke -copyNextSampleBuffer until that method returns NULL and then ask the AVAssetWriterInput for a set of time ranges from which it thinks media data should be re-encoded. These time ranges are then given to this method to set up the asset reader output for the next pass. The time ranges set here override the time range set on AVAssetReader.timeRange. Just as with that property, for each time range in the array the intersection of that time range and CMTimeRangeMake(kCMTimeZero, asset.duration) will take effect. If this method is invoked after the status of the attached AVAssetReader has become AVAssetReaderStatusFailed or AVAssetReaderStatusCancelled, no change in status will occur and the result of the next call to -copyNextSampleBuffer will be NULL. This method throws an exception if the following conditions are not honored: - each item in time ranges must be an NSValue - the start of each time range must be numeric - see CMTIME_IS_NUMERIC - the duration of each time range must be nonnegative and numeric, or kCMTimePositiveInfinity - the start of each time range must be greater than or equal to the end of the previous time range - start times must be strictly increasing - time ranges must not overlap - cannot be called before -startReading has been invoked on the attached asset reader - cannot be called until all samples of media data have been read (i.e. copyNextSampleBuffer returns NULL and the asset reader has not entered a failure state) - cannot be called without setting "supportsRandomAccess" to YES - cannot be called after calling -markConfigurationAsFinal

func (*AVAssetReaderOutput) SetAlwaysCopiesSampleData ¶

func (o *AVAssetReaderOutput) SetAlwaysCopiesSampleData(alwaysCopiesSampleData bool)

@property alwaysCopiesSampleData @abstract Indicates whether or not the data in buffers gets copied before being vended to the client. @discussion When the value of this property is YES, the AVAssetReaderOutput will always vend a buffer with copied data to the client. Data in such buffers can be freely modified by the client. When the value of this property is NO, the buffers vended to the client may not be copied. Such buffers may still be referenced by other entities. The result of modifying a buffer whose data hasn't been copied is undefined. Requesting buffers whose data hasn't been copied when possible can lead to performance improvements. The default value is YES. This property throws an exception if a value is set after reading has started (the asset reader has progressed beyond AVAssetReaderStatusUnknown).

func (*AVAssetReaderOutput) SetSupportsRandomAccess ¶

func (o *AVAssetReaderOutput) SetSupportsRandomAccess(supportsRandomAccess bool)

@property supportsRandomAccess @abstract Indicates whether the asset reader output supports reconfiguration of the time ranges to read. @discussion When the value of this property is YES, the time ranges read by the asset reader output can be reconfigured during reading using the -resetForReadingTimeRanges: method. This also prevents the attached AVAssetReader from progressing to AVAssetReaderStatusCompleted until -markConfigurationAsFinal has been invoked. The default value is NO, which means that the asset reader output may not be reconfigured once reading has begun. When the value of this property is NO, AVAssetReader may be able to read media data more efficiently, particularly when multiple asset reader outputs are attached. This property throws an exception if a value is set after reading has started (the asset reader has progressed beyond AVAssetReaderStatusUnknown) or after an AVAssetReaderOutput.Provider is attached.

func (*AVAssetReaderOutput) SupportsRandomAccess ¶

func (o *AVAssetReaderOutput) SupportsRandomAccess() bool

@property supportsRandomAccess @abstract Indicates whether the asset reader output supports reconfiguration of the time ranges to read. @discussion When the value of this property is YES, the time ranges read by the asset reader output can be reconfigured during reading using the -resetForReadingTimeRanges: method. This also prevents the attached AVAssetReader from progressing to AVAssetReaderStatusCompleted until -markConfigurationAsFinal has been invoked. The default value is NO, which means that the asset reader output may not be reconfigured once reading has begun. When the value of this property is NO, AVAssetReader may be able to read media data more efficiently, particularly when multiple asset reader outputs are attached. This property throws an exception if a value is set after reading has started (the asset reader has progressed beyond AVAssetReaderStatusUnknown) or after an AVAssetReaderOutput.Provider is attached.

type AVAssetReaderOutputCaptionAdaptor ¶

type AVAssetReaderOutputCaptionAdaptor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreaderoutputcaptionadaptor

func AVAssetReaderOutputCaptionAdaptorAssetReaderOutputCaptionAdaptorWithAssetReaderTrackOutput ¶

func AVAssetReaderOutputCaptionAdaptorAssetReaderOutputCaptionAdaptorWithAssetReaderTrackOutput(trackOutput *AVAssetReaderTrackOutput) *AVAssetReaderOutputCaptionAdaptor

@method assetReaderOutputCaptionAdaptorWithAssetReaderTrackOutput: @abstract Creates a new caption adaptor for reading from the given track output. @param trackOutput The track output from which to read captions. @result A new instance of AVAssetReaderOutputCaptionAdaptor, configured to read captions from the given AVAssetReaderTrackOutput. @discussion It is an error to pass nil to this method.

func AVAssetReaderOutputCaptionAdaptorFromID ¶

func AVAssetReaderOutputCaptionAdaptorFromID(id objc.ID) *AVAssetReaderOutputCaptionAdaptor

func (*AVAssetReaderOutputCaptionAdaptor) AssetReaderTrackOutput ¶

func (o *AVAssetReaderOutputCaptionAdaptor) AssetReaderTrackOutput() *AVAssetReaderTrackOutput

@property assetReaderTrackOutput @abstract The track output used to create the receiver.

func (*AVAssetReaderOutputCaptionAdaptor) CaptionsNotPresentInPreviousGroupsInCaptionGroup ¶

func (o *AVAssetReaderOutputCaptionAdaptor) CaptionsNotPresentInPreviousGroupsInCaptionGroup(captionGroup *AVCaptionGroup) *foundation.NSArray[*AVCaption]

@method captionsNotPresentInPreviousGroupsInCaptionGroup: @abstract Returns the set of captions that are present in the given group but were not present in any group previously vended by calls to -nextCaptionGroup: on the receiver. @param captionGroup The group containing the captions of interest. @result An array of AVCaption objects. @discussion The returned array contains the set of captions in the given group whose time ranges have the same start time as the group. This method is provided as a convenience for clients who want to process captions one-by-one and do not need a complete view of the set of captions active at a given time.

func (*AVAssetReaderOutputCaptionAdaptor) InitWithAssetReaderTrackOutput ¶

func (o *AVAssetReaderOutputCaptionAdaptor) InitWithAssetReaderTrackOutput(trackOutput *AVAssetReaderTrackOutput) *AVAssetReaderOutputCaptionAdaptor

@method initWithAssetReaderTrackOutput: @abstract Creates a new caption adaptor for reading from the given track output. @param trackOutput The track output from which to read captions. @result A new instance of AVAssetReaderOutputCaptionAdaptor, configured to read captions from the given AVAssetReaderTrackOutput. @discussion It is an error to pass nil to this method.

func (*AVAssetReaderOutputCaptionAdaptor) NextCaptionGroup ¶

func (o *AVAssetReaderOutputCaptionAdaptor) NextCaptionGroup() *AVCaptionGroup

@method nextCaptionGroup @abstract Returns the next caption. @result An instance of AVCaption representing the next caption. @discussion The method returns the next caption group. This method throws an exception if the track output is not attached to an asset reader and reading has not yet begun.

func (*AVAssetReaderOutputCaptionAdaptor) SetValidationDelegate ¶

func (o *AVAssetReaderOutputCaptionAdaptor) SetValidationDelegate(validationDelegate AVAssetReaderCaptionValidationHandling)

func (*AVAssetReaderOutputCaptionAdaptor) ValidationDelegate ¶

type AVAssetReaderOutputMetadataAdaptor ¶

type AVAssetReaderOutputMetadataAdaptor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreaderoutputmetadataadaptor

func AVAssetReaderOutputMetadataAdaptorAssetReaderOutputMetadataAdaptorWithAssetReaderTrackOutput ¶

func AVAssetReaderOutputMetadataAdaptorAssetReaderOutputMetadataAdaptorWithAssetReaderTrackOutput(trackOutput *AVAssetReaderTrackOutput) *AVAssetReaderOutputMetadataAdaptor

@method assetReaderOutputMetadataAdaptorWithAssetReaderTrackOutput: @abstract Creates a new timed metadata group adaptor for retrieving timed metadata group objects from an asset reader output. @param assetReaderOutput An instance of AVAssetReaderTrackOutput that vends sample buffers containing metadata, e.g. an AVAssetReaderTrackOutput object initialized with a track of media type AVMediaTypeMetadata and nil outputSettings. @result An instance of AVAssetReaderOutputMetadataAdaptor @discussion It is an error to create a timed metadata group adaptor with an asset reader output that does not vend metadata. It is also an error to create a timed metadata group adaptor with an asset reader output whose asset reader has already started reading, or an asset reader output that already has been used to initialize another timed metadata group adaptor. Clients should not mix calls to -[AVAssetReaderTrackOutput copyNextSampleBuffer] and -[AVAssetReaderOutputMetadataAdaptor nextTimedMetadataGroup]. Once an AVAssetReaderTrackOutput instance has been used to initialize an AVAssetReaderOutputMetadataAdaptor, calling -copyNextSampleBuffer on that instance will result in an exception being thrown.

func AVAssetReaderOutputMetadataAdaptorFromID ¶

func AVAssetReaderOutputMetadataAdaptorFromID(id objc.ID) *AVAssetReaderOutputMetadataAdaptor

func (*AVAssetReaderOutputMetadataAdaptor) AssetReaderTrackOutput ¶

func (o *AVAssetReaderOutputMetadataAdaptor) AssetReaderTrackOutput() *AVAssetReaderTrackOutput

@property assetReaderTrackOutput @abstract The asset reader track output from which the receiver pulls timed metadata groups.

func (*AVAssetReaderOutputMetadataAdaptor) InitWithAssetReaderTrackOutput ¶

@method initWithAssetReaderTrackOutput: @abstract Creates a new timed metadata group adaptor for retrieving timed metadata group objects from an asset reader output. @param assetReaderOutput An instance of AVAssetReaderTrackOutput that vends sample buffers containing metadata, e.g. an AVAssetReaderTrackOutput object initialized with a track of media type AVMediaTypeMetadata and nil outputSettings. @result An instance of AVAssetReaderOutputMetadataAdaptor @discussion It is an error to create a timed metadata group adaptor with an asset reader output that does not vend metadata. It is also an error to create a timed metadata group adaptor with an asset reader output whose asset reader has already started reading, or an asset reader output that already has been used to initialize another timed metadata group adaptor. Clients should not mix calls to -[AVAssetReaderTrackOutput copyNextSampleBuffer] and -[AVAssetReaderOutputMetadataAdaptor nextTimedMetadataGroup]. Once an AVAssetReaderTrackOutput instance has been used to initialize an AVAssetReaderOutputMetadataAdaptor, calling -copyNextSampleBuffer on that instance will result in an exception being thrown. This method throws an exception if the track's output was used to initialize another adaptor or if the track output's asset reader has already started reading.

func (*AVAssetReaderOutputMetadataAdaptor) NextTimedMetadataGroup ¶

func (o *AVAssetReaderOutputMetadataAdaptor) NextTimedMetadataGroup() *AVTimedMetadataGroup

@method nextTimedMetadataGroup @abstract Returns the next timed metadata group for the asset reader output, synchronously. @result An instance of AVTimedMetadataGroup, representing the next logical segment of metadata coming from the source asset reader output. @discussion This method will return nil when all timed metadata groups have been read from the asset reader output, or if there is an error that prevents the timed metadata group adaptor from reading more timed metadata groups. When this method returns nil, clients should check the value of the associated AVAssetReader's status property to determine why no more samples could be read. Unlike -[AVAssetReaderTrackOutput copyNextSampleBuffer], this method returns an autoreleased object. Before calling this method, you must ensure that the output which underlies the receiver is attached to an AVAssetReader via a prior call to -addOutput: and that -startReading has been called on the asset reader. This method throws an exception if track output is not attached to an asset reader and reading has not yet begun.

type AVAssetReaderSampleReferenceOutput ¶

type AVAssetReaderSampleReferenceOutput struct {
	AVAssetReaderOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreadersamplereferenceoutput

func AVAssetReaderSampleReferenceOutputAssetReaderSampleReferenceOutputWithTrack ¶

func AVAssetReaderSampleReferenceOutputAssetReaderSampleReferenceOutputWithTrack(track *AVAssetTrack) *AVAssetReaderSampleReferenceOutput

@method assetReaderSampleReferenceOutputWithTrack: @abstract Returns an instance of AVAssetReaderSampleReferenceOutput for supplying sample references. @param track The AVAssetTrack for which the resulting AVAssetReaderSampleReferenceOutput should provide sample references. @result An instance of AVAssetReaderSampleReferenceOutput. @discussion The track must be one of the tracks contained by the target AVAssetReader's asset.

func AVAssetReaderSampleReferenceOutputFromID ¶

func AVAssetReaderSampleReferenceOutputFromID(id objc.ID) *AVAssetReaderSampleReferenceOutput

func (*AVAssetReaderSampleReferenceOutput) InitWithTrack ¶

@method initWithTrack: @abstract Returns an instance of AVAssetReaderSampleReferenceOutput for supplying sample references. @param track The AVAssetTrack for which the resulting AVAssetReaderSampleReferenceOutput should provide sample references. @result An instance of AVAssetReaderTrackOutput. @discussion The track must be one of the tracks contained by the target AVAssetReader's asset.

func (*AVAssetReaderSampleReferenceOutput) Track ¶

type AVAssetReaderStatus ¶

type AVAssetReaderStatus int64
const (
	AVAssetReaderStatusUnknown   AVAssetReaderStatus = 0
	AVAssetReaderStatusReading   AVAssetReaderStatus = 1
	AVAssetReaderStatusCompleted AVAssetReaderStatus = 2
	AVAssetReaderStatusFailed    AVAssetReaderStatus = 3
	AVAssetReaderStatusCancelled AVAssetReaderStatus = 4
)

func (AVAssetReaderStatus) String ¶

func (e AVAssetReaderStatus) String() string

type AVAssetReaderTrackOutput ¶

type AVAssetReaderTrackOutput struct {
	AVAssetReaderOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreadertrackoutput

func AVAssetReaderTrackOutputAssetReaderTrackOutputWithTrackOutputSettings ¶

func AVAssetReaderTrackOutputAssetReaderTrackOutputWithTrackOutputSettings(track *AVAssetTrack, outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetReaderTrackOutput

@method assetReaderTrackOutputWithTrack:outputSettings: @abstract Returns an instance of AVAssetReaderTrackOutput for reading from the specified track and supplying media data according to the specified output settings. @param track The AVAssetTrack from which the resulting AVAssetReaderTrackOutput should read sample buffers. @param outputSettings An NSDictionary of output settings to be used for sample output. See AVAudioSettings.h for available output settings for audio tracks or AVVideoSettings.h for available output settings for video tracks and also for more information about how to construct an output settings dictionary. @result An instance of AVAssetReaderTrackOutput. @discussion The track must be one of the tracks contained by the target AVAssetReader's asset. A value of nil for outputSettings configures the output to vend samples in their original format as stored by the specified track. Initialization will fail if the output settings cannot be used with the specified track. AVAssetReaderTrackOutput can only produce uncompressed output. For audio output settings, this means that AVFormatIDKey must be kAudioFormatLinearPCM. For video output settings, this means that the dictionary must follow the rules for uncompressed video output, as laid out in AVVideoSettings.h. AVAssetReaderTrackOutput does not support the AVAudioSettings.h key AVSampleRateConverterAudioQualityKey or the following AVVideoSettings.h keys: AVVideoCleanApertureKey AVVideoPixelAspectRatioKey AVVideoScalingModeKey When constructing video output settings the choice of pixel format will affect the performance and quality of the decompression. For optimal performance when decompressing video the requested pixel format should be one that the decoder supports natively to avoid unnecessary conversions. Below are some recommendations: For H.264 use kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange, or kCVPixelFormatType_420YpCbCr8BiPlanarFullRange if the video is known to be full range. For JPEG on iOS, use kCVPixelFormatType_420YpCbCr8BiPlanarFullRange. For other codecs on OSX, kCVPixelFormatType_422YpCbCr8 is the preferred pixel format for video and is generally the most performant when decoding. If you need to work in the RGB domain then kCVPixelFormatType_32BGRA is recommended. ProRes encoded media can contain up to 12bits/ch. If your source is ProRes encoded and you wish to preserve more than 8bits/ch during decompression then use one of the following pixel formats: kCVPixelFormatType_4444AYpCbCr16, kCVPixelFormatType_422YpCbCr16, kCVPixelFormatType_422YpCbCr10, or kCVPixelFormatType_64ARGB. AVAssetReader does not support scaling with any of these high bit depth pixel formats. If you use them then do not specify kCVPixelBufferWidthKey or kCVPixelBufferHeightKey in your outputSettings dictionary. If you plan to append these sample buffers to an AVAssetWriterInput then note that only the ProRes encoders support these pixel formats. ProRes 4444 encoded media can contain a mathematically lossless alpha channel. To preserve the alpha channel during decompression use a pixel format with an alpha component such as kCVPixelFormatType_4444AYpCbCr16 or kCVPixelFormatType_64ARGB. To test whether your source contains an alpha channel check that the track's format description has kCMFormatDescriptionExtension_Depth and that its value is 32.

func AVAssetReaderTrackOutputFromID ¶

func AVAssetReaderTrackOutputFromID(id objc.ID) *AVAssetReaderTrackOutput

func (*AVAssetReaderTrackOutput) AudioTimePitchAlgorithm ¶

func (o *AVAssetReaderTrackOutput) AudioTimePitchAlgorithm() *foundation.NSString

@property audioTimePitchAlgorithm @abstract Indicates the processing algorithm used to manage audio pitch for scaled audio edits. @discussion Constants for various time pitch algorithms, e.g. AVAudioTimePitchAlgorithmSpectral, are defined in AVAudioProcessingSettings.h. An NSInvalidArgumentException will be raised if this property is set to a value other than the constants defined in that file. The default value is AVAudioTimePitchAlgorithmSpectral. This property throws an exception for any of the following reasons: - a value is set value after reading has started - a value is set other than AVAudioTimePitchAlgorithmSpectral, AVAudioTimePitchAlgorithmTimeDomain, or AVAudioTimePitchAlgorithmVarispeed.

func (*AVAssetReaderTrackOutput) InitWithTrackOutputSettings ¶

func (o *AVAssetReaderTrackOutput) InitWithTrackOutputSettings(track *AVAssetTrack, outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetReaderTrackOutput

@method initWithTrack:outputSettings: @abstract Returns an instance of AVAssetReaderTrackOutput for reading from the specified track and supplying media data according to the specified output settings. @param track The AVAssetTrack from which the resulting AVAssetReaderTrackOutput should read sample buffers. @param outputSettings An NSDictionary of output settings to be used for sample output. See AVAudioSettings.h for available output settings for audio tracks or AVVideoSettings.h for available output settings for video tracks and also for more information about how to construct an output settings dictionary. @result An instance of AVAssetReaderTrackOutput. @discussion The track must be one of the tracks contained by the target AVAssetReader's asset. A value of nil for outputSettings configures the output to vend samples in their original format as stored by the specified track. Initialization will fail if the output settings cannot be used with the specified track. AVAssetReaderTrackOutput can only produce uncompressed output. For audio output settings, this means that AVFormatIDKey must be kAudioFormatLinearPCM. For video output settings, this means that the dictionary must follow the rules for uncompressed video output, as laid out in AVVideoSettings.h. AVAssetReaderTrackOutput does not support the AVAudioSettings.h key AVSampleRateConverterAudioQualityKey or the following AVVideoSettings.h keys: AVVideoCleanApertureKey AVVideoPixelAspectRatioKey AVVideoScalingModeKey When constructing video output settings the choice of pixel format will affect the performance and quality of the decompression. For optimal performance when decompressing video the requested pixel format should be one that the decoder supports natively to avoid unnecessary conversions. Below are some recommendations: For H.264 use kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange, or kCVPixelFormatType_420YpCbCr8BiPlanarFullRange if the video is known to be full range. For JPEG on iOS, use kCVPixelFormatType_420YpCbCr8BiPlanarFullRange. For other codecs on OSX, kCVPixelFormatType_422YpCbCr8 is the preferred pixel format for video and is generally the most performant when decoding. If you need to work in the RGB domain then kCVPixelFormatType_32BGRA is recommended. ProRes encoded media can contain up to 12bits/ch. If your source is ProRes encoded and you wish to preserve more than 8bits/ch during decompression then use one of the following pixel formats: kCVPixelFormatType_4444AYpCbCr16, kCVPixelFormatType_422YpCbCr16, kCVPixelFormatType_422YpCbCr10, or kCVPixelFormatType_64ARGB. AVAssetReader does not support scaling with any of these high bit depth pixel formats. If you use them then do not specify kCVPixelBufferWidthKey or kCVPixelBufferHeightKey in your outputSettings dictionary. If you plan to append these sample buffers to an AVAssetWriterInput then note that only the ProRes encoders support these pixel formats. ProRes 4444 encoded media can contain a mathematically lossless alpha channel. To preserve the alpha channel during decompression use a pixel format with an alpha component such as kCVPixelFormatType_4444AYpCbCr16 or kCVPixelFormatType_64ARGB. To test whether your source contains an alpha channel check that the track's format description has kCMFormatDescriptionExtension_Depth and that its value is 32. This method throws an exception for any of the following reasons: - the output settings dictionary contains an unsupported key mentioned above - the output settings dictionary does not contain any recognized key - output settings are not compatible with track's media type - track output settings would cause the output to yield compressed samples

func (*AVAssetReaderTrackOutput) OutputSettings ¶

@property outputSettings @abstract The output settings used by the receiver. @discussion The value of this property is an NSDictionary that contains values for keys as specified by either AVAudioSettings.h for audio tracks or AVVideoSettings.h for video tracks. A value of nil indicates that the receiver will vend samples in their original format as stored in the target track.

func (*AVAssetReaderTrackOutput) SetAudioTimePitchAlgorithm ¶

func (o *AVAssetReaderTrackOutput) SetAudioTimePitchAlgorithm(audioTimePitchAlgorithm *foundation.NSString)

func (*AVAssetReaderTrackOutput) Track ¶

@property track @abstract The track from which the receiver reads sample buffers. @discussion The value of this property is an AVAssetTrack owned by the target AVAssetReader's asset.

type AVAssetReaderVideoCompositionOutput ¶

type AVAssetReaderVideoCompositionOutput struct {
	AVAssetReaderOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetreadervideocompositionoutput

func AVAssetReaderVideoCompositionOutputAssetReaderVideoCompositionOutputWithVideoTracksVideoSettings ¶

func AVAssetReaderVideoCompositionOutputAssetReaderVideoCompositionOutputWithVideoTracksVideoSettings(videoTracks *foundation.NSArray[*AVAssetTrack], videoSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetReaderVideoCompositionOutput

@method assetReaderVideoCompositionOutputWithVideoTracks:videoSettings: @abstract Creates an instance of AVAssetReaderVideoCompositionOutput for reading composited video from the specified video tracks and supplying media data according to the specified video settings. @param tracks An NSArray of AVAssetTrack objects from which the resulting AVAssetReaderVideoCompositionOutput should read video frames for compositing. @param videoSettings An NSDictionary of video settings to be used for video output. See AVVideoSettings.h for more information about how to construct a video settings dictionary. @result An instance of AVAssetReaderVideoCompositionOutput. @discussion Each track must be one of the tracks owned by the target AVAssetReader's asset and must be of media type AVMediaTypeVideo. A value of nil for videoSettings configures the output to return samples in a convenient uncompressed format, with properties determined according to the properties of the specified video tracks. Initialization will fail if the video settings cannot be used with the specified tracks. AVAssetReaderVideoCompositionOutput can only produce uncompressed output. This means that the video settings dictionary must follow the rules for uncompressed video output, as laid out in AVVideoSettings.h. In addition, the following keys are not supported: AVVideoCleanApertureKey AVVideoPixelAspectRatioKey AVVideoScalingModeKey

func AVAssetReaderVideoCompositionOutputFromID ¶

func AVAssetReaderVideoCompositionOutputFromID(id objc.ID) *AVAssetReaderVideoCompositionOutput

func (*AVAssetReaderVideoCompositionOutput) CustomVideoCompositor ¶

func (o *AVAssetReaderVideoCompositionOutput) CustomVideoCompositor() AVVideoCompositing

@property customVideoCompositor @abstract Indicates the custom video compositor instance used by the receiver. @discussion This property is nil if there is no video compositor, or if the internal video compositor is in use.

func (*AVAssetReaderVideoCompositionOutput) InitWithVideoTracksVideoSettings ¶

@method initWithVideoTracks:videoSettings: @abstract Creates an instance of AVAssetReaderVideoCompositionOutput for reading composited video from the specified video tracks and supplying media data according to the specified video settings. @param tracks An NSArray of AVAssetTrack objects from which the resulting AVAssetReaderVideoCompositionOutput should read video frames for compositing. @param videoSettings An NSDictionary of video settings to be used for video output. See AVVideoSettings.h for more information about how to construct a video settings dictionary. @result An instance of AVAssetReaderVideoCompositionOutput. @discussion Each track must be one of the tracks owned by the target AVAssetReader's asset and must be of media type AVMediaTypeVideo. A value of nil for videoSettings configures the output to return samples in a convenient uncompressed format, with properties determined according to the properties of the specified video tracks. Initialization will fail if the video settings cannot be used with the specified tracks. AVAssetReaderVideoCompositionOutput can only produce uncompressed output. This means that the video settings dictionary must follow the rules for uncompressed video output, as laid out in AVVideoSettings.h. This method throws an exception for any of the following reasons: - any video track is not of media type AVMediaTypeVideo - any video track is not part of this asset reader output's AVAsset - track output settings would cause the output to yield compressed samples - video settings does not follow the rules for uncompressed video output (AVVideoSettings.h) - video settings contains any of the following keys: - AVVideoCleanApertureKey - AVVideoPixelAspectRatioKey - AVVideoScalingModeKey - AVVideoDecompressionPropertiesKey

func (*AVAssetReaderVideoCompositionOutput) SetVideoComposition ¶

func (o *AVAssetReaderVideoCompositionOutput) SetVideoComposition(videoComposition *AVVideoComposition)

func (*AVAssetReaderVideoCompositionOutput) VideoComposition ¶

@property videoComposition @abstract The composition of video used by the receiver. @discussion The value of this property is an AVVideoComposition that can be used to specify the visual arrangement of video frames read from each source track over the timeline of the source asset. This property throws an exception if a value is set after reading has started.

func (*AVAssetReaderVideoCompositionOutput) VideoSettings ¶

@property videoSettings @abstract The video settings used by the receiver. @discussion The value of this property is an NSDictionary that contains values for keys as specified by AVVideoSettings.h. A value of nil indicates that the receiver will return video frames in a convenient uncompressed format, with properties determined according to the properties of the receiver's video tracks.

func (*AVAssetReaderVideoCompositionOutput) VideoTracks ¶

@property videoTracks @abstract The tracks from which the receiver reads composited video. @discussion The value of this property is an NSArray of AVAssetTracks owned by the target AVAssetReader's asset.

type AVAssetReferenceRestrictions ¶

type AVAssetReferenceRestrictions uint64
const (
	// Indicates that all types of references should be followed.
	AVAssetReferenceRestrictionForbidNone AVAssetReferenceRestrictions = 0
	// Indicates that references from a remote asset (e.g. referenced via http URL) to local media data (e.g. stored in a local file) should not be followed.
	AVAssetReferenceRestrictionForbidRemoteReferenceToLocal AVAssetReferenceRestrictions = 1
	// Indicates that references from a local asset to remote media data should not be followed.
	AVAssetReferenceRestrictionForbidLocalReferenceToRemote AVAssetReferenceRestrictions = 2
	// Indicates that references from a remote asset to remote media data stored at a different site should not be followed.
	AVAssetReferenceRestrictionForbidCrossSiteReference AVAssetReferenceRestrictions = 4
	// Indicates that references from a local asset to local media data stored outside the asset's container file should not be followed.
	AVAssetReferenceRestrictionForbidLocalReferenceToLocal AVAssetReferenceRestrictions = 8
	// Indicates that only references to media data stored within the asset's container file should be allowed.
	AVAssetReferenceRestrictionForbidAll     AVAssetReferenceRestrictions = 65535
	AVAssetReferenceRestrictionDefaultPolicy AVAssetReferenceRestrictions = 2
)

func (AVAssetReferenceRestrictions) String ¶

type AVAssetResourceLoader ¶

type AVAssetResourceLoader struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetresourceloader

func AVAssetResourceLoaderFromID ¶

func AVAssetResourceLoaderFromID(id objc.ID) *AVAssetResourceLoader

func (*AVAssetResourceLoader) Delegate ¶

@property delegate @abstract The receiver's delegate. @discussion The value of this property is an object conforming to the AVAssetResourceLoaderDelegate protocol. The delegate is set using the setDelegate:queue: method. The delegate is held using a zeroing-weak reference, so this property will have a value of nil after a delegate that was previously set has been deallocated.

func (*AVAssetResourceLoader) DelegateQueue ¶

func (o *AVAssetResourceLoader) DelegateQueue() *foundation.NSObject

@property delegateQueue @abstract The dispatch queue on which all delegate methods will be invoked. @discussion The value of this property is a dispatch_queue_t. The queue is set using the setDelegate:queue: method.

func (*AVAssetResourceLoader) PreloadsEligibleContentKeys ¶

func (o *AVAssetResourceLoader) PreloadsEligibleContentKeys() bool

func (*AVAssetResourceLoader) SendsCommonMediaClientDataAsHTTPHeaders ¶

func (o *AVAssetResourceLoader) SendsCommonMediaClientDataAsHTTPHeaders() bool

func (*AVAssetResourceLoader) SetDelegateQueue ¶

func (o *AVAssetResourceLoader) SetDelegateQueue(delegate AVAssetResourceLoaderDelegate, delegateQueue *foundation.NSObject)

@method setDelegate:queue: @abstract Sets the receiver's delegate that will mediate resource loading and the dispatch queue on which delegate methods will be invoked. @param delegate An object conforming to the AVAssetResourceLoaderDelegate protocol. @param delegateQueue A dispatch queue on which all delegate methods will be invoked. @discussion If you employ an AVAssetResourceLoader delegate that loads media data for playback, you should set the value of your AVPlayer’s automaticallyWaitsToMinimizeStalling property to NO. Allowing the value of automaticallyWaitsToMinimizeStalling to remain YES — its default value — when an AVAssetResourceLoader delegate is used for the loading of media data can result in poor start-up times for playback and poor recovery from stalls, because the behaviors provided by AVPlayer when automaticallyWaitsToMinimizeStalling has a value of YES depend on predictions of the future availability of media data that that do not function as expected when data is loaded via a client-controlled means, using the AVAssetResourceLoader delegate interface. You can allow the value of automaticallyWaitsToMinimizeStalling to remain YES if you use an AVAssetResourceLoader delegate to manage content keys for FairPlay Streaming, to provide dynamically-generated master playlists for HTTP Live Streaming, or to respond to authentication challenges, but not to load media data for playback.

func (*AVAssetResourceLoader) SetPreloadsEligibleContentKeys ¶

func (o *AVAssetResourceLoader) SetPreloadsEligibleContentKeys(preloadsEligibleContentKeys bool)

func (*AVAssetResourceLoader) SetSendsCommonMediaClientDataAsHTTPHeaders ¶

func (o *AVAssetResourceLoader) SetSendsCommonMediaClientDataAsHTTPHeaders(sendsCommonMediaClientDataAsHTTPHeaders bool)

type AVAssetResourceLoaderDelegate ¶

type AVAssetResourceLoaderDelegate interface {
}

AVAssetResourceLoaderDelegate wraps the ObjC protocol AVAssetResourceLoaderDelegate.

type AVAssetResourceLoadingContentInformationRequest ¶

type AVAssetResourceLoadingContentInformationRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetresourceloadingcontentinformationrequest

func AVAssetResourceLoadingContentInformationRequestFromID ¶

func AVAssetResourceLoadingContentInformationRequestFromID(id objc.ID) *AVAssetResourceLoadingContentInformationRequest

func (*AVAssetResourceLoadingContentInformationRequest) AllowedContentTypes ¶

@property allowedContentTypes @abstract An array showing the types of data which will be accepted as a valid response for the requested resource. @discussion If an AVAssetResourceLoadingRequest's contentInformationRequest is not nil, ensure that the value assigned to the contentType property is in this array. Otherwise, calling -finishLoading on the associated request will result in an exception.

func (*AVAssetResourceLoadingContentInformationRequest) ContentLength ¶

@property contentLength @abstract Indicates the length of the requested resource, in bytes. @discussion Before you finish loading an AVAssetResourceLoadingRequest, if its contentInformationRequest is not nil, you should set the value of this property to the number of bytes contained by the requested resource.

func (*AVAssetResourceLoadingContentInformationRequest) ContentType ¶

@property contentType @abstract A UTI that indicates the type of data contained by the requested resource. @discussion Before you finish loading an AVAssetResourceLoadingRequest, if its contentInformationRequest is not nil, you should set the value of this property to a UTI indicating the type of data contained by the requested resource.

func (*AVAssetResourceLoadingContentInformationRequest) IsByteRangeAccessSupported ¶

func (o *AVAssetResourceLoadingContentInformationRequest) IsByteRangeAccessSupported() bool

@property byteRangeAccessSupported @abstract Indicates whether random access to arbitrary ranges of bytes of the resource is supported. Such support also allows portions of the resource to be requested more than once. @discussion Before you finish loading an AVAssetResourceLoadingRequest, if its contentInformationRequest is not nil, you should set the value of this property to YES if you support random access to arbitrary ranges of bytes of the resource. If you do not set this property to YES for resources that must be loaded incrementally, loading of the resource may fail. Such resources include anything that contains media data.

func (*AVAssetResourceLoadingContentInformationRequest) IsEntireLengthAvailableOnDemand ¶

func (o *AVAssetResourceLoadingContentInformationRequest) IsEntireLengthAvailableOnDemand() bool

@property entireLengthAvailableOnDemand @abstract Indicates whether asset data loading can expect data to be produced immediately. @discussion Before you finish loading an AVAssetResourceLoadingRequest, if its contentInformationRequest is not nil, you may set this property to YES to indicate that all asset data can be produced immediately, e.g., because the data is fully cached, or because the custom URL scheme ultimately refers to files on local storage. This allows significant data flow optimizations. For backward compatibility, this property defaults to NO.

func (*AVAssetResourceLoadingContentInformationRequest) RenewalDate ¶

@property renewalDate @abstract For resources that expire, the date at which a new AVAssetResourceLoadingRequest will be issued for a renewal of this resource, if the media system still requires it. @discussion Before you finish loading an AVAssetResourceLoadingRequest, if the resource is prone to expiry you should set the value of this property to the date at which a renewal should be triggered. This value should be set sufficiently early enough to allow an AVAssetResourceRenewalRequest, delivered to your delegate via -resourceLoader:shouldWaitForRenewalOfRequestedResource:, to finish before the actual expiry time. Otherwise media playback may fail.

func (*AVAssetResourceLoadingContentInformationRequest) SetByteRangeAccessSupported ¶

func (o *AVAssetResourceLoadingContentInformationRequest) SetByteRangeAccessSupported(byteRangeAccessSupported bool)

func (*AVAssetResourceLoadingContentInformationRequest) SetContentLength ¶

func (o *AVAssetResourceLoadingContentInformationRequest) SetContentLength(contentLength int64)

func (*AVAssetResourceLoadingContentInformationRequest) SetContentType ¶

func (*AVAssetResourceLoadingContentInformationRequest) SetEntireLengthAvailableOnDemand ¶

func (o *AVAssetResourceLoadingContentInformationRequest) SetEntireLengthAvailableOnDemand(entireLengthAvailableOnDemand bool)

func (*AVAssetResourceLoadingContentInformationRequest) SetRenewalDate ¶

func (o *AVAssetResourceLoadingContentInformationRequest) SetRenewalDate(renewalDate *foundation.NSDate)

type AVAssetResourceLoadingDataRequest ¶

type AVAssetResourceLoadingDataRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetresourceloadingdatarequest

func AVAssetResourceLoadingDataRequestFromID ¶

func AVAssetResourceLoadingDataRequestFromID(id objc.ID) *AVAssetResourceLoadingDataRequest

func (*AVAssetResourceLoadingDataRequest) CurrentOffset ¶

func (o *AVAssetResourceLoadingDataRequest) CurrentOffset() int64

@property currentOffset @abstract The position within the resource of the next byte within the resource following the bytes that have already been provided via prior invocations of -respondWithData.

func (*AVAssetResourceLoadingDataRequest) RequestedLength ¶

func (o *AVAssetResourceLoadingDataRequest) RequestedLength() int

@property requestedLength @abstract The length of the data requested. @discussion Note that requestsAllDataToEndOfResource will be set to YES when the entire remaining length of the resource is being requested from requestedOffset to the end of the resource. This can occur even when the content length has not yet been reported by you via a prior finished loading request. When requestsAllDataToEndOfResource has a value of YES, you should disregard the value of requestedLength and incrementally provide as much data starting from the requestedOffset as the resource contains, until you have provided all of the available data successfully and invoked -finishLoading, until you have encountered a failure and invoked -finishLoadingWithError:, or until you have received -resourceLoader:didCancelLoadingRequest: for the AVAssetResourceLoadingRequest from which the AVAssetResourceLoadingDataRequest was obtained. When requestsAllDataToEndOfResource is YES and the content length has not yet been provided by you via a prior finished loading request, the value of requestedLength is set to NSIntegerMax. Starting in macOS 10.11 and iOS 9.0, in 32-bit applications requestedLength is also set to NSIntegerMax when all of the remaining resource data is being requested and the known length of the remaining data exceeds NSIntegerMax.

func (*AVAssetResourceLoadingDataRequest) RequestedOffset ¶

func (o *AVAssetResourceLoadingDataRequest) RequestedOffset() int64

@property requestedOffset @abstract The position within the resource of the first byte requested.

func (*AVAssetResourceLoadingDataRequest) RequestsAllDataToEndOfResource ¶

func (o *AVAssetResourceLoadingDataRequest) RequestsAllDataToEndOfResource() bool

@property requestsAllDataToEndOfResource @abstract Specifies that the entire remaining length of the resource from requestedOffset to the end of the resource is being requested. @discussion When requestsAllDataToEndOfResource has a value of YES, you should disregard the value of requestedLength and incrementally provide as much data starting from the requestedOffset as the resource contains, until you have provided all of the available data successfully and invoked -finishLoading, until you have encountered a failure and invoked -finishLoadingWithError:, or until you have received -resourceLoader:didCancelLoadingRequest: for the AVAssetResourceLoadingRequest from which the AVAssetResourceLoadingDataRequest was obtained.

func (*AVAssetResourceLoadingDataRequest) RespondWithData ¶

func (o *AVAssetResourceLoadingDataRequest) RespondWithData(data *foundation.NSData)

@method respondWithData: @abstract Provides data to the receiver. @param data An instance of NSData containing some or all of the requested bytes. @discussion May be invoked multiple times on the same instance of AVAssetResourceLoadingDataRequest to provide the full range of requested data incrementally. Upon each invocation, the value of currentOffset will be updated to accord with the amount of data provided. The instance of NSData that you provide may be retained for use in parsing or other processing for an indefinite period of time after this method returns. For this reason, if you are providing an instance of NSMutableData, you should avoid mutating it further after sharing its contents. If you are managing your own memory pool for I/O and resource loading, consider using -[NSData initWithBytesNoCopy:length:deallocator:] in order to receive notification of the earliest opportunity for safe recycling of the underlying memory.

type AVAssetResourceLoadingRequest ¶

type AVAssetResourceLoadingRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetresourceloadingrequest

func AVAssetResourceLoadingRequestFromID ¶

func AVAssetResourceLoadingRequestFromID(id objc.ID) *AVAssetResourceLoadingRequest

func (*AVAssetResourceLoadingRequest) ContentInformationRequest ¶

@property contentInformationRequest @abstract An instance of AVAssetResourceLoadingContentInformationRequest that you must populate with information about the resource before responding to any AVAssetResourceLoadingDataRequests for the resource. The value of this property will be nil if no such information is being requested.

func (*AVAssetResourceLoadingRequest) DataRequest ¶

@property dataRequest @abstract An instance of AVAssetResourceLoadingDataRequest that indicates the range of resource data that's being requested. If an AVAssetResourceLoadingContentInformationRequest has been provided, you must set its properties appropriately before responding to any AVAssetResourceLoadingDataRequests. The value of this property will be nil if no data is being requested.

func (*AVAssetResourceLoadingRequest) FinishLoading ¶

func (o *AVAssetResourceLoadingRequest) FinishLoading()

@method finishLoading @abstract Causes the receiver to treat the processing of the request as complete. @discussion If a dataRequest is present, and the resource does not contain the full extent of the data that has been requested according to the values of the requestedOffset and requestedLength properties of the dataRequest, or if requestsAllDataToEndOfResource has a value of YES, -finishLoading may be invoked after providing as much of the requested data as the resource contains. If the contentInformationRequest property is not nil and specifies a non-empty allowedContentTypes array, the contentInformationRequest's contentType property must be set to a value within allowedContentTypes. Otherwise, this method will throw an exception.

func (*AVAssetResourceLoadingRequest) FinishLoadingWithError ¶

func (o *AVAssetResourceLoadingRequest) FinishLoadingWithError(error_ unsafe.Pointer)

@method finishLoadingWithError: @abstract Causes the receiver to treat the request as having failed. @param error An instance of NSError indicating the reason for failure.

func (*AVAssetResourceLoadingRequest) FinishLoadingWithResponseDataRedirect ¶

func (o *AVAssetResourceLoadingRequest) FinishLoadingWithResponseDataRedirect(response *foundation.NSURLResponse, data *foundation.NSData, redirect *foundation.NSURLRequest)

@method finishLoadingWithResponse:data:redirect: @abstract Causes the receiver to finish loading a resource that a delegate has previously assumed responsibility for loading by returning YES as the result of -resourceLoader:shouldWaitForLoadingOfRequestedResource:. @param response The NSURLResponse for the NSURLRequest of the receiver. Should be nil if no response is required. @param data An instance of NSData containing the data of the resource. Should be nil if no such data is available. @param redirect An instance of NSURLRequest indicating a redirect of the loading request. Should be nil if no redirect is needed. @discussion This method is deprecated. Use the following methods instead. -[AVAssetResourceLoadingRequest setResponse:] to set the response property, -[AVAssetResourceLoadingRequest setRedirect:] to set the redirect property, -[AVAssetResourceLoadingDataRequest respondWithData:] to provide data, and -[AVAssetResourceLoadingRequest finishLoading] to indicate that loading is finished. Deprecated: Use -[AVAssetResourceLoadingRequest setResponse:], -[AVAssetResourceLoadingRequest setRedirect:], -[AVAssetResourceLoadingDataRequest respondWithData:], -[AVAssetResourceLoadingRequest finishLoading]

func (*AVAssetResourceLoadingRequest) IsCancelled ¶

func (o *AVAssetResourceLoadingRequest) IsCancelled() bool

@property cancelled @abstract Indicates whether the request has been cancelled. @discussion The value of this property becomes YES when the resource loader cancels the loading of a request, just prior to sending the message -resourceLoader:didCancelLoadingRequest: to its delegate.

func (*AVAssetResourceLoadingRequest) IsFinished ¶

func (o *AVAssetResourceLoadingRequest) IsFinished() bool

@property finished @abstract Indicates whether loading of the resource has been finished. @discussion The value of this property becomes YES only in response to an invocation of either -finishLoading or -finishLoadingWithError:.

func (*AVAssetResourceLoadingRequest) PersistentContentKeyFromKeyVendorResponseOptionsError ¶

func (o *AVAssetResourceLoadingRequest) PersistentContentKeyFromKeyVendorResponseOptionsError(keyVendorResponse *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*foundation.NSData, error)

@method persistentContentKeyFromKeyVendorResponse:options:error: @abstract Obtains a persistable content key from a context. @param keyVendorResponse The response returned from the key vendor as a result of a request generated from streamingContentKeyRequestDataForApp:contentIdentifier:options:error:. @param options Additional information necessary to obtain the persistable content key, or nil if none. @param outError If obtaining the persistable content key fails, will be set to an instance of NSError describing the failure. @result The persistable content key data that may be stored offline to answer future loading requests of the same content key. @discussion The data returned from this method may be used to immediately satisfy an AVAssetResourceLoadingDataRequest, as well as any subsequent requests for the same key url. The value of AVAssetResourceLoadingContentInformationRequest.contentType must be set to AVStreamingKeyDeliveryPersistentContentKeyType when responding with data created with this method. Deprecated: Use -[AVPersistableContentKeyRequest persistableContentKeyFromKeyVendorResponse:options:error:] instead

func (*AVAssetResourceLoadingRequest) Redirect ¶

@property redirect @abstract Set the value of this property to an instance of NSURLRequest indicating a redirection of the loading request to another URL. If no redirection is needed, leave the value of this property set to nil. @discussion AVAssetResourceLoader supports redirects to HTTP URLs only. Redirects to other URLs will result in a loading failure.

func (*AVAssetResourceLoadingRequest) Request ¶

@property request @abstract An NSURLRequest for the requested resource.

func (*AVAssetResourceLoadingRequest) Requestor ¶

@property requestor @abstract The AVAssetResourceLoadingRequestor that made this request

func (*AVAssetResourceLoadingRequest) Response ¶

@property response @abstract Set the value of this property to an instance of NSURLResponse indicating a response to the loading request. If no response is needed, leave the value of this property set to nil.

func (*AVAssetResourceLoadingRequest) SetRedirect ¶

func (o *AVAssetResourceLoadingRequest) SetRedirect(redirect *foundation.NSURLRequest)

func (*AVAssetResourceLoadingRequest) SetResponse ¶

func (o *AVAssetResourceLoadingRequest) SetResponse(response *foundation.NSURLResponse)

func (*AVAssetResourceLoadingRequest) StreamingContentKeyRequestDataForAppContentIdentifierOptionsError ¶

func (o *AVAssetResourceLoadingRequest) StreamingContentKeyRequestDataForAppContentIdentifierOptionsError(appIdentifier *foundation.NSData, contentIdentifier *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*foundation.NSData, error)

@method streamingContentKeyRequestDataForApp:contentIdentifier:options:error: @abstract Obtains a streaming content key request for a specific combination of application and content. @param appIdentifier An opaque identifier for the application. The value of this identifier depends on the particular system used to provide the decryption key. @param contentIdentifier An opaque identifier for the content. The value of this identifier depends on the particular system used to provide the decryption key. @param options Additional information necessary to obtain the key, or nil if none. @param outError If obtaining the streaming content key request fails, will be set to an instance of NSError describing the failure. @result The key request data that must be transmitted to the key vendor to obtain the content key. Deprecated: Use -[AVContentKeyRequest makeStreamingContentKeyRequestDataForApp:contentIdentifier:options:completionHandler:] instead

type AVAssetResourceLoadingRequestor ¶

type AVAssetResourceLoadingRequestor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetresourceloadingrequestor

func AVAssetResourceLoadingRequestorFromID ¶

func AVAssetResourceLoadingRequestorFromID(id objc.ID) *AVAssetResourceLoadingRequestor

func (*AVAssetResourceLoadingRequestor) ProvidesExpiredSessionReports ¶

func (o *AVAssetResourceLoadingRequestor) ProvidesExpiredSessionReports() bool

type AVAssetSegmentReport ¶

type AVAssetSegmentReport struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetsegmentreport

func AVAssetSegmentReportFromID ¶

func AVAssetSegmentReportFromID(id objc.ID) *AVAssetSegmentReport

func (*AVAssetSegmentReport) SegmentType ¶

func (o *AVAssetSegmentReport) SegmentType() AVAssetSegmentType

@property segmentType @abstract A segment type of the segment data.

func (*AVAssetSegmentReport) TrackReports ¶

@property trackReports @abstract Provides an array of AVAssetSegmentTrackReport in the segment data.

type AVAssetSegmentReportSampleInformation ¶

type AVAssetSegmentReportSampleInformation struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetsegmentreportsampleinformation

func AVAssetSegmentReportSampleInformationFromID ¶

func AVAssetSegmentReportSampleInformationFromID(id objc.ID) *AVAssetSegmentReportSampleInformation

func (*AVAssetSegmentReportSampleInformation) IsSyncSample ¶

func (o *AVAssetSegmentReportSampleInformation) IsSyncSample() bool

@property isSyncSample @abstract Indicates whether the sample is a sync sample.

func (*AVAssetSegmentReportSampleInformation) Length ¶

@property length @abstract The length of the sample.

func (*AVAssetSegmentReportSampleInformation) Offset ¶

@property offset @abstract The offset of the sample in the segment.

func (*AVAssetSegmentReportSampleInformation) PresentationTimeStamp ¶

func (o *AVAssetSegmentReportSampleInformation) PresentationTimeStamp() coremedia.CMTime

@property presentationTimeStamp @abstract The presentation timestamp (PTS) of the sample. @discussion This timestamp may be different from the earliestPresentationTimeStamp if the video is encoded using frame reordering.

type AVAssetSegmentTrackReport ¶

type AVAssetSegmentTrackReport struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetsegmenttrackreport

func AVAssetSegmentTrackReportFromID ¶

func AVAssetSegmentTrackReportFromID(id objc.ID) *AVAssetSegmentTrackReport

func (*AVAssetSegmentTrackReport) Duration ¶

@property duration @abstract Indicates the duration for this track. The value is kCMTimeInvalid if there is no information available.

func (*AVAssetSegmentTrackReport) EarliestPresentationTimeStamp ¶

func (o *AVAssetSegmentTrackReport) EarliestPresentationTimeStamp() coremedia.CMTime

@property earliestPresentationTimeStamp @abstract Indicates the earliest presentation timestamp (PTS) for this track. The value is kCMTimeInvalid if there is no information available.

func (*AVAssetSegmentTrackReport) FirstVideoSampleInformation ¶

func (o *AVAssetSegmentTrackReport) FirstVideoSampleInformation() *AVAssetSegmentReportSampleInformation

@property firstVideoSampleInformation @abstract Provides information on the first video sample in this track. The value is nil if this track is not video track or no information available.

func (*AVAssetSegmentTrackReport) MediaType ¶

@property mediaType @abstract Indicates the media type for this track. Media types are declared in AVMediaFormat.h.

func (*AVAssetSegmentTrackReport) TrackID ¶

func (o *AVAssetSegmentTrackReport) TrackID() int32

@property trackID @abstract Indicates the persistent unique identifier for this track.

type AVAssetSegmentType ¶

type AVAssetSegmentType int64
const (
	AVAssetSegmentTypeInitialization AVAssetSegmentType = 1
	AVAssetSegmentTypeSeparable      AVAssetSegmentType = 2
)

func (AVAssetSegmentType) String ¶

func (e AVAssetSegmentType) String() string

type AVAssetTrack ¶

type AVAssetTrack struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassettrack

func AVAssetTrackFromID ¶

func AVAssetTrackFromID(id objc.ID) *AVAssetTrack

func (*AVAssetTrack) Asset ¶

func (o *AVAssetTrack) Asset() *AVAsset

Provides a reference to the AVAsset of which the AVAssetTrack is a part

func (*AVAssetTrack) AssociatedTracksOfType ¶

func (o *AVAssetTrack) AssociatedTracksOfType(trackAssociationType *foundation.NSString) *foundation.NSArray[*AVAssetTrack]

Provides an NSArray of AVAssetTracks, one for each track associated with the receiver with the specified type of track association. Becomes callable without blocking when the key @"availableTrackAssociationTypes" has been loaded. - Parameter trackAssociationType: The type of track association for which associated tracks are requested. - Returns: An NSArray containing AVAssetTracks; may be empty if there is no associated tracks of the specified type. Deprecated: Use loadAssociatedTracksOfType:completionHandler: instead

func (*AVAssetTrack) AvailableMetadataFormats ¶

func (o *AVAssetTrack) AvailableMetadataFormats() *foundation.NSArray[*foundation.NSString]

Provides an NSArray of NSStrings, each representing a format of metadata that's available for the track (e.g. QuickTime userdata, etc.) Metadata formats are defined in AVMetadataItem.h.

func (*AVAssetTrack) AvailableTrackAssociationTypes ¶

func (o *AVAssetTrack) AvailableTrackAssociationTypes() *foundation.NSArray[*foundation.NSString]

Provides an NSArray of NSStrings, each representing a type of track association that the receiver has with one or more of the other tracks of the asset (e.g. AVTrackAssociationTypeChapterList, AVTrackAssociationTypeTimecode, etc.). Track association types are defined immediately above.

func (*AVAssetTrack) CanProvideSampleCursors ¶

func (o *AVAssetTrack) CanProvideSampleCursors() bool

Indicates whether the receiver can provide instances of AVSampleCursor for traversing its media samples and discovering information about them.

func (*AVAssetTrack) CommonMetadata ¶

func (o *AVAssetTrack) CommonMetadata() *foundation.NSArray[*AVMetadataItem]

Provides access to an array of AVMetadataItems for each common metadata key for which a value is available

func (*AVAssetTrack) EstimatedDataRate ¶

func (o *AVAssetTrack) EstimatedDataRate() float32

Indicates the estimated data rate of the media data referenced by the track, in units of bits per second

func (*AVAssetTrack) ExtendedLanguageTag ¶

func (o *AVAssetTrack) ExtendedLanguageTag() *foundation.NSString

Indicates the language tag associated with the track, as an IETF BCP 47 (RFC 4646) language identifier; may be nil if no language tag is indicated

func (*AVAssetTrack) FormatDescriptions ¶

func (o *AVAssetTrack) FormatDescriptions() *foundation.NSArray[objc.ID]

Provides an array of CMFormatDescriptions each of which indicates the format of media samples referenced by the track; a track that presents uniform media, e.g. encoded according to the same encoding settings, will provide an array with a count of 1.

func (*AVAssetTrack) HasAudioSampleDependencies ¶

func (o *AVAssetTrack) HasAudioSampleDependencies() bool

Indicates whether this audio track has dependencies (e.g. kAudioFormatMPEGD_USAC)

func (*AVAssetTrack) HasMediaCharacteristic ¶

func (o *AVAssetTrack) HasMediaCharacteristic(mediaCharacteristic *foundation.NSString) bool

Reports whether the track references media with the specified media characteristic. - Parameter mediaCharacteristic: The media characteristic of interest, e.g. AVMediaCharacteristicVisual, AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, etc., as defined above. - Returns: YES if the track references media with the specified characteristic, otherwise NO.

func (*AVAssetTrack) IsDecodable ¶

func (o *AVAssetTrack) IsDecodable() bool

Indicates whether the receiver is decodable in the current environment; if YES, the track can be decoded even though decoding may be too slow for real time playback.

func (*AVAssetTrack) IsEnabled ¶

func (o *AVAssetTrack) IsEnabled() bool

Indicates whether the track is enabled according to state stored in its container or construct; note that its presentation state can be changed from this default via AVPlayerItemTrack

func (*AVAssetTrack) IsPlayable ¶

func (o *AVAssetTrack) IsPlayable() bool

Indicates whether the receiver is playable in the current environment; if YES, an AVPlayerItemTrack of an AVPlayerItem initialized with the receiver's asset can be enabled for playback.

func (*AVAssetTrack) IsSelfContained ¶

func (o *AVAssetTrack) IsSelfContained() bool

Indicates whether the track references sample data only within its storage container

func (*AVAssetTrack) LanguageCode ¶

func (o *AVAssetTrack) LanguageCode() *foundation.NSString

Indicates the language associated with the track, as an ISO 639-2/T language code; may be nil if no language is indicated

func (*AVAssetTrack) LoadAssociatedTracksOfTypeCompletionHandler ¶

func (o *AVAssetTrack) LoadAssociatedTracksOfTypeCompletionHandler(trackAssociationType *foundation.NSString, completionHandler func(*foundation.NSArray[*AVAssetTrack], unsafe.Pointer))

Provides an NSArray of AVAssetTracks, one for each track associated with the receiver with the specified type of track association. - Parameter trackAssociationType: The type of track association for which associated tracks are requested. - Parameter completionHandler: A block that is invoked when loading is comlete, vending an array of tracks (which may be empty if there is no associated tracks of the specified type) or an error. `

func (*AVAssetTrack) LoadMetadataForFormatCompletionHandler ¶

func (o *AVAssetTrack) LoadMetadataForFormatCompletionHandler(format *foundation.NSString, completionHandler func(*foundation.NSArray[*AVMetadataItem], unsafe.Pointer))

Loads an NSArray of AVMetadataItems, one for each metadata item in the container of the specified format. - Parameter format: The metadata format for which items are requested. - Parameter completionHandler: A block that is invoked when loading is complete, vending the array of metadata items (which may be empty if there is no metadata of the specified format) or an error.

func (*AVAssetTrack) LoadSamplePresentationTimeForTrackTimeCompletionHandler ¶

func (o *AVAssetTrack) LoadSamplePresentationTimeForTrackTimeCompletionHandler(trackTime coremedia.CMTime, completionHandler objc.Block)

Maps the specified trackTime through the appropriate time mapping and loads the resulting sample presentation time. - Parameter trackTime: The trackTime for which a sample presentation time is requested. - Parameter completionHandler: A block that is invoked when loading is complete, vending a CMTime (which will be invalid if the trackTime is out of range) or an error.

func (*AVAssetTrack) LoadSegmentForTrackTimeCompletionHandler ¶

func (o *AVAssetTrack) LoadSegmentForTrackTimeCompletionHandler(trackTime coremedia.CMTime, completionHandler func(unsafe.Pointer, unsafe.Pointer))

Loads the AVAssetTrackSegment from the segments array with a target timeRange that either contains the specified track time or is the closest to it among the target timeRanges of the track's segments. If the trackTime does not map to a sample presentation time (e.g. it's outside the track's timeRange), the segment closest in time to the specified trackTime is returned. - Parameter trackTime: The trackTime for which an AVAssetTrackSegment is requested. - Parameter completionHandler: A block that is invoked when loading is complete, vending an AVAssetTrackSegment or an error.

func (*AVAssetTrack) MakeSampleCursorAtFirstSampleInDecodeOrder ¶

func (o *AVAssetTrack) MakeSampleCursorAtFirstSampleInDecodeOrder() *AVSampleCursor

Creates an instance of AVSampleCursor and positions it at the receiver's first media sample in decode order. This method will return nil if there are no samples in the track. - Returns: An instance of AVSampleCursor.

func (*AVAssetTrack) MakeSampleCursorAtLastSampleInDecodeOrder ¶

func (o *AVAssetTrack) MakeSampleCursorAtLastSampleInDecodeOrder() *AVSampleCursor

Creates an instance of AVSampleCursor and positions it at the receiver's last media sample in decode order. This method will return nil if there are no samples in the track. - Returns: An instance of AVSampleCursor.

func (*AVAssetTrack) MakeSampleCursorWithPresentationTimeStamp ¶

func (o *AVAssetTrack) MakeSampleCursorWithPresentationTimeStamp(presentationTimeStamp coremedia.CMTime) *AVSampleCursor

Creates an instance of AVSampleCursor and positions it at or near the specified presentation timestamp. If the receiver's asset has a value of YES for providesPreciseDurationAndTiming, the sample cursor will be accurately positioned at the receiver's last media sample with presentation timestamp less than or equal to the desired timestamp, or, if there are no such samples, the first sample in presentation order. If the receiver's asset has a value of NO for providesPreciseDurationAndTiming, and it is prohibitively expensive to locate the precise sample at the desired timestamp, the sample cursor may be approximately positioned. This method will return nil if there are no samples in the track. - Parameter presentationTimeStamp: The desired initial presentation timestamp of the returned AVSampleCursor. - Returns: An instance of AVSampleCursor.

func (*AVAssetTrack) MediaType ¶

func (o *AVAssetTrack) MediaType() *foundation.NSString

Indicates the media type for this track, e.g. AVMediaTypeVideo, AVMediaTypeAudio, etc., as defined in AVMediaFormat.h.

func (*AVAssetTrack) Metadata ¶

func (o *AVAssetTrack) Metadata() *foundation.NSArray[*AVMetadataItem]

Provides access to an array of AVMetadataItems for all metadata identifiers for which a value is available; items can be filtered according to language via +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:] and according to identifier via +[AVMetadataItem metadataItemsFromArray:filteredByIdentifier:].

func (*AVAssetTrack) MetadataForFormat ¶

func (o *AVAssetTrack) MetadataForFormat(format *foundation.NSString) *foundation.NSArray[*AVMetadataItem]

Provides an NSArray of AVMetadataItems, one for each metadata item in the container of the specified format. Becomes callable without blocking when the key @"availableMetadataFormats" has been loaded - Parameter format: The metadata format for which items are requested. - Returns: An NSArray containing AVMetadataItems. Deprecated: Use loadMetadataForFormat:completionHandler: instead

func (*AVAssetTrack) MinFrameDuration ¶

func (o *AVAssetTrack) MinFrameDuration() coremedia.CMTime

Indicates the minimum duration of the track's frames; the value will be kCMTimeInvalid if the minimum frame duration is not known or cannot be calculated

func (*AVAssetTrack) NaturalSize ¶

func (o *AVAssetTrack) NaturalSize() corefoundation.CGSize

Indicates the natural dimensions of the media data referenced by the track as a CGSize

func (*AVAssetTrack) NaturalTimeScale ¶

func (o *AVAssetTrack) NaturalTimeScale() int32

Indicates a timescale in which time values for the track can be operated upon without extraneous numerical conversion

func (*AVAssetTrack) NominalFrameRate ¶

func (o *AVAssetTrack) NominalFrameRate() float32

For tracks that carry a full frame per media sample, indicates the frame rate of the track in units of frames per second. For field-based video tracks that carry one field per media sample, the value of this property is the field rate, not the frame rate.

func (*AVAssetTrack) PreferredTransform ¶

func (o *AVAssetTrack) PreferredTransform() corefoundation.CGAffineTransform

Indicates the transform specified in the track's storage container as the preferred transformation of the visual media data for display purposes; its value is often but not always CGAffineTransformIdentity

func (*AVAssetTrack) PreferredVolume ¶

func (o *AVAssetTrack) PreferredVolume() float32

Indicates the volume specified in the track's storage container as the preferred volume of the audible media data

func (*AVAssetTrack) RequiresFrameReordering ¶

func (o *AVAssetTrack) RequiresFrameReordering() bool

Indicates whether samples in the track may have different values for their presentation and decode timestamps.

func (*AVAssetTrack) SamplePresentationTimeForTrackTime ¶

func (o *AVAssetTrack) SamplePresentationTimeForTrackTime(trackTime coremedia.CMTime) coremedia.CMTime

Maps the specified trackTime through the appropriate time mapping and returns the resulting sample presentation time. - Parameter trackTime: The trackTime for which a sample presentation time is requested. - Returns: A CMTime; will be invalid if the trackTime is out of range Deprecated: Use loadSamplePresentationTimeForTrackTime:completionHandler: instead

func (*AVAssetTrack) SegmentForTrackTime ¶

func (o *AVAssetTrack) SegmentForTrackTime(trackTime coremedia.CMTime) *AVAssetTrackSegment

Supplies the AVAssetTrackSegment from the segments array with a target timeRange that either contains the specified track time or is the closest to it among the target timeRanges of the track's segments. If the trackTime does not map to a sample presentation time (e.g. it's outside the track's timeRange), the segment closest in time to the specified trackTime is returned. - Parameter trackTime: The trackTime for which an AVAssetTrackSegment is requested. - Returns: An AVAssetTrackSegment. Deprecated: Use loadSegmentForTrackTime:completionHandler: instead

func (*AVAssetTrack) Segments ¶

Provides an array of AVAssetTrackSegments with time mappings from the timeline of the track's media samples to the timeline of the track. Empty edits, i.e. timeRanges for which no media data is available to be presented, have a value of AVAssetTrackSegment.empty equal to YES.

func (*AVAssetTrack) TimeRange ¶

func (o *AVAssetTrack) TimeRange() coremedia.CMTimeRange

Indicates the timeRange of the track within the overall timeline of the asset; a track with CMTIME_COMPARE_INLINE(timeRange.start, >, kCMTimeZero) will initially present an empty interval.

func (*AVAssetTrack) TotalSampleDataLength ¶

func (o *AVAssetTrack) TotalSampleDataLength() int64

Indicates the total number of bytes of sample data required by the track

func (*AVAssetTrack) TrackID ¶

func (o *AVAssetTrack) TrackID() int32

Indicates the persistent unique identifier for this track of the asset

type AVAssetTrackGroup ¶

type AVAssetTrackGroup struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassettrackgroup

func AVAssetTrackGroupFromID ¶

func AVAssetTrackGroupFromID(id objc.ID) *AVAssetTrackGroup

func (*AVAssetTrackGroup) TrackIDs ¶

type AVAssetTrackGroupOutputHandling ¶

type AVAssetTrackGroupOutputHandling uint64
const (
	AVAssetTrackGroupOutputHandlingNone                    AVAssetTrackGroupOutputHandling = 0
	AVAssetTrackGroupOutputHandlingPreserveAlternateTracks AVAssetTrackGroupOutputHandling = 1
	AVAssetTrackGroupOutputHandlingDefaultPolicy           AVAssetTrackGroupOutputHandling = 0
)

func (AVAssetTrackGroupOutputHandling) String ¶

type AVAssetTrackSegment ¶

type AVAssetTrackSegment struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassettracksegment

func AVAssetTrackSegmentFromID ¶

func AVAssetTrackSegmentFromID(id objc.ID) *AVAssetTrackSegment

func (*AVAssetTrackSegment) IsEmpty ¶

func (o *AVAssetTrackSegment) IsEmpty() bool

func (*AVAssetTrackSegment) TimeMapping ¶

func (o *AVAssetTrackSegment) TimeMapping() coremedia.CMTimeMapping

type AVAssetVariant ¶

type AVAssetVariant struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetvariant

func AVAssetVariantFromID ¶

func AVAssetVariantFromID(id objc.ID) *AVAssetVariant

func (*AVAssetVariant) AudioAttributes ¶

func (o *AVAssetVariant) AudioAttributes() *AVAssetVariantAudioAttributes

Provides variant's audio rendition attributes. If no audio attributes are declared, it will be nil.

func (*AVAssetVariant) AverageBitRate ¶

func (o *AVAssetVariant) AverageBitRate() float64

If it is not declared, the value will be negative.

func (*AVAssetVariant) PeakBitRate ¶

func (o *AVAssetVariant) PeakBitRate() float64

If it is not declared, the value will be negative.

func (*AVAssetVariant) URL ¶

func (o *AVAssetVariant) URL() *foundation.NSURL

Provides URL to media playlist corresponding to variant

func (*AVAssetVariant) VideoAttributes ¶

func (o *AVAssetVariant) VideoAttributes() *AVAssetVariantVideoAttributes

Provides variant's video rendition attributes. If no video attributes are declared, it will be nil.

type AVAssetVariantAudioAttributes ¶

type AVAssetVariantAudioAttributes struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetvariantaudioattributes

func AVAssetVariantAudioAttributesFromID ¶

func AVAssetVariantAudioAttributesFromID(id objc.ID) *AVAssetVariantAudioAttributes

func (*AVAssetVariantAudioAttributes) FormatIDs ¶

Provides an array of audio formats present in the variant's renditions if any are declared. Each value in the array is a NSNumber representation of AudioFormatID.

func (*AVAssetVariantAudioAttributes) RenditionSpecificAttributesForMediaOption ¶

func (o *AVAssetVariantAudioAttributes) RenditionSpecificAttributesForMediaOption(mediaSelectionOption *AVMediaSelectionOption) *AVAssetVariantAudioRenditionSpecificAttributes

Provides attributes for a specific audio media selection option. If no rendition specific attributes are declared, it will be nil. - Parameter mediaSelectionOption: The option to return rendition specific information for.

type AVAssetVariantAudioRenditionSpecificAttributes ¶

type AVAssetVariantAudioRenditionSpecificAttributes struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetvariantaudiorenditionspecificattributes

func AVAssetVariantAudioRenditionSpecificAttributesFromID ¶

func AVAssetVariantAudioRenditionSpecificAttributesFromID(id objc.ID) *AVAssetVariantAudioRenditionSpecificAttributes

func (*AVAssetVariantAudioRenditionSpecificAttributes) ChannelCount ¶

If it is not declared, the value will be negative. A channel count greater than two indicates that the variant offers a rich multichannel authoring.

func (*AVAssetVariantAudioRenditionSpecificAttributes) IsBinaural ¶

Indicates that the variant is best suited for delivery to headphones. A binaural variant may originate from a direct binaural recording or from the processing of a multichannel audio source.

func (*AVAssetVariantAudioRenditionSpecificAttributes) IsDownmix ¶

Indicates that this variant is declared as a downmix derivative of other media of greater channel count. If one or more multichannel variants are also provided, the dowmix is assumed to be compatible in its internal timing and other attributes with those variants. Typically this is because it has been derived from the same source. A downmix can be used as a suitable substitute for a multichannel variant under some conditions.

func (*AVAssetVariantAudioRenditionSpecificAttributes) IsImmersive ¶

Indicates that this variant contains virtualized or otherwise pre-processed audio content that is suitable for a variety of purposes. If a variant audio redition is immersive it is eligible for rendering either to headphones or speakers.

type AVAssetVariantQualifier ¶

type AVAssetVariantQualifier struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetvariantqualifier

func AVAssetVariantQualifierAssetVariantQualifierWithPredicate ¶

func AVAssetVariantQualifierAssetVariantQualifierWithPredicate(predicate *foundation.NSPredicate) *AVAssetVariantQualifier

Returns a qualifer for a predicate. - Parameter predicate: The variant predicate. Must be a valid, non-nil NSPredicate.

func AVAssetVariantQualifierAssetVariantQualifierWithVariant ¶

func AVAssetVariantQualifierAssetVariantQualifierWithVariant(variant *AVAssetVariant) *AVAssetVariantQualifier

Returns a qualifer for a particular asset variant. - Parameter variant: A variant obtained from the -[AVAsset variants] or -[AVAssetDownloadConfiguration playableVariants]. Must be a valid, non-nil AVAssetVariant.

func AVAssetVariantQualifierFromID ¶

func AVAssetVariantQualifierFromID(id objc.ID) *AVAssetVariantQualifier

type AVAssetVariantVideoAttributes ¶

type AVAssetVariantVideoAttributes struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetvariantvideoattributes

func AVAssetVariantVideoAttributesFromID ¶

func AVAssetVariantVideoAttributesFromID(id objc.ID) *AVAssetVariantVideoAttributes

func (*AVAssetVariantVideoAttributes) CodecTypes ¶

Provides an array of video sample codec types present in the variant's renditions if any are declared. Each value in the array is a NSNumber representation of CMVideoCodecType.

func (*AVAssetVariantVideoAttributes) NominalFrameRate ¶

func (o *AVAssetVariantVideoAttributes) NominalFrameRate() float64

If it is not declared, the value will be negative.

func (*AVAssetVariantVideoAttributes) PresentationSize ¶

func (o *AVAssetVariantVideoAttributes) PresentationSize() corefoundation.CGSize

If it is not declared, it will be CGSizeZero.

func (*AVAssetVariantVideoAttributes) VideoLayoutAttributes ¶

Describes the video layout attributes. videoLayoutAttributes' count may be greater than one if this variant contains a collection of differing video layout media attributes over time.

func (*AVAssetVariantVideoAttributes) VideoRange ¶

Provides the video range of the variant. If it is not declared, it will be AVVideoRangeSDR.

type AVAssetVariantVideoLayoutAttributes ¶

type AVAssetVariantVideoLayoutAttributes struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetvariantvideolayoutattributes

func AVAssetVariantVideoLayoutAttributesFromID ¶

func AVAssetVariantVideoLayoutAttributesFromID(id objc.ID) *AVAssetVariantVideoLayoutAttributes

func (*AVAssetVariantVideoLayoutAttributes) ProjectionType ¶

Describes the video projection.

func (*AVAssetVariantVideoLayoutAttributes) StereoViewComponents ¶

Describes the stereo components. If not declared, the value will be `kCMStereoViewComponent_None`. In case of monoscopic content, the value will be `kCMStereoViewComponent_None` and incase of stereoscopic content, the value will be `(kCMStereoViewComponent_LeftEye | kCMStereoViewComponent_RightEye)`.

type AVAssetWriter ¶

type AVAssetWriter struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriter

func AVAssetWriterAssetWriterWithURLFileTypeError ¶

func AVAssetWriterAssetWriterWithURLFileTypeError(outputURL *foundation.NSURL, outputFileType *foundation.NSString) (*AVAssetWriter, error)

@method assetWriterWithURL:fileType:error: @abstract Returns an instance of AVAssetWriter configured to write to a file in a specified container format. @param URL The location of the file to be written. The URL must be a file URL. @param fileType A UTI indicating the format of the file to be written. @param outError On return, if initialization of the AVAssetWriter fails, points to an NSError describing the nature of the failure. @result An instance of AVAssetWriter. @discussion Writing will fail if a file already exists at the specified URL. UTIs for container formats that can be written are declared in AVMediaFormat.h.

func AVAssetWriterFromID ¶

func AVAssetWriterFromID(id objc.ID) *AVAssetWriter

func (*AVAssetWriter) AddInput ¶

func (o *AVAssetWriter) AddInput(input *AVAssetWriterInput)

@method addInput: @abstract Adds an input to the receiver. @param input The AVAssetWriterInput object to be added. @discussion Inputs are created with a media type and output settings. These both must be compatible with the receiver. Inputs cannot be added after writing has started. This method throws an exception if any of the following conditions are satisfied: - the input's media type is not allowed for this asset writer - writing uncompressed video in a specific format - passthrough* to files (other than AVFileTypeQuickTimeMovie) is missing a format hint in the AVAssetWriterInput initializer - passthrough* is not supported for this media/file type combination (for example, AVFileTypeWAVE only supports AVMediaTypeAudio) Passthrough is indicated when the input's output settings are nil.

func (*AVAssetWriter) AddInputGroup ¶

func (o *AVAssetWriter) AddInputGroup(inputGroup *AVAssetWriterInputGroup)

func (*AVAssetWriter) AvailableMediaTypes ¶

func (o *AVAssetWriter) AvailableMediaTypes() *foundation.NSArray[*foundation.NSString]

@property availableMediaTypes @abstract The media types for which inputs can be added to the receiver. @discussion Some media types may not be accepted within the file format with which an AVAssetWriter was initialized.

func (*AVAssetWriter) CanAddInput ¶

func (o *AVAssetWriter) CanAddInput(input *AVAssetWriterInput) bool

@method canAddInput: @abstract Tests whether an input can be added to the receiver. @param input The AVAssetWriterInput object to be tested. @result A BOOL indicating whether the input can be added to the receiver. @discussion An input that accepts media data of a type that is not compatible with the receiver, or with output settings that are not compatible with the receiver, cannot be added.

func (*AVAssetWriter) CanAddInputGroup ¶

func (o *AVAssetWriter) CanAddInputGroup(inputGroup *AVAssetWriterInputGroup) bool

@method canAddInputGroup: @abstract Tests whether an input group can be added to the receiver. @param inputGroup The AVAssetWriterInputGroup object to be tested. @result A BOOL indicating whether the input group can be added to the receiver. @discussion If outputFileType specifies a container format that does not support mutually exclusive relationships among tracks, or if the specified instance of AVAssetWriterInputGroup contains inputs with media types that cannot be related, the group cannot be added to the AVAssetWriter. This method throws an exception if any of the following conditions are satisfied: - this writer's output file type does not support mutually exclusive relationships among tracks (allowed types are AVFileTypeQuickTimeMovie, AVFileTypeAppleM4A, AVFileTypeAppleM4V, AVFileType3GPP, AVFileTypeMPEG4) - any AVAssetWriterInput in the input group is also present in an input group already added

func (*AVAssetWriter) CanApplyOutputSettingsForMediaType ¶

func (o *AVAssetWriter) CanApplyOutputSettingsForMediaType(outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID], mediaType *foundation.NSString) bool

@method canApplyOutputSettings:forMediaType: @abstract Tests whether output settings for a specific media type are supported by the receiver's file format. @param outputSettings The output settings that are to be tested. @param mediaType The media type for which the output settings are to be tested. Media types are defined in AVMediaFormat.h. @result A BOOL indicating whether the given output settings can be used for the given media type. @discussion This method determines whether the output settings for the specified media type can be used with the receiver's file format. For example, video compression settings that specify H.264 compression are not compatible with file formats that cannot contain H.264-compressed video. Attempting to add an input with output settings and a media type for which this method returns NO will cause an exception to be thrown.

func (*AVAssetWriter) CancelWriting ¶

func (o *AVAssetWriter) CancelWriting()

@method cancelWriting @abstract Cancels the creation of the output file. @discussion If the status of the receiver is "failed" or "completed," -cancelWriting is a no-op. Otherwise, this method will block until writing is canceled. If an output file was created by the receiver during the writing process, -cancelWriting will delete the file. This method should not be called concurrently with -[AVAssetWriterInput appendSampleBuffer:] or -[AVAssetWriterInputPixelBufferAdaptor appendPixelBuffer:withPresentationTime:].

func (*AVAssetWriter) Delegate ¶

func (o *AVAssetWriter) Delegate() AVAssetWriterDelegate

@property delegate @abstract An object that implements one or more of the methods in the AVAssetWriterDelegate protocol. @discussion This property cannot be set after writing has started.

func (*AVAssetWriter) DirectoryForTemporaryFiles ¶

func (o *AVAssetWriter) DirectoryForTemporaryFiles() *foundation.NSURL

@property directoryForTemporaryFiles @abstract Specifies a directory that is suitable for containing temporary files generated during the process of writing an asset. @discussion AVAssetWriter may need to write temporary files when configured in certain ways, such as when performsMultiPassEncodingIfSupported is set to YES on one or more of its inputs. This property can be used to control where in the filesystem those temporary files are created. All temporary files will be deleted when asset writing is completed, is canceled, or fails. When the value of this property is nil, the asset writer will choose a suitable location when writing temporary files. The default value is nil. This property cannot be set after writing has started. The asset writer will fail if a file cannot be created in this directory (for example, due to insufficient permissions).

func (*AVAssetWriter) EndSessionAtSourceTime ¶

func (o *AVAssetWriter) EndSessionAtSourceTime(endTime coremedia.CMTime)

@method endSessionAtSourceTime: @abstract Concludes a sample-writing session. @param endTime The ending asset time for the sample-writing session, in the timeline of the source samples. @discussion Call this method to complete a session started with -startSessionAtSourceTime:. The endTime defines the moment on the timeline of source samples at which the session ends. In the case of the QuickTime movie file format, each sample-writing session's startTime...endTime pair corresponds to a period of movie time into which the session's samples are inserted. Samples with timestamps that are later than the session end time will still be added to the written file but will be edited out (i.e. not presented during playback). So if the first session has duration D1 = endTime - startTime, it will be inserted into the written file at time 0 through D1; the second session would be inserted into the written file at time D1 through D1+D2, etc. It is legal to have a session with no samples; this will cause creation of an empty edit of the prescribed duration. It is not mandatory to call -endSessionAtSourceTime:; if -finishWritingWithCompletionHandler: is called without first invoking -endSessionAtSourceTime:, the session's effective end time will be the latest end timestamp of the session's appended samples (i.e. no samples will be edited out at the end). It is an error to append samples outside of a sample-writing session. To append more samples after invoking -endSessionAtSourceTime:, you must first start a new session using -startSessionAtSourceTime:. NOTE: Multiple sample-writing sessions are currently not supported. It is an error to call -startSessionAtSourceTime: a second time after calling -endSessionAtSourceTime:. This method throws an exception if the session is ended without first starting it.

func (*AVAssetWriter) Error ¶

func (o *AVAssetWriter) Error() unsafe.Pointer

@property error @abstract If the receiver's status is AVAssetWriterStatusFailed, this describes the error that caused the failure. @discussion The value of this property is an NSError that describes what caused the receiver to no longer be able to write to its output file. If the receiver's status is not AVAssetWriterStatusFailed, the value of this property is nil. This property is thread safe.

func (*AVAssetWriter) FinishWriting ¶

func (o *AVAssetWriter) FinishWriting() bool

@method finishWriting @abstract Completes the writing of the output file. @result A BOOL indicating whether writing successfully finished. @discussion This method is deprecated. Use finishWritingWithCompletionHandler: instead. This method will block until writing is finished. When this method returns successfully, the file being written by the receiver is complete and ready to use. Because this method is blocking and can take a long time to execute (especially with shouldOptimizeForNetworkUse set to YES), it should not be called from the main thread. Doing so can cause the finishWriting operation to fail. If writing cannot be finished, this method returns NO. Clients can check the values of the status and error properties for more information on why writing could not be finished. This method should not be called concurrently with -[AVAssetWriterInput appendSampleBuffer:] or -[AVAssetWriterInputPixelBufferAdaptor appendPixelBuffer:withPresentationTime:]. Deprecated: since macOS 10.9.

func (*AVAssetWriter) FinishWritingWithCompletionHandler ¶

func (o *AVAssetWriter) FinishWritingWithCompletionHandler(handler func())

@method finishWritingWithCompletionHandler: @abstract Marks all unfinished inputs as finished and completes the writing of the output file. @discussion This method returns immediately and causes its work to be performed asynchronously. When the writing of the output file is finished, or if a failure or a cancellation occurs in the meantime, the specified handler will be invoked to indicate completion of the operation. To determine whether the operation succeeded, your handler can check the value of AVAssetWriter.status. If the status is AVAssetWriterStatusFailed, AVAsset.error will contain an instance of NSError that describes the failure. To guarantee that all sample buffers are successfully written, ensure all calls to -[AVAssetWriterInput appendSampleBuffer:] or -[AVAssetWriterInputPixelBufferAdaptor appendPixelBuffer:withPresentationTime:] have returned before invoking this method.

func (*AVAssetWriter) FlushSegment ¶

func (o *AVAssetWriter) FlushSegment()

@method flushSegment @abstract Closes the current segment and outputs it to the -assetWriter:didOutputSegmentData:segmentType:segmentReport: or -assetWriter:didOutputSegmentData:segmentType: delegate method. @discussion This method throws an exception if the delegate method to output segment data is not implemented, or if the value of the preferredOutputSegmentInterval property is not kCMTimeIndefinite.

func (*AVAssetWriter) InitWithContentType ¶

func (o *AVAssetWriter) InitWithContentType(outputContentType *uniformtypeidentifiers.UTType) *AVAssetWriter

@method initWithContentType: @abstract Creates an instance of AVAssetWriter configured to output segment data in a specified container format. @param outputContentType A UTType indicating the format of the segment data to be output. @result An instance of AVAssetWriter. @discussion Clients that want to receive segment data through the -assetWriter:didOutputSegmentData:segmentType:segmentReport: or -assetWriter:didOutputSegmentData:segmentType: delegate method should use this initializer instead of -initWithURL:fileType:error:. Clients may use +typeWithIdentifier: with a UTI to create an instance of UTType. See <UniformTypeIdentifiers/UTType.h>. This method throws an exception if the output content type UTI for container format is not declared in AVMediaFormat.h.

func (*AVAssetWriter) InitWithURLFileTypeError ¶

func (o *AVAssetWriter) InitWithURLFileTypeError(outputURL *foundation.NSURL, outputFileType *foundation.NSString) (*AVAssetWriter, error)

@method initWithURL:fileType:error: @abstract Creates an instance of AVAssetWriter configured to write to a file in a specified container format. @param URL The location of the file to be written. The URL must be a file URL. @param fileType A UTI indicating the format of the file to be written. @param outError On return, if initialization of the AVAssetWriter fails, points to an NSError describing the nature of the failure. @result An instance of AVAssetWriter. @discussion Writing will fail if a file already exists at the specified URL. This method throws an exception if the output file type is not declared in AVMediaFormat.h.

func (*AVAssetWriter) InitialMovieFragmentInterval ¶

func (o *AVAssetWriter) InitialMovieFragmentInterval() coremedia.CMTime

@property initialMovieFragmentInterval @abstract For file types that support movie fragments, specifies the interval at which initial movie fragment should be written. @discussion This property is irrelevant if the movieFragmentInterval property is not set. The default value is kCMTimeInvalid, which indicates that the interval for initial movie fragment is same as the one specified by movieFragmentInterval property. This property cannot be set after writing has started.

func (*AVAssetWriter) InitialMovieFragmentSequenceNumber ¶

func (o *AVAssetWriter) InitialMovieFragmentSequenceNumber() int

@property initialMovieFragmentSequenceNumber @abstract For file types that support movie fragments, specifies the initial movie fragment sequence number. @discussion The value must be equal to or greater than 1. The default value is 1. Note that if you combine movie fragments produced by an instance of AVAssetWriter with additional movie fragments, produced either by a different instance of AVAssetWriter or by some other means, it is necessary to ensure that movie fragment sequence numbers increase monotonically across the entire combined collection, in temporal order. This property cannot be set after writing has started.

func (*AVAssetWriter) InitialSegmentStartTime ¶

func (o *AVAssetWriter) InitialSegmentStartTime() coremedia.CMTime

@property initialSegmentStartTime @abstract Specifies start time of initial segment. @discussion A numeric time must be set if the value of preferredOutputSegmentInterval property is positive numeric. If not, this property is irrelevant. This property cannot be set after writing has started.

func (*AVAssetWriter) InputGroups ¶

func (*AVAssetWriter) Inputs ¶

@property inputs @abstract The inputs from which the asset writer receives media data. @discussion The value of this property is an NSArray containing concrete instances of AVAssetWriterInput. Inputs can be added to the receiver using the addInput: method.

func (*AVAssetWriter) Metadata ¶

@property metadata @abstract A collection of metadata to be written to the receiver's output file. @discussion The value of this property is an array of AVMetadataItem objects representing the collection of top-level metadata to be written in the output file. This property cannot be set after writing has started.

func (*AVAssetWriter) MovieFragmentInterval ¶

func (o *AVAssetWriter) MovieFragmentInterval() coremedia.CMTime

@property movieFragmentInterval @abstract For file types that support movie fragments, specifies the frequency at which movie fragments should be written. @discussion When movie fragments are used, a partially written asset whose writing is unexpectedly interrupted can be successfully opened and played up to multiples of the specified time interval. The default value of this property is kCMTimeInvalid, which indicates that movie fragments should not be used. When using movie fragments, for best writing performance to external storage devices, set the movieFragmentInterval to 10 seconds or greater. This property cannot be set after writing has started.

func (*AVAssetWriter) MovieTimeScale ¶

func (o *AVAssetWriter) MovieTimeScale() int32

@property movieTimeScale @abstract For file types that contain a 'moov' atom, such as QuickTime Movie files, specifies the asset-level time scale to be used. @discussion The default value is 0, which indicates that the receiver should choose a convenient value, if applicable. This property cannot be set after writing has started.

func (*AVAssetWriter) OutputFileType ¶

func (o *AVAssetWriter) OutputFileType() *foundation.NSString

@property outputFileType @abstract The UTI of the file format of the file for which the instance of AVAssetWriter was initialized for writing.

func (*AVAssetWriter) OutputFileTypeProfile ¶

func (o *AVAssetWriter) OutputFileTypeProfile() *foundation.NSString

func (*AVAssetWriter) OutputURL ¶

func (o *AVAssetWriter) OutputURL() *foundation.NSURL

@property outputURL @abstract The location of the file for which the instance of AVAssetWriter was initialized for writing. @discussion You may use [[UTType typeWithIdentifier:outputFileType] preferredFilenameExtension] to obtain an appropriate path extension for the outputFileType you have specified. For more information, see <UniformTypeIdentifiers/UTType.h>.

func (*AVAssetWriter) OverallDurationHint ¶

func (o *AVAssetWriter) OverallDurationHint() coremedia.CMTime

@property overallDurationHint @abstract For file types that support movie fragments, provides a hint of the final duration of the file to be written @discussion The value of this property must be a nonnegative, numeric CMTime. Alternatively, if the value of this property is an invalid CMTime (e.g. kCMTimeInvalid), no overall duration hint will be written to the file. The default value is kCMTimeInvalid. This property is currently ignored if movie fragments are not being written. Use the movieFragmentInterval property to enable movie fragments. This property cannot be set after writing has started.

func (*AVAssetWriter) PreferredOutputSegmentInterval ¶

func (o *AVAssetWriter) PreferredOutputSegmentInterval() coremedia.CMTime

@property preferredOutputSegmentInterval @abstract Specifies preferred segment interval. @discussion The default value is kCMTimeInvalid, which means that the receiver will choose an appropriate default value. The value can be set to positive numeric or kCMTimeIndefinite. If the value is kCMTimeIndefinite, every time a client calls -flushSegment the receiver outputs a segment data. This property cannot be set after writing has started.

func (*AVAssetWriter) ProducesCombinableFragments ¶

func (o *AVAssetWriter) ProducesCombinableFragments() bool

@property producesCombinableFragments @abstract For file types that support fragmented MPEG-4, specifies whether the movie fragments should be produced in way that makes them suitable for combining with movie fragments produced by one or more other instances of AVAssetWriter into a single fragment stream of uniform encoding. @discussion The default value is NO. When multiple instances of AVAssetWriter are used to produce distinct streams that complement each other, for example to create HLS encoding or bitrate variants, it’s not necessary to set this property to YES. This property cannot be set after writing has started.

func (*AVAssetWriter) SetDelegate ¶

func (o *AVAssetWriter) SetDelegate(delegate AVAssetWriterDelegate)

func (*AVAssetWriter) SetDirectoryForTemporaryFiles ¶

func (o *AVAssetWriter) SetDirectoryForTemporaryFiles(directoryForTemporaryFiles *foundation.NSURL)

func (*AVAssetWriter) SetInitialMovieFragmentInterval ¶

func (o *AVAssetWriter) SetInitialMovieFragmentInterval(initialMovieFragmentInterval coremedia.CMTime)

func (*AVAssetWriter) SetInitialMovieFragmentSequenceNumber ¶

func (o *AVAssetWriter) SetInitialMovieFragmentSequenceNumber(initialMovieFragmentSequenceNumber int)

func (*AVAssetWriter) SetInitialSegmentStartTime ¶

func (o *AVAssetWriter) SetInitialSegmentStartTime(initialSegmentStartTime coremedia.CMTime)

func (*AVAssetWriter) SetMetadata ¶

func (o *AVAssetWriter) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVAssetWriter) SetMovieFragmentInterval ¶

func (o *AVAssetWriter) SetMovieFragmentInterval(movieFragmentInterval coremedia.CMTime)

func (*AVAssetWriter) SetMovieTimeScale ¶

func (o *AVAssetWriter) SetMovieTimeScale(movieTimeScale int32)

func (*AVAssetWriter) SetOutputFileTypeProfile ¶

func (o *AVAssetWriter) SetOutputFileTypeProfile(outputFileTypeProfile *foundation.NSString)

func (*AVAssetWriter) SetOverallDurationHint ¶

func (o *AVAssetWriter) SetOverallDurationHint(overallDurationHint coremedia.CMTime)

func (*AVAssetWriter) SetPreferredOutputSegmentInterval ¶

func (o *AVAssetWriter) SetPreferredOutputSegmentInterval(preferredOutputSegmentInterval coremedia.CMTime)

func (*AVAssetWriter) SetProducesCombinableFragments ¶

func (o *AVAssetWriter) SetProducesCombinableFragments(producesCombinableFragments bool)

func (*AVAssetWriter) SetShouldOptimizeForNetworkUse ¶

func (o *AVAssetWriter) SetShouldOptimizeForNetworkUse(shouldOptimizeForNetworkUse bool)

func (*AVAssetWriter) ShouldOptimizeForNetworkUse ¶

func (o *AVAssetWriter) ShouldOptimizeForNetworkUse() bool

@property shouldOptimizeForNetworkUse @abstract Specifies whether the output file should be written in way that makes it more suitable for playback over a network @discussion When the value of this property is YES, the output file will be written in such a way that playback can start after only a small amount of the file is downloaded. This property cannot be set after writing has started.

func (*AVAssetWriter) StartSessionAtSourceTime ¶

func (o *AVAssetWriter) StartSessionAtSourceTime(startTime coremedia.CMTime)

@method startSessionAtSourceTime: @abstract Initiates a sample-writing session for the receiver. @param startTime The starting asset time for the sample-writing session, in the timeline of the source samples. @discussion Sequences of sample data appended to the asset writer inputs are considered to fall within "sample-writing sessions", initiated with this method. Accordingly, this method must be called after writing has started (using -startWriting) but before any sample data is appended to the receiver's inputs. Each writing session has a start time which, where allowed by the file format being written, defines the mapping from the timeline of source samples to the timeline of the written file. In the case of the QuickTime movie file format, the first session begins at movie time 0, so a sample appended with timestamp T will be played at movie time (T-startTime). Samples with timestamps earlier than startTime will still be added to the output file but will be edited out (i.e. not presented during playback). If the earliest appended sample for an input has a timestamp later than than startTime, an empty edit will be inserted to preserve synchronization between tracks of the output asset. To end the session started by use of this method, use -endSessionAtSourceTime: or -finishWritingWithCompletionHandler:. It is an error to invoke -startSessionAtSourceTime: twice in a row without invoking -endSessionAtSourceTime: in between. NOTE: Multiple sample-writing sessions are currently not supported. It is an error to call -startSessionAtSourceTime: a second time after calling -endSessionAtSourceTime:.

func (*AVAssetWriter) StartWriting ¶

func (o *AVAssetWriter) StartWriting() bool

@method startWriting @abstract Prepares the receiver for accepting input and for writing its output to its output file. @result A BOOL indicating whether writing successfully started. @discussion This method must be called after all inputs have been added and other configuration properties have been set in order to tell the receiver to prepare for writing. After this method is called, clients can start writing sessions using startSessionAtSourceTime: and can write media samples using the methods provided by each of the receiver's inputs. If writing cannot be started, this method returns NO. Clients can check the values of the status and error properties for more information on why writing could not be started. On iOS, if the status of an AVAssetWriter is AVAssetWriterStatusWriting when the client app goes into the background, its status will change to AVAssetWriterStatusFailed and appending to any of its inputs will fail. You may want to use -[UIApplication beginBackgroundTaskWithExpirationHandler:] to avoid being interrupted in the middle of a writing session and to finish writing the data that has already been appended. For more information about executing code in the background, see the iOS Application Programming Guide.

func (*AVAssetWriter) Status ¶

func (o *AVAssetWriter) Status() AVAssetWriterStatus

@property status @abstract The status of writing samples to the receiver's output file. @discussion The value of this property is an AVAssetWriterStatus that indicates whether writing is in progress, has completed successfully, has been canceled, or has failed. Clients of AVAssetWriterInput objects should check the value of this property after appending samples fails to determine why no more samples could be written. This property is thread safe.

type AVAssetWriterDelegate ¶

type AVAssetWriterDelegate interface {
}

AVAssetWriterDelegate wraps the ObjC protocol AVAssetWriterDelegate.

type AVAssetWriterInput ¶

type AVAssetWriterInput struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinput

func AVAssetWriterInputAssetWriterInputWithMediaTypeOutputSettings ¶

func AVAssetWriterInputAssetWriterInputWithMediaTypeOutputSettings(mediaType *foundation.NSString, outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetWriterInput

Creates a new input of the specified media type to receive sample buffers for writing to the output file. Each new input accepts data for a new track of the AVAssetWriter's output file. Inputs are added to an asset writer using -[AVAssetWriter addInput:]. Passing nil for output settings instructs the input to pass through appended samples, doing no processing before they are written to the output file. This is useful if, for example, you are appending buffers that are already in a desirable compressed format. However, if not writing to a QuickTime Movie file (i.e. the AVAssetWriter was initialized with a file type other than AVFileTypeQuickTimeMovie), AVAssetWriter only supports passing through a restricted set of media types and subtypes. In order to pass through media data to files other than AVFileTypeQuickTimeMovie, a non-NULL format hint must be provided using +assetWriterInputWithMediaType:outputSettings:sourceFormatHint: instead of this method. For AVMediaTypeAudio the following keys are not currently supported in the outputSettings dictionary: AVSampleRateConverterAudioQualityKey. When using this method to construct a new instance, an audio settings dictionary must be fully specified, meaning that it must contain AVFormatIDKey, AVSampleRateKey, and AVNumberOfChannelsKey. If no other channel layout information is available, a value of 1 for AVNumberOfChannelsKey will result in mono output and a value of 2 will result in stereo output. If AVNumberOfChannelsKey specifies a channel count greater than 2, the dictionary must also specify a value for AVChannelLayoutKey. For kAudioFormatLinearPCM, all relevant AVLinearPCM*Key keys must be included, and for kAudioFormatAppleLossless, AVEncoderBitDepthHintKey keys must be included. See +assetWriterInputWithMediaType:outputSettings:sourceFormatHint: for a way to avoid having to specify a value for each of those keys. For AVMediaTypeVideo, any output settings dictionary must request a compressed video format. This means that the value passed in for outputSettings must follow the rules for compressed video output, as laid out in AVVideoSettings.h. When using this method to construct a new instance, a video settings dictionary must be fully specified, meaning that it must contain AVVideoCodecKey, AVVideoWidthKey, and AVVideoHeightKey. See +assetWriterInputWithMediaType:outputSettings:sourceFormatHint: for a way to avoid having to specify a value for each of those keys. On iOS, the only values currently supported for AVVideoCodecKey are AVVideoCodecTypeH264 and AVVideoCodecTypeJPEG. AVVideoCodecTypeH264 is not supported on iPhone 3G. For AVVideoScalingModeKey, the value AVVideoScalingModeFit is not supported. - Parameter mediaType: The media type of samples that will be accepted by the input. Media types are defined in AVMediaFormat.h. - Parameter outputSettings: The settings used for encoding the media appended to the output. See AVAudioSettings.h for AVMediaTypeAudio or AVVideoSettings.h for AVMediaTypeVideo and for more information on how to construct an output settings dictionary. If you only require simple preset-based output settings, see AVOutputSettingsAssistant. - Returns: An instance of AVAssetWriterInput.

func AVAssetWriterInputAssetWriterInputWithMediaTypeOutputSettingsSourceFormatHint ¶

func AVAssetWriterInputAssetWriterInputWithMediaTypeOutputSettingsSourceFormatHint(mediaType *foundation.NSString, outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID], sourceFormatHint unsafe.Pointer) *AVAssetWriterInput

Creates a new input of the specified media type to receive sample buffers for writing to the output file. A version of +assetWriterInputWithMediaType:outputSettings: that includes the ability to hint at the format of media data that will be appended to the new instance of AVAssetWriterInput. When a source format hint is provided, the outputSettings dictionary is not required to be fully specified. For AVMediaTypeAudio, this means that AVFormatIDKey is the only required key. For AVMediaTypeVideo, this means that AVVideoCodecKey is the only required key. Values for the remaining keys will be chosen by the asset writer input, with consideration given to the attributes of the source format. To guarantee successful file writing, clients who specify a format hint should ensure that subsequently-appended buffers are of the specified format. This method throws an exception for any of the following reasons: - the media type of the format description does not match the media type passed into this method - the width and height of video format hint are not positive - the output settings do not match the supplied media type - for video inputs, the output settings do not contain a required key (AVVideoCodecKey, AVVideoWidthKey, AVVideoHeightKey) - the output scaling mode is AVVideoScalingModeFit - the output settings contain AVSampleRateConverterAudioQualityKey or AVVideoDecompressionPropertiesKey - Parameter mediaType: The media type of samples that will be accepted by the input. Media types are defined in AVMediaFormat.h. - Parameter outputSettings: The settings used for encoding the media appended to the output. See AVAudioSettings.h for AVMediaTypeAudio or AVVideoSettings.h for AVMediaTypeVideo and for more information on how to construct an output settings dictionary. If you only require simple preset-based output settings, see AVOutputSettingsAssistant. - Parameter sourceFormatHint: A hint about the format of media data that will be appended to the new input. - Returns: An instance of AVAssetWriterInput.

func AVAssetWriterInputFromID ¶

func AVAssetWriterInputFromID(id objc.ID) *AVAssetWriterInput

func (*AVAssetWriterInput) AddTrackAssociationWithTrackOfInputType ¶

func (o *AVAssetWriterInput) AddTrackAssociationWithTrackOfInputType(input *AVAssetWriterInput, trackAssociationType *foundation.NSString)

Associates the track corresponding to the specified input with the track corresponding with the receiver. If the type of association requires tracks of specific media types that don't match the media types of the inputs, or if the output file type does not support track associations, an NSInvalidArgumentException is raised. Track associations cannot be added after writing on the receiver's AVAssetWriter has started. This method throws an exception if the input and track association type cannot be added (see -canAddTrackAssociationWithTrackOfInput:type:). - Parameter input: The instance of AVAssetWriterInput with a corresponding track to associate with track corresponding to the receiver. - Parameter trackAssociationType: The type of track association to add. Common track association types, such as AVTrackAssociationTypeTimecode, are defined in AVAssetTrack.h.

func (*AVAssetWriterInput) AppendSampleBuffer ¶

func (o *AVAssetWriterInput) AppendSampleBuffer(sampleBuffer unsafe.Pointer) bool

Appends samples to the receiver. The timing information in the sample buffer, considered relative to the time passed to -[AVAssetWriter startSessionAtSourceTime:], will be used to determine the timing of those samples in the output file. For track types other than audio tracks, to determine the duration of all samples in the output file other than the very last sample that's appended, the difference between the sample buffer's output DTS and the following sample buffer's output DTS will be used. The duration of the last sample is determined as follows: 1. If a marker sample buffer with kCMSampleBufferAttachmentKey_EndsPreviousSampleDuration is appended following the last media-bearing sample, the difference between the output DTS of the marker sample buffer and the output DTS of the last media-bearing sample will be used. 2. If the marker sample buffer is not provided and if the output duration of the last media-bearing sample is valid, it will be used. 3. if the output duration of the last media-bearing sample is not valid, the duration of the second-to-last sample will be used. For audio tracks, the properties of each appended sample buffer are used to determine corresponding output durations. The receiver will retain the CMSampleBuffer until it is done with it, and then release it. Do not modify a CMSampleBuffer or its contents after you have passed it to this method. If the sample buffer contains audio data and the AVAssetWriterInput was intialized with an outputSettings dictionary then the format must be linear PCM. If the outputSettings dictionary was nil then audio data can be provided in a compressed format, and it will be passed through to the output without any re-compression. Note that advanced formats like AAC will have encoder delay present in their bitstreams. This data is inserted by the encoder and is necessary for proper decoding, but it is not meant to be played back. Clients who provide compressed audio bitstreams must use kCMSampleBufferAttachmentKey_TrimDurationAtStart to mark the encoder delay (generally restricted to the first sample buffer). Packetization can cause there to be extra audio frames in the last packet which are not meant to be played back. These remainder frames should be marked with kCMSampleBufferAttachmentKey_TrimDurationAtEnd. CMSampleBuffers obtained from AVAssetReader will already have the necessary trim attachments. Please see http://developer.apple.com/mac/library/technotes/tn2009/tn2258.html for more information about encoder delay. When attaching trims make sure that the output PTS of the sample buffer is what you expect. For example if you called -[AVAssetWriter startSessionAtSourceTime:kCMTimeZero] and you want your audio to start at time zero in the output file then make sure that the output PTS of the first non-fully trimmed audio sample buffer is kCMTimeZero. If the sample buffer contains a CVPixelBuffer then the choice of pixel format will affect the performance and quality of the encode. For optimal performance the format of the pixel buffer should match one of the native formats supported by the selected video encoder. Below are some recommendations: The H.264 and HEVC encoders natively support kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange and kCVPixelFormatType_420YpCbCr8BiPlanarFullRange, which should be used with 8-bit 4:2:0 video and full range input respectively; other related pixel formats in CoreVideo/CVPixelBuffer.h are ideal for 4:2:2 and 4:4:4 (and for HEVC, 10-bit). The JPEG encoder on iOS and Apple Silicon macOS natively supports kCVPixelFormatType_422YpCbCr8FullRange. If you need to work in the RGB domain then kCVPixelFormatType_32BGRA is recommended on iOS and macOS. Pixel buffers not in a natively supported format will be converted internally prior to encoding when possible. Pixel format conversions within the same range (video or full) are generally faster than conversions between different ranges. The ProRes encoders can preserve high bit depth sources, supporting up to 12bits/ch. ProRes 4444 can contain a mathematically lossless alpha channel and it doesn't do any chroma subsampling. This makes ProRes 4444 ideal for quality critical applications. If you are working with 8bit sources ProRes is also a good format to use due to its high image quality. Use either of the recommended pixel formats above. Note that RGB pixel formats by definition have 4:4:4 chroma sampling. If you are working with high bit depth sources the following yuv pixel formats are recommended when encoding to ProRes: kCVPixelFormatType_4444AYpCbCr16, kCVPixelFormatType_422YpCbCr16, and kCVPixelFormatType_422YpCbCr10. When working in the RGB domain kCVPixelFormatType_64ARGB is recommended. Scaling and color matching are not currently supported when using AVAssetWriter with any of these high bit depth pixel formats. Please make sure that your track's output settings dictionary specifies the same width and height as the buffers you will be appending. Do not include AVVideoScalingModeKey or AVVideoColorPropertiesKey. As of macOS 10.10 and iOS 8.0, this method can be used to add sample buffers that reference existing data in a file instead of containing media data to be appended to the file. This can be used to generate tracks that are not self-contained. In order to append such a sample reference to the track create a CMSampleBufferRef with a NULL dataBuffer and dataReady set to true and set the kCMSampleBufferAttachmentKey_SampleReferenceURL and kCMSampleBufferAttachmentKey_SampleReferenceByteOffset attachments on the sample buffer. Further documentation on how to create such a "sample reference" sample buffer can be found in the description of the kCMSampleBufferAttachmentKey_SampleReferenceURL and kCMSampleBufferAttachmentKey_SampleReferenceByteOffset attachment keys in the CMSampleBuffer documentation. Before calling this method, you must ensure that the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer. It is an error to invoke this method before starting a session (via -[AVAssetWriter startSessionAtSourceTime:]) or after ending a session (via -[AVAssetWriter endSessionAtSourceTime:]). This method throws an exception if the sample buffer's media type does not match the asset writer input's media type. - Parameter sampleBuffer: The CMSampleBuffer to be appended. - Returns: A BOOL value indicating success of appending the sample buffer. If a result of NO is returned, clients can check the value of AVAssetWriter.status to determine whether the writing operation completed, failed, or was cancelled. If the status is AVAssetWriterStatusFailed, AVAsset.error will contain an instance of NSError that describes the failure.

func (*AVAssetWriterInput) CanAddTrackAssociationWithTrackOfInputType ¶

func (o *AVAssetWriterInput) CanAddTrackAssociationWithTrackOfInputType(input *AVAssetWriterInput, trackAssociationType *foundation.NSString) bool

Tests whether an association between the tracks corresponding to a pair of inputs is valid. If the type of association requires tracks of specific media types that don't match the media types of the inputs, or if the output file type does not support track associations, -canAddTrackAssociationWithTrackOfInput:type: will return NO. - Parameter input: The instance of AVAssetWriterInput with a corresponding track to associate with track corresponding with the receiver. - Parameter trackAssociationType: The type of track association to test. Common track association types, such as AVTrackAssociationTypeTimecode, are defined in AVAssetTrack.h.

func (*AVAssetWriterInput) CanPerformMultiplePasses ¶

func (o *AVAssetWriterInput) CanPerformMultiplePasses() bool

Indicates whether the input might perform multiple passes over appended media data. When the value for this property is YES, your source for media data should be configured for random access. After appending all of the media data for the current pass (as specified by the currentPassDescription property), call -markCurrentPassAsFinished to start the process of determining whether additional passes are needed. Note that it is still possible in this case for the input to perform only the initial pass, if it determines that there will be no benefit to performing multiple passes. When the value for this property is NO, your source for media data only needs to support sequential access. In this case, append all of the source media once and call -markAsFinished. In the default configuration of AVAssetWriterInput, the value for this property will be NO. Currently the only way for this property to become YES is when performsMultiPassEncodingIfSupported has been set to YES. The final value will be available after -startWriting is called, when a specific encoder has been choosen. This property is key-value observable.

func (*AVAssetWriterInput) CurrentPassDescription ¶

func (o *AVAssetWriterInput) CurrentPassDescription() *AVAssetWriterInputPassDescription

Provides an object that describes the requirements, such as source time ranges to append or re-append, for the current pass. If the value of this property is nil, it means there is no request to be fulfilled and -markAsFinished should be called on the asset writer input. During the first pass, the request will contain a single time range from zero to positive infinity, indicating that all media from the source should be appended. This will also be true when canPerformMultiplePasses is NO, in which case only one pass will be performed. The value of this property will be nil before -startWriting is called on the attached asset writer. It will transition to an initial non-nil value during the call to -startWriting. After that, the value of this property will change only after a call to -markCurrentPassAsFinished. For an easy way to be notified at the beginning of each pass, see -respondToEachPassDescriptionOnQueue:usingBlock:. This property is key-value observable. Observers should not assume that they will be notified of changes on a specific thread.

func (*AVAssetWriterInput) ExpectsMediaDataInRealTime ¶

func (o *AVAssetWriterInput) ExpectsMediaDataInRealTime() bool

Indicates whether the input should tailor its processing of media data for real-time sources. Clients appending media data to an input from a real-time source, such as an AVCaptureOutput, should set expectsMediaDataInRealTime to YES. This will ensure that readyForMoreMediaData is calculated appropriately for real-time usage. For best results, do not set both this property and performsMultiPassEncodingIfSupported to YES. This property cannot be set after writing on the receiver's AVAssetWriter has started.

func (*AVAssetWriterInput) ExtendedLanguageTag ¶

func (o *AVAssetWriterInput) ExtendedLanguageTag() *foundation.NSString

Indicates the language tag to associate with the track corresponding to the receiver, as an IETF BCP 47 (RFC 4646) language identifier; can be nil. Extended language tags are normally set only when an ISO 639-2/T language code by itself is ambiguous, as in cases in which media data should be distinguished not only by language but also by the regional dialect in use or the writing system employed. This property cannot be set after writing on the receiver's AVAssetWriter has started. This property throws an exception if an extended language tag is set which does not conform to the IETF BCP 47 (RFC 4646) language identifiers.

func (*AVAssetWriterInput) InitWithMediaTypeOutputSettings ¶

func (o *AVAssetWriterInput) InitWithMediaTypeOutputSettings(mediaType *foundation.NSString, outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetWriterInput

Creates a new input of the specified media type to receive sample buffers for writing to the output file. Each new input accepts data for a new track of the AVAssetWriter's output file. Inputs are added to an asset writer using -[AVAssetWriter addInput:]. Passing nil for output settings instructs the input to pass through appended samples, doing no processing before they are written to the output file. This is useful if, for example, you are appending buffers that are already in a desirable compressed format. However, if not writing to a QuickTime Movie file (i.e. the AVAssetWriter was initialized with a file type other than AVFileTypeQuickTimeMovie), AVAssetWriter only supports passing through a restricted set of media types and subtypes. In order to pass through media data to files other than AVFileTypeQuickTimeMovie, a non-NULL format hint must be provided using -initWithMediaType:outputSettings:sourceFormatHint: instead of this method. For AVMediaTypeAudio the following keys are not currently supported in the outputSettings dictionary: AVSampleRateConverterAudioQualityKey. When using this initializer, an audio settings dictionary must be fully specified, meaning that it must contain AVFormatIDKey, AVSampleRateKey, and AVNumberOfChannelsKey. If no other channel layout information is available, a value of 1 for AVNumberOfChannelsKey will result in mono output and a value of 2 will result in stereo output. If AVNumberOfChannelsKey specifies a channel count greater than 2, the dictionary must also specify a value for AVChannelLayoutKey. For kAudioFormatLinearPCM, all relevant AVLinearPCM*Key keys must be included, and for kAudioFormatAppleLossless, AVEncoderBitDepthHintKey keys must be included. See -initWithMediaType:outputSettings:sourceFormatHint: for a way to avoid having to specify a value for each of those keys. For AVMediaTypeVideo, any output settings dictionary must request a compressed video format. This means that the value passed in for outputSettings must follow the rules for compressed video output, as laid out in AVVideoSettings.h. When using this initializer, a video settings dictionary must be fully specified, meaning that it must contain AVVideoCodecKey, AVVideoWidthKey, and AVVideoHeightKey. See -initWithMediaType:outputSettings:sourceFormatHint: for a way to avoid having to specify a value for each of those keys. On iOS, the only values currently supported for AVVideoCodecKey are AVVideoCodecTypeH264 and AVVideoCodecTypeJPEG. AVVideoCodecTypeH264 is not supported on iPhone 3G. For AVVideoScalingModeKey, the value AVVideoScalingModeFit is not supported. This method throws an exception for any of the following reasons: - the media type of the format description does not match the media type passed into this method - the output settings do not match the supplied media type - for video inputs, the output settings do not contain a required key (AVVideoCodecKey, AVVideoWidthKey, AVVideoHeightKey) - the output scaling mode is AVVideoScalingModeFit - the output settings contain AVSampleRateConverterAudioQualityKey or AVVideoDecompressionPropertiesKey - Parameter mediaType: The media type of samples that will be accepted by the input. Media types are defined in AVMediaFormat.h. - Parameter outputSettings: The settings used for encoding the media appended to the output. See AVAudioSettings.h for AVMediaTypeAudio or AVVideoSettings.h for AVMediaTypeVideo and for more information on how to construct an output settings dictionary. If you only require simple preset-based output settings, see AVOutputSettingsAssistant. - Returns: An instance of AVAssetWriterInput.

func (*AVAssetWriterInput) InitWithMediaTypeOutputSettingsSourceFormatHint ¶

func (o *AVAssetWriterInput) InitWithMediaTypeOutputSettingsSourceFormatHint(mediaType *foundation.NSString, outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID], sourceFormatHint unsafe.Pointer) *AVAssetWriterInput

Creates a new input of the specified media type to receive sample buffers for writing to the output file. This is the designated initializer of AVAssetWriterInput. A version of -initWithMediaType:outputSettings: that includes the ability to hint at the format of media data that will be appended to the new instance of AVAssetWriterInput. When a source format hint is provided, the outputSettings dictionary is not required to be fully specified. For AVMediaTypeAudio, this means that AVFormatIDKey is the only required key. For AVMediaTypeVideo, this means that AVVideoCodecKey is the only required key. Values for the remaining keys will be chosen by the asset writer input, with consideration given to the attributes of the source format. To guarantee successful file writing, clients who specify a format hint should ensure that subsequently-appended buffers are of the specified format. This method throws an exception for any of the following reasons: - the media type of the format description does not match the media type passed into this method - the width and height of video format hint are not positive - the output settings do not match the supplied media type - for video inputs, the output settings do not contain a required key (AVVideoCodecKey, AVVideoWidthKey, AVVideoHeightKey) - the output scaling mode is AVVideoScalingModeFit - the output settings contain AVSampleRateConverterAudioQualityKey or AVVideoDecompressionPropertiesKey - Parameter mediaType: The media type of samples that will be accepted by the input. Media types are defined in AVMediaFormat.h. - Parameter outputSettings: The settings used for encoding the media appended to the output. See AVAudioSettings.h for AVMediaTypeAudio or AVVideoSettings.h for AVMediaTypeVideo and for more information on how to construct an output settings dictionary. If you only require simple preset-based output settings, see AVOutputSettingsAssistant. - Parameter sourceFormatHint: A hint about the format of media data that will be appended to the new input. - Returns: An instance of AVAssetWriterInput.

func (*AVAssetWriterInput) IsReadyForMoreMediaData ¶

func (o *AVAssetWriterInput) IsReadyForMoreMediaData() bool

Indicates the readiness of the input to accept more media data. When there are multiple inputs, AVAssetWriter tries to write media data in an ideal interleaving pattern for efficiency in storage and playback. Each of its inputs signals its readiness to receive media data for writing according to that pattern via the value of readyForMoreMediaData. You can append media data to an input only while its readyForMoreMediaData property is YES. Clients writing media data from a non-real-time source, such as an instance of AVAssetReader, should hold off on generating or obtaining more media data to append to an input when the value of readyForMoreMediaData is NO. To help with control of the supply of non-real-time media data, such clients can use -requestMediaDataWhenReadyOnQueue:usingBlock in order to specify a block that the input should invoke whenever it's ready for input to be appended. Clients writing media data from a real-time source, such as an instance of AVCaptureOutput, should set the input's expectsMediaDataInRealTime property to YES to ensure that the value of readyForMoreMediaData is calculated appropriately. When expectsMediaDataInRealTime is YES, readyForMoreMediaData will become NO only when the input cannot process media samples as quickly as they are being provided by the client. If readyForMoreMediaData becomes NO for a real-time source, the client may need to drop samples or consider reducing the data rate of appended samples. When the value of canPerformMultiplePasses is YES for any input attached to this input's asset writer, the value for this property may start as NO and/or be NO for long periods of time. The value of readyForMoreMediaData will often change from NO to YES asynchronously, as previously supplied media data is processed and written to the output. It is possible for all of an AVAssetWriter's AVAssetWriterInputs temporarily to return NO for readyForMoreMediaData. This property is key value observable. Observers should not assume that they will be notified of changes on a specific thread.

func (*AVAssetWriterInput) LanguageCode ¶

func (o *AVAssetWriterInput) LanguageCode() *foundation.NSString

Indicates the language to associate with the track corresponding to the receiver, as an ISO 639-2/T language code; can be nil. Also see extendedLanguageTag below. This property cannot be set after writing on the receiver's AVAssetWriter has started. This property throws an exception if a language code is set which does not conform to the ISO 639-2/T language codes.

func (*AVAssetWriterInput) MarkAsFinished ¶

func (o *AVAssetWriterInput) MarkAsFinished()

Indicates to the AVAssetWriter that no more buffers will be appended to this input. Clients that are monitoring each input's readyForMoreMediaData value must call markAsFinished on an input when they are done appending buffers to it. This is necessary to prevent other inputs from stalling, as they may otherwise wait forever for that input's media data, attempting to complete the ideal interleaving pattern. After invoking this method from the serial queue passed to -requestMediaDataWhenReadyOnQueue:usingBlock:, the receiver is guaranteed to issue no more invocations of the block passed to that method. The same is true of -respondToEachPassDescriptionOnQueue:usingBlock:. Before calling this method, you must ensure that the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer.

func (*AVAssetWriterInput) MarkCurrentPassAsFinished ¶

func (o *AVAssetWriterInput) MarkCurrentPassAsFinished()

Instructs the receiver to analyze the media data that has been appended and determine whether the results could be improved by re-encoding certain segments. When the value of canPerformMultiplePasses is YES, call this method after you have appended all of your media data. After the receiver analyzes whether an additional pass is warranted, the value of currentPassDescription will change (usually asynchronously) to describe how to set up for the next pass. Although it is possible to use key-value observing to determine when the value of currentPassDescription has changed, it is typically more convenient to invoke -respondToEachPassDescriptionOnQueue:usingBlock: in order to start the work for each pass. After re-appending the media data for all of the time ranges of the new pass, call this method again to determine whether additional segments should be re-appended in another pass. Calling this method effectively cancels any previous invocation of -requestMediaDataWhenReadyOnQueue:usingBlock:, meaning that -requestMediaDataWhenReadyOnQueue:usingBlock: can be invoked again for each new pass. -respondToEachPassDescriptionOnQueue:usingBlock: provides a convenient way to consolidate these invocations in your code. After each pass, you have the option of keeping the most recent results by calling -markAsFinished instead of this method. If the value of currentPassDescription is nil at the beginning of a pass, call -markAsFinished to tell the receiver to not expect any further media data. If the value of canPerformMultiplePasses is NO, the value of currentPassDescription will immediately become nil after calling this method. Before calling this method, you must ensure that the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer.

func (*AVAssetWriterInput) MarksOutputTrackAsEnabled ¶

func (o *AVAssetWriterInput) MarksOutputTrackAsEnabled() bool

For file types that support enabled and disabled tracks, such as QuickTime Movie files, specifies whether the track corresponding to the receiver should be enabled by default for playback and processing. The default value is YES. When an input group is added to an AVAssetWriter (see -[AVAssetWriter addInputGroup:]), the value of marksOutputTrackAsEnabled will automatically be set to YES for the default input and set to NO for all of the other inputs in the group. In this case, if a new value is set on this property then an exception will be raised. This property cannot be set after writing on the receiver's AVAssetWriter has started. This property throws an exception if a value is set on an asset writer input that is contained in an input group.

func (*AVAssetWriterInput) MediaDataLocation ¶

func (o *AVAssetWriterInput) MediaDataLocation() *foundation.NSString

Specifies where the media data will be laid out and whether the media data will be interleaved as the main media data. If this value is set to AVAssetWriterInputMediaDataLocationBeforeMainMediaDataNotInterleaved, AVAssetWriter tries to write the media data for this track before all the media data for AVAssetWriterInputs with this property set to AVAssetWriterInputMediaDataLocationInterleavedWithMainMediaData. Use of this property is recommended for optimizing tracks that contain a small amount of data that is needed all at once, independent of playback time, such as chapter name tracks and chapter image tracks. Keep it set to AVAssetWriterInputMediaDataLocationInterleavedWithMainMediaData for tracks whose media data that's needed only as its presentation time is approaching and, when multiple inputs are present that supply media data that will be played concurrently, should be interleaved for optimal access. For file types that support preloading media data such as QuickTime movie file, if this value is set to AVAssetWriterInputMediaDataLocationBeforeMainMediaDataNotInterleaved, AVAssetWriter will write an indication such as 'load' atom that the whole media data should be preloaded. The default value is AVAssetWriterInputMediaDataLocationInterleavedWithMainMediaData, which means that the receiver will not write the indication and that the media data will be interleaved. This property cannot be set after -startWriting has been called on the receiver.

func (*AVAssetWriterInput) MediaTimeScale ¶

func (o *AVAssetWriterInput) MediaTimeScale() int32

For file types that support media time scales, such as QuickTime Movie files, specifies the media time scale to be used. The default value is 0, which indicates that the receiver should choose a convenient value, if applicable. It is an error to set a value other than 0 if the receiver has media type AVMediaTypeAudio. This property cannot be set after writing has started. This property throws an exception if a value is set on an asset writer input with media type AVMediaTypeAudio.

func (*AVAssetWriterInput) MediaType ¶

func (o *AVAssetWriterInput) MediaType() *foundation.NSString

The media type of the samples that can be appended to the receiver. The value of this property is one of the media types defined in AVMediaFormat.h.

func (*AVAssetWriterInput) Metadata ¶

A collection of metadata to be written to the track corresponding to the receiver. The value of this property is an array of AVMetadataItem objects representing the collection of track-level metadata to be written in the output file. This property cannot be set after writing on the receiver's AVAssetWriter has started.

func (*AVAssetWriterInput) NaturalSize ¶

func (o *AVAssetWriterInput) NaturalSize() corefoundation.CGSize

The size specified in the output file as the natural dimensions of the visual media data for display purposes. If the default value, CGSizeZero, is specified, the naturalSize of the track corresponding to the receiver is set according to dimensions indicated by the format descriptions that are ultimately written to the output track. This property cannot be set after writing on the receiver's AVAssetWriter has started.

func (*AVAssetWriterInput) OutputSettings ¶

The settings used for encoding the media appended to the output. The value of this property is an NSDictionary that contains values for keys as specified by either AVAudioSettings.h for AVMediaTypeAudio or AVVideoSettings.h for AVMediaTypeVideo. A value of nil indicates that the receiver will pass through appended samples, doing no processing before they are written to the output file.

func (*AVAssetWriterInput) PerformsMultiPassEncodingIfSupported ¶

func (o *AVAssetWriterInput) PerformsMultiPassEncodingIfSupported() bool

Indicates whether the input should attempt to encode the source media data using multiple passes. The input may be able to achieve higher quality and/or lower data rate by performing multiple passes over the source media. It does this by analyzing the media data that has been appended and re-encoding certain segments with different parameters. In order to do this re-encoding, the media data for these segments must be appended again. See -markCurrentPassAsFinished and the property currentPassDescription for the mechanism by which the input nominates segments for re-appending. When the value of this property is YES, the value of readyForMoreMediaData for other inputs attached to the same AVAssetWriter may be NO more often and/or for longer periods of time. In particular, the value of readyForMoreMediaData for inputs that do not (or cannot) perform multiple passes may start out as NO after -[AVAssetWriter startWriting] has been called and may not change to YES until after all multi-pass inputs have completed their final pass. When the value of this property is YES, the input may store data in one or more temporary files before writing compressed samples to the output file. Use the AVAssetWriter property directoryForTemporaryFiles if you need to control the location of temporary file writing. The default value is NO, meaning that no additional analysis will occur and no segments will be re-encoded. Not all asset writer input configurations (for example, inputs configured with certain media types or to use certain encoders) can benefit from performing multiple passes over the source media. To determine whether the selected encoder can perform multiple passes, query the value of canPerformMultiplePasses after calling -startWriting. For best results, do not set both this property and expectsMediaDataInRealTime to YES. This property cannot be set after writing on the receiver's AVAssetWriter has started.

func (*AVAssetWriterInput) PreferredMediaChunkAlignment ¶

func (o *AVAssetWriterInput) PreferredMediaChunkAlignment() int

For file types that support media chunk alignment, such as QuickTime Movie files, specifies the boundary for media chunk alignment in bytes (e.g. 512). The default value is 0, which means that the receiver will choose an appropriate default value. A value of 1 implies that no padding should be used to achieve a particular chunk alignment. It is an error to set a negative value for chunk alignment. This property cannot be set after -startWriting has been called on the receiver.

func (*AVAssetWriterInput) PreferredMediaChunkDuration ¶

func (o *AVAssetWriterInput) PreferredMediaChunkDuration() coremedia.CMTime

For file types that support media chunk duration, such as QuickTime Movie files, specifies the duration to be used for each chunk of sample data in the output file. Chunk duration can influence the granularity of the I/O performed when reading a media file, e.g. during playback. A larger chunk duration can result in fewer reads from disk, at the potential expense of a higher memory footprint. A "chunk" contains one or more samples. The total duration of the samples in a chunk is no greater than this preferred chunk duration, or the duration of a single sample if the sample's duration is greater than this preferred chunk duration. The default value is kCMTimeInvalid, which means that the receiver will choose an appropriate default value. This property cannot be set after -startWriting has been called on the receiver. This property throws an exception if a duration is set which is non-numeric or non-positive (see CMTIME_IS_NUMERIC).

func (*AVAssetWriterInput) PreferredVolume ¶

func (o *AVAssetWriterInput) PreferredVolume() float32

func (*AVAssetWriterInput) RequestMediaDataWhenReadyOnQueueUsing ¶

func (o *AVAssetWriterInput) RequestMediaDataWhenReadyOnQueueUsing(queue *foundation.NSObject, block func())

Instructs the receiver to invoke a client-supplied block repeatedly, at its convenience, in order to gather media data for writing to the output file. The block should append media data to the input either until the input's readyForMoreMediaData property becomes NO or until there is no more media data to supply (at which point it may choose to mark the input as finished via -markAsFinished). The block should then exit. After the block exits, if the input has not been marked as finished, once the input has processed the media data it has received and becomes ready for more media data again, it will invoke the block again in order to obtain more. A typical use of this method, with a block that supplies media data to an input while respecting the input's readyForMoreMediaData property, might look like this: ```objc [myAVAssetWriterInput requestMediaDataWhenReadyOnQueue:myInputSerialQueue usingBlock:^{ while ([myAVAssetWriterInput isReadyForMoreMediaData]) { CMSampleBufferRef nextSampleBuffer = [self copyNextSampleBufferToWrite]; if (nextSampleBuffer) { [myAVAssetWriterInput appendSampleBuffer:nextSampleBuffer]; CFRelease(nextSampleBuffer); } else { [myAVAssetWriterInput markAsFinished]; break; } } }]; ``` This method is not recommended for use with a push-style buffer source, such as AVCaptureAudioDataOutput or AVCaptureVideoDataOutput, because such a combination will likely require intermediate queueing of buffers. Instead, this method is better suited to a pull-style buffer source such as AVAssetReaderOutput, as illustrated in the above example. When using a push-style buffer source, it is generally better to immediately append each buffer to the AVAssetWriterInput, directly via -[AVAssetWriter appendSampleBuffer:], as it is received. Using this strategy, it is often possible to avoid having to queue up buffers in between the buffer source and the AVAssetWriterInput. Note that many of these push-style buffer sources also produce buffers in real-time, in which case the client should set expectsMediaDataInRealTime to YES. Before calling this method, you must ensure that the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer. This method throws an exception if this method is called more than once. - Parameter queue: The queue on which the block should be invoked. - Parameter block: The block the input should invoke to obtain media data.

func (*AVAssetWriterInput) RespondToEachPassDescriptionOnQueueUsing ¶

func (o *AVAssetWriterInput) RespondToEachPassDescriptionOnQueueUsing(queue *foundation.NSObject, block func())

Instructs the receiver to invoke a client-supplied block whenever a new pass has begun. A typical block passed to this method will perform the following steps: 1. Query the value of the receiver's currentPassDescription property and reconfigure the source of media data (e.g. AVAssetReader) accordingly 2. Call -requestMediaDataWhenReadyOnQueue:usingBlock: to begin appending data for the current pass 3. Exit When all media data has been appended for the current request, call -markCurrentPassAsFinished to begin the process of determining whether an additional pass is warranted. If an additional pass is warranted, the block passed to this method will be invoked to begin the next pass. If no additional passes are needed, the block passed to this method will be invoked one final time so the client can invoke -markAsFinished in response to the value of currentPassDescription becoming nil. Before calling this method, you must ensure that the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer. This method throws an exception if called more than once. - Parameter queue: The queue on which the block should be invoked. - Parameter block: A block the receiver should invoke whenever a new pass has begun.

func (*AVAssetWriterInput) SampleReferenceBaseURL ¶

func (o *AVAssetWriterInput) SampleReferenceBaseURL() *foundation.NSURL

For file types that support writing sample references, such as QuickTime Movie files, specifies the base URL sample references are relative to. If the value of this property can be resolved as an absolute URL, the sample locations written to the file when appending sample references will be relative to this URL. The URL must point to a location that is in a directory that is a parent of the sample reference location. Usage example: Setting the sampleReferenceBaseURL property to "file:///User/johnappleseed/Movies/" and appending sample buffers with the kCMSampleBufferAttachmentKey_SampleReferenceURL attachment set to "file:///User/johnappleseed/Movies/data/movie1.mov" will cause the sample reference "data/movie1.mov" to be written to the movie. If the value of the property cannot be resolved as an absolute URL or if it points to a location that is not in a parent directory of the sample reference location, the location referenced in the sample buffer will be written unmodified. The default value is nil, which means that the location referenced in the sample buffer will be written unmodified. This property cannot be set after -startWriting has been called on the receiver.

func (*AVAssetWriterInput) SetExpectsMediaDataInRealTime ¶

func (o *AVAssetWriterInput) SetExpectsMediaDataInRealTime(expectsMediaDataInRealTime bool)

Indicates whether the input should tailor its processing of media data for real-time sources. Clients appending media data to an input from a real-time source, such as an AVCaptureOutput, should set expectsMediaDataInRealTime to YES. This will ensure that readyForMoreMediaData is calculated appropriately for real-time usage. For best results, do not set both this property and performsMultiPassEncodingIfSupported to YES. This property cannot be set after writing on the receiver's AVAssetWriter has started.

func (*AVAssetWriterInput) SetExtendedLanguageTag ¶

func (o *AVAssetWriterInput) SetExtendedLanguageTag(extendedLanguageTag *foundation.NSString)

func (*AVAssetWriterInput) SetLanguageCode ¶

func (o *AVAssetWriterInput) SetLanguageCode(languageCode *foundation.NSString)

func (*AVAssetWriterInput) SetMarksOutputTrackAsEnabled ¶

func (o *AVAssetWriterInput) SetMarksOutputTrackAsEnabled(marksOutputTrackAsEnabled bool)

func (*AVAssetWriterInput) SetMediaDataLocation ¶

func (o *AVAssetWriterInput) SetMediaDataLocation(mediaDataLocation *foundation.NSString)

func (*AVAssetWriterInput) SetMediaTimeScale ¶

func (o *AVAssetWriterInput) SetMediaTimeScale(mediaTimeScale int32)

func (*AVAssetWriterInput) SetMetadata ¶

func (o *AVAssetWriterInput) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVAssetWriterInput) SetNaturalSize ¶

func (o *AVAssetWriterInput) SetNaturalSize(naturalSize corefoundation.CGSize)

func (*AVAssetWriterInput) SetPerformsMultiPassEncodingIfSupported ¶

func (o *AVAssetWriterInput) SetPerformsMultiPassEncodingIfSupported(performsMultiPassEncodingIfSupported bool)

func (*AVAssetWriterInput) SetPreferredMediaChunkAlignment ¶

func (o *AVAssetWriterInput) SetPreferredMediaChunkAlignment(preferredMediaChunkAlignment int)

func (*AVAssetWriterInput) SetPreferredMediaChunkDuration ¶

func (o *AVAssetWriterInput) SetPreferredMediaChunkDuration(preferredMediaChunkDuration coremedia.CMTime)

func (*AVAssetWriterInput) SetPreferredVolume ¶

func (o *AVAssetWriterInput) SetPreferredVolume(preferredVolume float32)

func (*AVAssetWriterInput) SetSampleReferenceBaseURL ¶

func (o *AVAssetWriterInput) SetSampleReferenceBaseURL(sampleReferenceBaseURL *foundation.NSURL)

func (*AVAssetWriterInput) SetTransform ¶

func (o *AVAssetWriterInput) SetTransform(transform corefoundation.CGAffineTransform)

func (*AVAssetWriterInput) SourceFormatHint ¶

func (o *AVAssetWriterInput) SourceFormatHint() unsafe.Pointer

The hint given at initialization time about the format of incoming media data. AVAssetWriterInput may be able to use this hint to fill in missing output settings or perform more upfront validation. To guarantee successful file writing, clients who specify a format hint should ensure that subsequently-appended media data are of the specified format.

func (*AVAssetWriterInput) Transform ¶

The transform specified in the output file as the preferred transformation of the visual media data for display purposes. If no value is specified, the identity transform is used. This property cannot be set after writing on the receiver's AVAssetWriter has started.

type AVAssetWriterInputCaptionAdaptor ¶

type AVAssetWriterInputCaptionAdaptor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinputcaptionadaptor

func AVAssetWriterInputCaptionAdaptorAssetWriterInputCaptionAdaptorWithAssetWriterInput ¶

func AVAssetWriterInputCaptionAdaptorAssetWriterInputCaptionAdaptorWithAssetWriterInput(input *AVAssetWriterInput) *AVAssetWriterInputCaptionAdaptor

Creates a new caption adaptor for writing to the specified asset writer input.

func AVAssetWriterInputCaptionAdaptorFromID ¶

func AVAssetWriterInputCaptionAdaptorFromID(id objc.ID) *AVAssetWriterInputCaptionAdaptor

func (*AVAssetWriterInputCaptionAdaptor) AppendCaption ¶

func (o *AVAssetWriterInputCaptionAdaptor) AppendCaption(caption *AVCaption) bool

Append a single caption to be written. If this method returns NO, check the value of AVAssetWriter.status on the attached asset writer to determine why appending failed. The start time of each caption's timeRange property must be numeric (see CMTIME_IS_NUMERIC) and must be at least as large as the start time of any previous caption (including any captions present in a group appended via -appendCaptionGroup:). In other words, the sequence of captions appended using this method must have monotonically increasing start times. The duration of each caption's timeRange property must be numeric. - Parameter caption: The caption to append. - Returns: Returns YES if the operation succeeded, NO if it failed.

func (*AVAssetWriterInputCaptionAdaptor) AppendCaptionGroup ¶

func (o *AVAssetWriterInputCaptionAdaptor) AppendCaptionGroup(captionGroup *AVCaptionGroup) bool

Append a group of captions to be written. If this method returns NO, check the value of AVAssetWriter.status on the attached asset writer to determine why appending failed. When appending a sequence of captions groups, the start time of each group must be equal to or greater than the end time of any previous group. The easiest way to achieve this is to create the group using a caption whose duration is kCMTimeInvalid, in which case the duration will be determined by subtracting the start time of the group from the start time of the next appended group. When mixing calls to -appendCaptionGroup: and -appendCaption:, the start time of each group must be equal to or greater than the end time of any previous captions. To mark a time range containing no captions, append a group containing an empty caption array. - Parameter captionGroup: - Returns: Returns YES if the operation succeeded, NO if it failed.

func (*AVAssetWriterInputCaptionAdaptor) AssetWriterInput ¶

The asset writer input that was used to initialize the receiver.

func (*AVAssetWriterInputCaptionAdaptor) InitWithAssetWriterInput ¶

Creates a new caption adaptor for writing to the specified asset writer input. This method thows an exception for any of the following reasons: - input is nil - the input's media type is not supported (should use text or closed caption) - the input is already attached to an asset writer caption adaptor - the input has already started writing

type AVAssetWriterInputGroup ¶

type AVAssetWriterInputGroup struct {
	AVMediaSelectionGroup
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinputgroup

func AVAssetWriterInputGroupAssetWriterInputGroupWithInputsDefaultInput ¶

func AVAssetWriterInputGroupAssetWriterInputGroupWithInputsDefaultInput(inputs *foundation.NSArray[*AVAssetWriterInput], defaultInput *AVAssetWriterInput) *AVAssetWriterInputGroup

func AVAssetWriterInputGroupFromID ¶

func AVAssetWriterInputGroupFromID(id objc.ID) *AVAssetWriterInputGroup

func (*AVAssetWriterInputGroup) DefaultInput ¶

func (o *AVAssetWriterInputGroup) DefaultInput() *AVAssetWriterInput

@property defaultInput @abstract The input designated at the defaultInput of the receiver. @discussion The value of this property is a concrete instance of AVAssetWriterInput.

func (*AVAssetWriterInputGroup) InitWithInputsDefaultInput ¶

func (o *AVAssetWriterInputGroup) InitWithInputsDefaultInput(inputs *foundation.NSArray[*AVAssetWriterInput], defaultInput *AVAssetWriterInput) *AVAssetWriterInputGroup

func (*AVAssetWriterInputGroup) Inputs ¶

@property inputs @abstract The inputs grouped together by the receiver. @discussion The value of this property is an NSArray containing concrete instances of AVAssetWriterInput.

type AVAssetWriterInputMetadataAdaptor ¶

type AVAssetWriterInputMetadataAdaptor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinputmetadataadaptor

func AVAssetWriterInputMetadataAdaptorAssetWriterInputMetadataAdaptorWithAssetWriterInput ¶

func AVAssetWriterInputMetadataAdaptorAssetWriterInputMetadataAdaptorWithAssetWriterInput(input *AVAssetWriterInput) *AVAssetWriterInputMetadataAdaptor

Creates a new timed metadata group adaptor to receive instances of AVTimedMetadataGroup for writing to the output file. The instance of AVAssetWriterInput passed in to this method must have been created with a format hint indicating all possible combinations of identifier (or, alternatively, key and keySpace), dataType, and extendedLanguageTag that will be appended to the metadata adaptor. It is an error to append metadata items not represented in the input's format hint. This method throws an exception for any of the following reasons: - input is already attached to another instance of AVAssetWriterInputMetadataAdaptor - input's asset writer has already started writing (progressed beyond AVAssetWriterStatusUnknown) - input's asset writer does not carry a source format hint - input's source format hint media subtype is not kCMMetadataFormatType_Boxed - Parameter input: An instance of AVAssetWriterInput to which the receiver should append groups of timed metadata. Only asset writer inputs that accept media data of type AVMediaTypeMetadata can be used to initialize a timed metadata group adaptor. - Returns: An instance of AVAssetWriterInputMetadataAdaptor.

func AVAssetWriterInputMetadataAdaptorFromID ¶

func AVAssetWriterInputMetadataAdaptorFromID(id objc.ID) *AVAssetWriterInputMetadataAdaptor

func (*AVAssetWriterInputMetadataAdaptor) AppendTimedMetadataGroup ¶

func (o *AVAssetWriterInputMetadataAdaptor) AppendTimedMetadataGroup(timedMetadataGroup *AVTimedMetadataGroup) bool

Appends a timed metadata group to the receiver. The receiver will retain the AVTimedMetadataGroup until it is done with it, and then release it. The timing of the metadata items in the output asset will correspond to the timeRange of the AVTimedMetadataGroup, regardless of the values of the time and duration properties of the individual items. Before calling this method, you must ensure that the input that underlies the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer. It is an error to invoke this method before starting a session (via -[AVAssetWriter startSessionAtSourceTime:]) or after ending a session (via -[AVAssetWriter endSessionAtSourceTime:]). This method throws an exception if the attached asset writer input has not been added to an asset writer or -startWriting has not been called on that asset writer. - Parameter timedMetadataGroup: The AVTimedMetadataGroup to be appended. - Returns: A BOOL value indicating success of appending the timed metadata group. If a result of NO is returned, AVAssetWriter.error will contain more information about why apending the timed metadata group failed.

func (*AVAssetWriterInputMetadataAdaptor) AssetWriterInput ¶

The asset writer input to which the receiver should append timed metadata groups.

func (*AVAssetWriterInputMetadataAdaptor) InitWithAssetWriterInput ¶

Creates a new timed metadator group adaptor to receive instances of AVTimedMetadataGroup for writing to the output file. The instance of AVAssetWriterInput passed in to this method must have been created with a format hint indicating all possible combinations of identifier (or, alternatively, key and keySpace), dataType, and extendedLanguageTag that will be appended to the metadata adaptor. It is an error to append metadata items not represented in the input's format hint. For help creating a suitable format hint, see -[AVTimedMetadataGroup copyFormatDescription]. This method throws an exception for any of the following reasons: - input is already attached to another instance of AVAssetWriterInputMetadataAdaptor - input's asset writer has already started writing (progressed beyond AVAssetWriterStatusUnknown) - input's asset writer does not carry a source format hint - input's source format hint media subtype is not kCMMetadataFormatType_Boxed - Parameter input: An instance of AVAssetWriterInput to which the receiver should append groups of timed metadata. Only asset writer inputs that accept media data of type AVMediaTypeMetadata can be used to initialize a timed metadata group adaptor. - Returns: An instance of AVAssetWriterInputMetadataAdaptor.

type AVAssetWriterInputPassDescription ¶

type AVAssetWriterInputPassDescription struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinputpassdescription

func AVAssetWriterInputPassDescriptionFromID ¶

func AVAssetWriterInputPassDescriptionFromID(id objc.ID) *AVAssetWriterInputPassDescription

func (*AVAssetWriterInputPassDescription) SourceTimeRanges ¶

type AVAssetWriterInputPixelBufferAdaptor ¶

type AVAssetWriterInputPixelBufferAdaptor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinputpixelbufferadaptor

func AVAssetWriterInputPixelBufferAdaptorAssetWriterInputPixelBufferAdaptorWithAssetWriterInputSourcePixelBufferAttributes ¶

func AVAssetWriterInputPixelBufferAdaptorAssetWriterInputPixelBufferAdaptorWithAssetWriterInputSourcePixelBufferAttributes(input *AVAssetWriterInput, sourcePixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetWriterInputPixelBufferAdaptor

Creates a new pixel buffer adaptor to receive pixel buffers for writing to the output file. In order to take advantage of the improved efficiency of appending buffers created from the adaptor's pixel buffer pool, clients should specify pixel buffer attributes that most closely accommodate the source format of the video frames being appended. Pixel buffer attributes keys for the pixel buffer pool are defined in <CoreVideo/CVPixelBuffer.h>. To specify the pixel format type, the pixelBufferAttributes dictionary should contain a value for kCVPixelBufferPixelFormatTypeKey. For example, use [NSNumber numberWithInt:kCVPixelFormatType_32BGRA] for 8-bit-per-channel BGRA. See the discussion under appendPixelBuffer:withPresentationTime: for advice on choosing a pixel format. Clients that do not need a pixel buffer pool for allocating buffers should set sourcePixelBufferAttributes to nil. This method throws an exception if the input is already attached to another asset writer input pixel buffer adaptor or if the input has already started writing (the asset writer has progressed beyond AVAssetWriterStatusUnknown). - Parameter input: An instance of AVAssetWriterInput to which the receiver should append pixel buffers. Currently, only asset writer inputs that accept media data of type AVMediaTypeVideo can be used to initialize a pixel buffer adaptor. - Parameter sourcePixelBufferAttributes: Specifies the attributes of pixel buffers that will be vended by the input's CVPixelBufferPool. - Returns: An instance of AVAssetWriterInputPixelBufferAdaptor.

func AVAssetWriterInputPixelBufferAdaptorFromID ¶

func AVAssetWriterInputPixelBufferAdaptorFromID(id objc.ID) *AVAssetWriterInputPixelBufferAdaptor

func (*AVAssetWriterInputPixelBufferAdaptor) AppendPixelBufferWithPresentationTime ¶

func (o *AVAssetWriterInputPixelBufferAdaptor) AppendPixelBufferWithPresentationTime(pixelBuffer unsafe.Pointer, presentationTime coremedia.CMTime) bool

Appends a pixel buffer to the receiver. The receiver will retain the CVPixelBuffer until it is done with it, and then release it. Do not modify a CVPixelBuffer or its contents after you have passed it to this method. For optimal performance the format of the pixel buffer should match one of the native formats supported by the selected video encoder. Below are some recommendations: The H.264 and HEVC encoders natively support kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange and kCVPixelFormatType_420YpCbCr8BiPlanarFullRange, which should be used with 8-bit 4:2:0 video and full range input respectively; other related pixel formats in CoreVideo/CVPixelBuffer.h are ideal for 4:2:2 and 4:4:4 (and for HEVC, 10-bit). The JPEG encoder on iOS and Apple Silicon macOS natively supports kCVPixelFormatType_422YpCbCr8FullRange. If you need to work in the RGB domain then kCVPixelFormatType_32BGRA is recommended on iOS and macOS. Pixel buffers not in a natively supported format will be converted internally prior to encoding when possible. Pixel format conversions within the same range (video or full) are generally faster than conversions between different ranges. The ProRes encoders can preserve high bit depth sources, supporting up to 12bits/ch. ProRes 4444 can contain a mathematically lossless alpha channel and it doesn't do any chroma subsampling. This makes ProRes 4444 ideal for quality critical applications. If you are working with 8bit sources ProRes is also a good format to use due to its high image quality. Use either of the recommended pixel formats above. Note that RGB pixel formats by definition have 4:4:4 chroma sampling. If you are working with high bit depth sources the following yuv pixel formats are recommended when encoding to ProRes: kCVPixelFormatType_4444AYpCbCr16, kCVPixelFormatType_422YpCbCr16, and kCVPixelFormatType_422YpCbCr10. When working in the RGB domain kCVPixelFormatType_64ARGB is recommended. Scaling and color matching are not currently supported when using AVAssetWriter with any of these high bit depth pixel formats. Please make sure that your track's output settings dictionary specifies the same width and height as the buffers you will be appending. Do not include AVVideoScalingModeKey or AVVideoColorPropertiesKey. Before calling this method, you must ensure that the input that underlies the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer. It is an error to invoke this method before starting a session (via -[AVAssetWriter startSessionAtSourceTime:]) or after ending a session (via -[AVAssetWriter endSessionAtSourceTime:]). This method throws an exception if the presentation time is is non-numeric (see CMTIME_IS_NUMERIC) or if "readyForMoreMediaData" is NO. - Parameter pixelBuffer: The CVPixelBuffer to be appended. - Parameter presentationTime: The presentation time for the pixel buffer to be appended. This time will be considered relative to the time passed to -[AVAssetWriter startSessionAtSourceTime:] to determine the timing of the frame in the output file. - Returns: A BOOL value indicating success of appending the pixel buffer. If a result of NO is returned, clients can check the value of AVAssetWriter.status to determine whether the writing operation completed, failed, or was cancelled. If the status is AVAssetWriterStatusFailed, AVAsset.error will contain an instance of NSError that describes the failure.

func (*AVAssetWriterInputPixelBufferAdaptor) AssetWriterInput ¶

The asset writer input to which the receiver should append pixel buffers.

func (*AVAssetWriterInputPixelBufferAdaptor) InitWithAssetWriterInputSourcePixelBufferAttributes ¶

func (o *AVAssetWriterInputPixelBufferAdaptor) InitWithAssetWriterInputSourcePixelBufferAttributes(input *AVAssetWriterInput, sourcePixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetWriterInputPixelBufferAdaptor

Creates a new pixel buffer adaptor to receive pixel buffers for writing to the output file. In order to take advantage of the improved efficiency of appending buffers created from the adaptor's pixel buffer pool, clients should specify pixel buffer attributes that most closely accommodate the source format of the video frames being appended. Pixel buffer attributes keys for the pixel buffer pool are defined in <CoreVideo/CVPixelBuffer.h>. To specify the pixel format type, the pixelBufferAttributes dictionary should contain a value for kCVPixelBufferPixelFormatTypeKey. For example, use [NSNumber numberWithInt:kCVPixelFormatType_32BGRA] for 8-bit-per-channel BGRA. See the discussion under appendPixelBuffer:withPresentationTime: for advice on choosing a pixel format. Clients that do not need a pixel buffer pool for allocating buffers should set sourcePixelBufferAttributes to nil. This method throws an exception if the input is already attached to another asset writer input pixel buffer adaptor or if the input has already started writing (the asset writer has progressed beyond AVAssetWriterStatusUnknown). - Parameter input: An instance of AVAssetWriterInput to which the receiver should append pixel buffers. Currently, only asset writer inputs that accept media data of type AVMediaTypeVideo can be used to initialize a pixel buffer adaptor. - Parameter sourcePixelBufferAttributes: Specifies the attributes of pixel buffers that will be vended by the input's CVPixelBufferPool. - Returns: An instance of AVAssetWriterInputPixelBufferAdaptor.

func (*AVAssetWriterInputPixelBufferAdaptor) PixelBufferPool ¶

A pixel buffer pool that will vend and efficiently recycle CVPixelBuffer objects that can be appended to the receiver. For maximum efficiency, clients should create CVPixelBuffer objects for appendPixelBuffer:withPresentationTime: by using this pool with the CVPixelBufferPoolCreatePixelBuffer() function. The value of this property will be NULL before -[AVAssetWriter startWriting] is called on the associated AVAssetWriter object. This property is key value observable. This property throws an exception if a pixel buffer pool cannot be created with this asset writer input pixel buffer adaptor's source pixel buffer attributes (must specify width, height, and either pixel format or pixel format description).

func (*AVAssetWriterInputPixelBufferAdaptor) SourcePixelBufferAttributes ¶

The pixel buffer attributes of pixel buffers that will be vended by the receiver's CVPixelBufferPool. The value of this property is a dictionary containing pixel buffer attributes keys defined in <CoreVideo/CVPixelBuffer.h>.

type AVAssetWriterInputTaggedPixelBufferGroupAdaptor ¶

type AVAssetWriterInputTaggedPixelBufferGroupAdaptor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avassetwriterinputtaggedpixelbuffergroupadaptor

func AVAssetWriterInputTaggedPixelBufferGroupAdaptorAssetWriterInputTaggedPixelBufferGroupAdaptorWithAssetWriterInputSourcePixelBufferAttributes ¶

func AVAssetWriterInputTaggedPixelBufferGroupAdaptorAssetWriterInputTaggedPixelBufferGroupAdaptorWithAssetWriterInputSourcePixelBufferAttributes(input *AVAssetWriterInput, sourcePixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetWriterInputTaggedPixelBufferGroupAdaptor

Creates a new tagged buffer adaptor to receive tagged buffer groups for writing to the output file. In order to take advantage of the improved efficiency of appending buffers created from the adaptor's pixel buffer pool, clients should specify pixel buffer attributes that most closely accommodate the source format of the video frames being appended. Pixel buffer attributes keys for the pixel buffer pool are defined in <CoreVideo/CVPixelBuffer.h>. To specify the pixel format type, the pixelBufferAttributes dictionary should contain a value for kCVPixelBufferPixelFormatTypeKey. For example, use [NSNumber numberWithInt:kCVPixelFormatType_32BGRA] for 8-bit-per-channel BGRA. See the discussion under appendPixelBuffer:withPresentationTime: for advice on choosing a pixel format. Clients that do not need a pixel buffer pool for allocating buffers should set sourcePixelBufferAttributes to nil. This method throws an exception if the input is already attached to another asset writer input tagged buffer group adaptor or if the input has already started writing (the asset writer has progressed beyond AVAssetWriterStatusUnknown). - Parameter input: An instance of AVAssetWriterInput to which the receiver should append tagged buffer groups. Currently, only asset writer inputs that accept media data of type AVMediaTypeVideo can be used to initialize a tagged buffer adaptor. - Parameter sourcePixelBufferAttributes: Specifies the attributes of pixel buffers of tagged buffer groups that will be vended by the input's CVPixelBufferPool. - Returns: An instance of AVAssetWriterInputTaggedPixelBufferGroupAdaptor.

func AVAssetWriterInputTaggedPixelBufferGroupAdaptorFromID ¶

func AVAssetWriterInputTaggedPixelBufferGroupAdaptorFromID(id objc.ID) *AVAssetWriterInputTaggedPixelBufferGroupAdaptor

func (*AVAssetWriterInputTaggedPixelBufferGroupAdaptor) AppendTaggedPixelBufferGroupWithPresentationTime ¶

func (o *AVAssetWriterInputTaggedPixelBufferGroupAdaptor) AppendTaggedPixelBufferGroupWithPresentationTime(taggedPixelBufferGroup unsafe.Pointer, presentationTime coremedia.CMTime) bool

Appends a tagged buffer group to the receiver. The receiver will retain the CMTaggedBufferGroup until it is done with it, and then release it. Do not modify a CMTaggedBufferGroup or its contents after you have passed it to this method. Before calling this method, you must ensure that the input that underlies the receiver is attached to an AVAssetWriter via a prior call to -addInput: and that -startWriting has been called on the asset writer. It is an error to invoke this method before starting a session (via -[AVAssetWriter startSessionAtSourceTime:]) or after ending a session (via -[AVAssetWriter endSessionAtSourceTime:]). In an AVAssetWriterInput instance creation with AVMediaTypeVideo, kVTCompressionPropertyKey_MVHEVCVideoLayerIDs key must be specified as part of the dictionary given for AVVideoCompressionPropertiesKey. It sets video layer IDs to a target multi-image video encoder. This method checks the values for kCMTagCategory_VideoLayerID tag in tag collections of taggedPixelBufferGroup over the array values for kVTCompressionPropertyKey_MVHEVCVideoLayerIDs key. An NSInvalidArgumentException will be raised if the video layer IDs mismatch between the value of kVTCompressionPropertyKey_MVHEVCVideoLayerIDs in the AVVideoCompressionPropertiesKey sub-dictionary of the input's outputSettings property and tag collections of taggedPixelBufferGroup. Below is a sample code sketch focusing on data flow that illustrates how you might append a taggedPixelBufferGroup instance. ```objc // Set up an AVAssetWriterInput and AVAssetWriterInputTaggedPixelBufferGroupAdaptor instance AVAssetWriterInput *assetWriterInput = [[AVAssetWriterInput alloc] initWithMediaType:AVMediaTypeVideo outputSettings:@{ .., AVVideoCompressionPropertiesKey: @{ (NSString *)kVTCompressionPropertyKey_MVHEVCVideoLayerIDs : .. }}]; AVAssetWriterInputTaggedPixelBufferGroupAdaptor *assetWriterInputAdaptor = [[AVAssetWriterInputTaggedPixelBufferGroupAdaptor alloc] initWithAssetWriterInput:assetWriterInput ..]; ``` Later, when the writer input is ready for more media data, create and append a tagged buffer group containing one or more pixel buffers and the exact tag values associated with kCMTagCategory_VideoLayerID being specified via kVTCompressionPropertyKey_MVHEVCVideoLayerIDs. ```objc // Set up tag collection buffers CMTag tags[] = CMTagMakeWithSInt64Value(kCMTagCategory_VideoLayerID, ..); CMItemCount tagCount = sizeof(tags) / sizeof(tags[0]); CMTagCollectionCreate(.., tags, tagCount, &tagCollection); CFArrayAppendValue(tagCollectionArray, tagCollection); // Set up pixel buffers CVPixelBufferPoolCreatePixelBuffer(.., &pixelBuffer); CFArrayAppendValue(pixelBufferArray, pixelBuffer); // Append a CMTaggedBufferGroupRef instance to asset writer input CMTaggedBufferGroupCreate(.., tagCollectionArray, pixelBufferArray, &taggedBufferGroup); [assetWriterInputAdaptor appendTaggedPixelBufferGroup:taggedBufferGroup ..]; ``` - Parameter taggedPixelBufferGroup: The CMTaggedBufferGroup to be appended. All of the buffers in taggedPixelBufferGroup should be CVPixelBuffers, and they should correspond to tag collections that contain kCMTagCategory_VideoLayerID values matching the list set using kVTCompressionPropertyKey_MVHEVCVideoLayerIDs. The pixel buffers should be IOSurface-backed. - Parameter presentationTime: The presentation time for the tagged buffer group to be appended. This time will be considered relative to the time passed to -[AVAssetWriter startSessionAtSourceTime:] to determine the timing of the frame in the output file. - Returns: A BOOL value indicating success of appending the tagged buffer group. If a result of NO is returned, clients can check the value of AVAssetWriter.status to determine whether the writing operation completed, failed, or was cancelled. If the status is AVAssetWriterStatusFailed, AVAssetWriter.error will contain an instance of NSError that describes the failure.

func (*AVAssetWriterInputTaggedPixelBufferGroupAdaptor) AssetWriterInput ¶

The asset writer input to which the receiver should append tagged buffer groups.

func (*AVAssetWriterInputTaggedPixelBufferGroupAdaptor) InitWithAssetWriterInputSourcePixelBufferAttributes ¶

func (o *AVAssetWriterInputTaggedPixelBufferGroupAdaptor) InitWithAssetWriterInputSourcePixelBufferAttributes(input *AVAssetWriterInput, sourcePixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVAssetWriterInputTaggedPixelBufferGroupAdaptor

Creates a new tagged buffer group adaptor to receive tagged buffer groups for writing to the output file. In order to take advantage of the improved efficiency of appending buffers created from the adaptor's pixel buffer pool, clients should specify pixel buffer attributes that most closely accommodate the source format of the video frames of tagged buffer groups being appended. Pixel buffer attributes keys for the pixel buffer pool are defined in <CoreVideo/CVPixelBuffer.h>. To specify the pixel format type, the pixelBufferAttributes dictionary should contain a value for kCVPixelBufferPixelFormatTypeKey. For example, use [NSNumber numberWithInt:kCVPixelFormatType_32BGRA] for 8-bit-per-channel BGRA. See the discussion under appendPixelBuffer:withPresentationTime: in AVAssetWriterInputPixelBufferAdaptor for advice on choosing a pixel format. Clients that do not need a pixel buffer pool for allocating buffers should set sourcePixelBufferAttributes to nil. It is an error to initialize an instance of AVAssetWriterInputTaggedPixelBufferGroupAdaptor with an asset writer input that is already attached to another instance of AVAssetWriterInputTaggedPixelBufferGroupAdaptor. It is also an error to initialize an instance of AVAssetWriterInputTaggedPixelBufferGroupAdaptor with an asset writer input whose asset writer has progressed beyond AVAssetWriterStatusUnknown. - Parameter input: An instance of AVAssetWriterInput to which the receiver should append tagged buffer groups. In addition to the pixel buffer adaptor, asset writer inputs with media data of type AVMediaTypeVideo can be used to initialize a tagged buffer group adaptor. - Parameter sourcePixelBufferAttributes: Specifies the attributes of pixel buffers of tagged buffer groups that will be vended by the input's CVPixelBufferPool. - Returns: An instance of AVAssetWriterInputTaggedPixelBufferGroupAdaptor.

func (*AVAssetWriterInputTaggedPixelBufferGroupAdaptor) PixelBufferPool ¶

A pixel buffer pool that will vend and efficiently recycle CVPixelBuffer objects of tagged buffer groups that can be appended to the receiver. For maximum efficiency, clients should create CVPixelBuffer objects of tagged buffer groups for appendTaggedPixelBufferGroup:withPresentationTime: by using this pool with the CVPixelBufferPoolCreatePixelBuffer() function. The value of this property will be NULL before -[AVAssetWriter startWriting] is called on the associated AVAssetWriter object. Clients should read this property after -[AVAssetWriter startWriting] calling to get a non-NULL value. This property is not key value observable.

func (*AVAssetWriterInputTaggedPixelBufferGroupAdaptor) SourcePixelBufferAttributes ¶

The pixel buffer attributes of pixel buffers that will be vended by the receiver's CVPixelBufferPool. The value of this property is a dictionary containing pixel buffer attributes keys defined in <CoreVideo/CVPixelBuffer.h>.

type AVAssetWriterStatus ¶

type AVAssetWriterStatus int64
const (
	AVAssetWriterStatusUnknown   AVAssetWriterStatus = 0
	AVAssetWriterStatusWriting   AVAssetWriterStatus = 1
	AVAssetWriterStatusCompleted AVAssetWriterStatus = 2
	AVAssetWriterStatusFailed    AVAssetWriterStatus = 3
	AVAssetWriterStatusCancelled AVAssetWriterStatus = 4
)

func (AVAssetWriterStatus) String ¶

func (e AVAssetWriterStatus) String() string

type AVAsynchronousCIImageFilteringRequest ¶

type AVAsynchronousCIImageFilteringRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avasynchronousciimagefilteringrequest

func AVAsynchronousCIImageFilteringRequestFromID ¶

func AVAsynchronousCIImageFilteringRequestFromID(id objc.ID) *AVAsynchronousCIImageFilteringRequest

func (*AVAsynchronousCIImageFilteringRequest) CompositionTime ¶

The time for which the frame should be filtered

func (*AVAsynchronousCIImageFilteringRequest) FinishWithError ¶

func (o *AVAsynchronousCIImageFilteringRequest) FinishWithError(error_ unsafe.Pointer)

Callback the filter should call when filtering failed. The error parameter should describe the actual error.

func (*AVAsynchronousCIImageFilteringRequest) FinishWithImageContext ¶

func (o *AVAsynchronousCIImageFilteringRequest) FinishWithImageContext(filteredImage objc.ID, context_ objc.ID)

Callback the filter should call when filtering succeeded. If context is nil then a default context will be used, GPU-accelerated if possible. It is safe to pass in the sourceImage in which case the filter will appear to have no effect, essentially functioning as a pass-through.

func (*AVAsynchronousCIImageFilteringRequest) RenderSize ¶

Width and height for rendering frames.

func (*AVAsynchronousCIImageFilteringRequest) SourceImage ¶

CIImage for the first enabled source video track. Unlike AVAsynchronousVideoCompositionRequest, renderContext.renderTransform is already applied to the source image.

type AVAsynchronousKeyValueLoading ¶

type AVAsynchronousKeyValueLoading interface {
	StatusOfValueForKeyError(key *foundation.NSString) (AVKeyValueStatus, error)
	LoadValuesAsynchronouslyForKeysCompletionHandler(keys *foundation.NSArray[*foundation.NSString], handler func())
}

AVAsynchronousKeyValueLoading wraps the ObjC protocol AVAsynchronousKeyValueLoading.

type AVAsynchronousVideoCompositionRequest ¶

type AVAsynchronousVideoCompositionRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avasynchronousvideocompositionrequest

func AVAsynchronousVideoCompositionRequestFromID ¶

func AVAsynchronousVideoCompositionRequestFromID(id objc.ID) *AVAsynchronousVideoCompositionRequest

func (*AVAsynchronousVideoCompositionRequest) AttachSpatialVideoConfigurationToPixelBuffer ¶

func (o *AVAsynchronousVideoCompositionRequest) AttachSpatialVideoConfigurationToPixelBuffer(spatialVideoConfiguration *AVSpatialVideoConfiguration, pixelBuffer unsafe.Pointer)

Associates the pixel buffer with the specified spatial configuration. - Parameters: - spatialVideoConfiguration: The spatial configuration to associate with the pixel buffer. - pixelBuffer: The pixel buffer to associate with the spatial configuration. NOTE: The spatial configuration must be one of the spatial configurations specified in the “AVVideoComposition/spatialConfigurations“ property. An exception will be thrown otherwise. NOTE: All pixel buffers from the custom compositor must be associated with the same spatial configuration. An exception will be thrown otherwise. A spatial configuration with all nil values indicates the video is not spatial. A nil spatial configuration also indicates the video is not spatial. The value can be nil, which indicates the output will not be spatial, but a spatial configuration with all nil values must be in the “AVVideoComposition/spatialConfigurations“ property or an exception will be thrown.

func (*AVAsynchronousVideoCompositionRequest) CompositionTime ¶

The time for which the frame should be composed

func (*AVAsynchronousVideoCompositionRequest) FinishCancelledRequest ¶

func (o *AVAsynchronousVideoCompositionRequest) FinishCancelledRequest()

callback the custom compositor should call for a request that has been cancelled.

func (*AVAsynchronousVideoCompositionRequest) FinishWithComposedTaggedBufferGroup ¶

func (o *AVAsynchronousVideoCompositionRequest) FinishWithComposedTaggedBufferGroup(taggedBufferGroup unsafe.Pointer)

The method that the custom compositor calls when composition succeeds. - Parameter taggedBufferGroup: The tagged buffer group containing the composed tagged buffers. The tagged buffers must be compatible with the outputBufferDescription specified in the video composition. The outputBufferDescription must not be nil when calling this function. NOTE: If “AVVideoComposition/spatialConfigurations“ is not empty, then “attach(spatialVideoConfiguration:to:)“ must be called with one of the spatial configurations. An exception will be thrown otherwise. Also, all pixel buffers must be associated with the same spatial configuration. An exception will be thrown otherwise.

func (*AVAsynchronousVideoCompositionRequest) FinishWithComposedVideoFrame ¶

func (o *AVAsynchronousVideoCompositionRequest) FinishWithComposedVideoFrame(composedVideoFrame unsafe.Pointer)

The method that the custom compositor calls when composition succeeds. - Parameter composedVideoFrame: The video frame to finish with. Call finishWithComposedTaggedBufferGroup: instead if outputBufferDescription is non-nil.

func (*AVAsynchronousVideoCompositionRequest) FinishWithError ¶

func (o *AVAsynchronousVideoCompositionRequest) FinishWithError(error_ unsafe.Pointer)

callback the custom compositor should call when composition failed. The error parameter should describe the actual error.

func (*AVAsynchronousVideoCompositionRequest) RenderContext ¶

The AVVideoCompositionRenderContext making the request

func (*AVAsynchronousVideoCompositionRequest) SourceFrameByTrackID ¶

func (o *AVAsynchronousVideoCompositionRequest) SourceFrameByTrackID(trackID int32) unsafe.Pointer

Returns the source CVPixelBufferRef for the given track ID If the track contains tagged buffers, a pixel buffer from one of the tagged buffers will be returned. - Parameter trackID: The track ID for the requested source frame

func (*AVAsynchronousVideoCompositionRequest) SourceSampleBufferByTrackID ¶

func (o *AVAsynchronousVideoCompositionRequest) SourceSampleBufferByTrackID(trackID int32) unsafe.Pointer

Returns the source CMSampleBufferRef for the given track ID - Parameter trackID: The track ID for the requested source sample buffer

func (*AVAsynchronousVideoCompositionRequest) SourceSampleDataTrackIDs ¶

Track IDs of all the source sample data buffers that are available to compose the frame.

func (*AVAsynchronousVideoCompositionRequest) SourceTaggedBufferGroupByTrackID ¶

func (o *AVAsynchronousVideoCompositionRequest) SourceTaggedBufferGroupByTrackID(trackID int32) unsafe.Pointer

Returns the source CMTaggedBufferGroupRef for the given track ID. Returns nil if the video track does not contain tagged buffers. Returns nil if the track does not contain video. This function should only be called when supportsSourceTaggedBuffers is YES. - Parameter trackID: The track ID for the requested source tagged buffer group.

func (*AVAsynchronousVideoCompositionRequest) SourceTimedMetadataByTrackID ¶

func (o *AVAsynchronousVideoCompositionRequest) SourceTimedMetadataByTrackID(trackID int32) *AVTimedMetadataGroup

Returns the source AVTimedMetadataGroup * for the given track ID - Parameter trackID: The track ID for the requested source timed metadata group.

func (*AVAsynchronousVideoCompositionRequest) SourceTrackIDs ¶

Track IDs of all the source video buffers that are available to compose the frame.

func (*AVAsynchronousVideoCompositionRequest) VideoCompositionInstruction ¶

The AVVideoCompositionInstruction to use to compose the frame.

type AVAudioMix ¶

type AVAudioMix struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avaudiomix

func AVAudioMixFromID ¶

func AVAudioMixFromID(id objc.ID) *AVAudioMix

func (*AVAudioMix) InputParameters ¶

func (o *AVAudioMix) InputParameters() *foundation.NSArray[*AVAudioMixInputParameters]

type AVAudioMixInputParameters ¶

type AVAudioMixInputParameters struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avaudiomixinputparameters

func AVAudioMixInputParametersFromID ¶

func AVAudioMixInputParametersFromID(id objc.ID) *AVAudioMixInputParameters

func (*AVAudioMixInputParameters) AudioTapProcessor ¶

func (o *AVAudioMixInputParameters) AudioTapProcessor() unsafe.Pointer

@property audioTapProcessor @abstract Indicates the audio processing tap that will be used for the audio track.

func (*AVAudioMixInputParameters) AudioTimePitchAlgorithm ¶

func (o *AVAudioMixInputParameters) AudioTimePitchAlgorithm() *foundation.NSString

@property audioTimePitchAlgorithm @abstract Indicates the processing algorithm used to manage audio pitch at varying rates and for scaled audio edits. @discussion Constants for various time pitch algorithms, e.g. AVAudioTimePitchSpectral, are defined in AVAudioProcessingSettings.h. Can be nil, in which case the audioTimePitchAlgorithm set on the AVPlayerItem, AVAssetExportSession, or AVAssetReaderAudioMixOutput on which the AVAudioMix is set will be used for the associated track.

func (*AVAudioMixInputParameters) GetVolumeRampForTimeStartVolumeEndVolumeTimeRange ¶

func (o *AVAudioMixInputParameters) GetVolumeRampForTimeStartVolumeEndVolumeTimeRange(time_ coremedia.CMTime, startVolume *float32, endVolume *float32, timeRange *coremedia.CMTimeRange) bool

func (*AVAudioMixInputParameters) TrackID ¶

func (o *AVAudioMixInputParameters) TrackID() int32

@property trackID @abstract Indicates the trackID of the audio track to which the parameters should be applied.

type AVAudioSpatializationFormats ¶

type AVAudioSpatializationFormats uint64
const (
	AVAudioSpatializationFormatNone                      AVAudioSpatializationFormats = 0
	AVAudioSpatializationFormatMonoAndStereo             AVAudioSpatializationFormats = 3
	AVAudioSpatializationFormatMultichannel              AVAudioSpatializationFormats = 4
	AVAudioSpatializationFormatMonoStereoAndMultichannel AVAudioSpatializationFormats = 7
)

func (AVAudioSpatializationFormats) String ¶

type AVAuthorizationStatus ¶

type AVAuthorizationStatus int64
const (
	AVAuthorizationStatusNotDetermined AVAuthorizationStatus = 0
	AVAuthorizationStatusRestricted    AVAuthorizationStatus = 1
	AVAuthorizationStatusDenied        AVAuthorizationStatus = 2
	AVAuthorizationStatusAuthorized    AVAuthorizationStatus = 3
)

func AVCaptureDeviceAuthorizationStatusForMediaType ¶

func AVCaptureDeviceAuthorizationStatusForMediaType(mediaType *foundation.NSString) AVAuthorizationStatus

@method authorizationStatusForMediaType: @abstract Returns the client's authorization status for accessing the underlying hardware that supports a given media type. @param mediaType The media type, either AVMediaTypeVideo or AVMediaTypeAudio @result The authorization status of the client @discussion This method returns the AVAuthorizationStatus of the client for accessing the underlying hardware supporting the media type. Media type constants are defined in AVMediaFormat.h. If any media type other than AVMediaTypeVideo or AVMediaTypeAudio is supplied, an NSInvalidArgumentException will be thrown. If the status is AVAuthorizationStatusNotDetermined, you may use the +requestAccessForMediaType:completionHandler: method to request access by prompting the user.

func AVExternalStorageDeviceAuthorizationStatus ¶

func AVExternalStorageDeviceAuthorizationStatus() AVAuthorizationStatus

@property authorizationStatus @abstract Returns the client's authorization status for capturing onto an external storage device connected to this device. @discussion This method returns the AVAuthorizationStatus of the client for capturing onto an external storage device connected to this device. If the status is AVAuthorizationStatusNotDetermined, you may use the +requestAccessWithCompletionHandler: method to request access by prompting the user.

func (AVAuthorizationStatus) String ¶

func (e AVAuthorizationStatus) String() string

type AVCameraCalibrationData ¶

type AVCameraCalibrationData struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcameracalibrationdata

func AVCameraCalibrationDataFromID ¶

func AVCameraCalibrationDataFromID(id objc.ID) *AVCameraCalibrationData

func (*AVCameraCalibrationData) ExtrinsicMatrix ¶

func (o *AVCameraCalibrationData) ExtrinsicMatrix() unsafe.Pointer

@property extrinsicMatrix @abstract A camera's extrinsic matrix describes its pose (position and direction) in world coordinates. @discussion The extrinsic matrix consists of a unitless 3x3 rotation matrix (R) on the left and a translation (t) 3x1 column vector on the right. The translation vector's units are millimeters. The camera's pose is expressed with respect to a reference camera (camera-to-world view). If the rotation matrix is an identity matrix, then this camera is the reference camera. Note that a matrix_float4x3 matrix is column major with 3 rows and 4 columns. / \ / \ | r1,1 r1,2 r1,3 | t1 | |R|t| = | r2,1 r2,2 r2,3 | t2 | \ / | r3,1 r3,2 r3,3 | t3 | \ /

func (*AVCameraCalibrationData) IntrinsicMatrix ¶

func (o *AVCameraCalibrationData) IntrinsicMatrix() unsafe.Pointer

@property intrinsicMatrix @abstract A camera's intrinsic (K) matrix describes its geometric properties. @discussion The intrinsic matrix allows one to transform 3D coordinates to 2D coordinates on an image plane using the pinhole camera model. All values are expressed in pixels. The elements in the matrix are: / \ | fx 0 ox | | 0 fy oy | | 0 0 1 | \ / where fx and fy describe the focal length. For square pixels, their values are identical. ox and oy are the offset of the principal point. The origin is the upper left of the frame.

func (*AVCameraCalibrationData) IntrinsicMatrixReferenceDimensions ¶

func (o *AVCameraCalibrationData) IntrinsicMatrixReferenceDimensions() corefoundation.CGSize

@property intrinsicMatrixReferenceDimensions @abstract The reference frame dimensions used in calculating a camera's principal point. @discussion A camera's intrinsic matrix expresses values in pixels with respect to a frame of this width and height.

func (*AVCameraCalibrationData) InverseLensDistortionLookupTable ¶

func (o *AVCameraCalibrationData) InverseLensDistortionLookupTable() *foundation.NSData

@property inverseLensDistortionLookupTable @abstract An NSData of floats describing the inverse lookup table required to reapply the camera lens' radial distortions to a rectified image. @discussion See lensDistortionLookupTable. If you've rectified an image by removing the distortions characterized by the lensDistortionLookupTable, and now wish to go back to geometrically distorted, you may use the inverseLensDistortionLookupTable. For more information, see the reference implementation below. If the camera lacks the calibration data needed to accurately characterize lens distortions, this property's value is nil.

func (*AVCameraCalibrationData) LensDistortionCenter ¶

func (o *AVCameraCalibrationData) LensDistortionCenter() corefoundation.CGPoint

@property lensDistortionCenter @abstract A CGPoint describing the offset of the lens’ distortion center from the top left in intrinsicMatrixReferenceDimensions. @discussion Due to geometric distortions in the image, the center of the distortion may not be equal to the optical center (principal point) of the lens. When making an image rectilinear, the distortion center should be used rather than the optical center of the image. For more information, see the reference implementation below. If the camera lacks the calibration data needed to accurately characterize lens distortions, this property's value is set to CGPointZero and should not be used.

func (*AVCameraCalibrationData) LensDistortionLookupTable ¶

func (o *AVCameraCalibrationData) LensDistortionLookupTable() *foundation.NSData

@property lensDistortionLookupTable @abstract An NSData of floats describing the camera lens' radial distortions. @discussion Images captured by a camera are geometrically warped by radial distortions in the lens. In order to project from the 2D image plane back into the 3D world, the images must be distortion corrected, or made rectilinear. Lens distortion is modeled using a one-dimensional lookup table of 32-bit float values evenly distributed along a radius from the center of the distortion to the farthest corner, with each value representing an elongation or compression of the radius (0.0 for any given point indicates no elongation). This model assumes radially symmetric lens distortion. When dealing with AVDepthData, the disparity / depth map representations are geometrically distorted to align with images produced by the camera. For more information, see the reference implementation below. If the camera lacks the calibration data needed to accurately characterize lens distortions, this property's value is nil.

func (*AVCameraCalibrationData) PixelSize ¶

func (o *AVCameraCalibrationData) PixelSize() float32

@property pixelSize @abstract The size of one pixel at intrinsicMatrixReferenceDimensions in millimeters.

type AVCaption ¶

type AVCaption struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaption

func AVCaptionFromID ¶

func AVCaptionFromID(id objc.ID) *AVCaption

func (*AVCaption) Animation ¶

func (o *AVCaption) Animation() AVCaptionAnimation

func (*AVCaption) BackgroundColorAtIndexRange ¶

func (o *AVCaption) BackgroundColorAtIndexRange(index int, outRange *foundation.NSRange) unsafe.Pointer

@method backgroundColorAtIndex:range: @abstract The background color of the character(s). @discussion A value of NULL means that the color is not specified. The caller must release the returned object via CGColorRelease. The range parameter receives UTF-16 code unit index range the style is effective. After returning from the call, the range will indicate where the current style returned (including NULL) will be active and allows discovery of the next change in the style. iTT format ignores this property. CEA608 closed captions support the following 8 colors with 1.0, 0.5 and 0.0 alpha values. White (RGB:1.0, 1.0, 1.0) Red (RGB:1.0, 0.0, 0.0) Blue (RGB:0.0, 0.0, 1.0) Green (RGB:0.0, 1.0, 0.0) Yellow (RGB:1.0, 1.0, 0.0) Cyan (RGB:0.0, 1.0, 1.0) Magenta (RGB:1.0, 0.0, 1.0) Black (RGB:0.0, 0.0, 0.0)

func (*AVCaption) DecorationAtIndexRange ¶

func (o *AVCaption) DecorationAtIndexRange(index int, outRange *foundation.NSRange) AVCaptionDecoration

@method decorationAtIndex:range: @abstract Character decoration @discussion The value of OR-ed value of AVCaptionDecoration as NSInteger. The range parameter receives UTF-16 code unit index range the style is effective. After returning from the call, the range will indicate where the current style returned will be active and allows discovery of the next change in the style. CEA608 closed captions support only AVCaptionDecorationNone and AVCaptionDecorationUnderline.

func (*AVCaption) FontStyleAtIndexRange ¶

func (o *AVCaption) FontStyleAtIndexRange(index int, outRange *foundation.NSRange) AVCaptionFontStyle

@method fontStyleAtIndex:range: @abstract Indicates the font style of the character(s). @discussion The range parameter receives UTF-16 code unit index range the style is effective. After returning from the call, the range will indicate where the current style returned will be active and allows discovery of the next change in the style. Some writing systems may not have italic glyphs for characters and so fonts with italic forms are not available. For example, Japanese fonts do not typically have italic forms for most characters although there may be special cases for Latin characters. Nevertheless, AVCaption still carries the font style semantics even though there may be no visible rendering distinction between using AVCaptionFontStyleNormal and AVCaptionFontStyleItalic with that language.

func (*AVCaption) FontWeightAtIndexRange ¶

func (o *AVCaption) FontWeightAtIndexRange(index int, outRange *foundation.NSRange) AVCaptionFontWeight

@method fontWeightAtIndex:range: @abstract Indicates the font weight of the character(s). @discussion The range parameter receives UTF-16 code unit index range the style is effective. After returning from the call, the range will indicate where the current style returned will be active and allows discovery of the next change in the style. CEA608 closed captions ignore this property. A visible distinction between AVCaptionFontWeightNormal and AVCaptionFontWeightBold may not exist if the font used has only one weight. This can be more common with CJK fonts where individual fonts can be quite large in terms of storage. Nevertheless, AVCaption still carries the font weight semantics so if the same AVCaption is applied to a different font having multiple weights, the distinction will become visible.

func (*AVCaption) InitWithTextTimeRange ¶

func (o *AVCaption) InitWithTextTimeRange(text *foundation.NSString, timeRange coremedia.CMTimeRange) *AVCaption

@method initWithText:timeRange: @abstract Initializes an instance of AVCaption with the given text and time range. @param text The text for the new caption object. See text property for the available character sets and other restrictions. @param timeRange The time range for the new caption object. @result An instance of AVCaption that carries the given text and time range.

func (*AVCaption) Region ¶

func (o *AVCaption) Region() *AVCaptionRegion

@property region @abstract The region where the caption is placed. @discussion It can be nil when the underlying caption format doesn't support or use regions.

func (*AVCaption) RubyAtIndexRange ¶

func (o *AVCaption) RubyAtIndexRange(index int, outRange *foundation.NSRange) *AVCaptionRuby

@method rubyAtIndex:range: @abstract Get Ruby associated with the characters. @discussion The range parameter receives UTF-16 code unit index range where the ruby text is applied. After returning from the call, the range will indicate where the current style returned (including NULL) will be active and allows discovery of the next change in the style. It returns nil when the text doesn't have a ruby at the position. CEA608 closed captions ignore this property.

func (*AVCaption) Text ¶

func (o *AVCaption) Text() *foundation.NSString

@property text @abstract The text content of the caption. @discussion The text may contain any of the line breaking character sequences (LF, CR, or CF+LF) and separating the lines in the presentation. The Apple iTT format supports all Unicode code points allowed in a XML document. Any XML special characters such as '&' are converted to a corresponding character reference syntax when written to the destination file. CEA608 closed captions support the following Unicode characters. Range: U+0020 - U+005F Range: U+0061 - U+007E Range: U+00A1 - U+00A5 Characters: U+00A9, U+00AB, U+00AE, U+00B0, U+00BB, U+00BD, U+00BF Range: U+00C0-U+00C5 Range: U+00C7-U+00CF Range: U+00D1-U+00D6 Range: U+00D8-U+00DC Range: U+00DF-U+00E5 Range: U+00E7-U+00EF Range: U+00F1-U+00FC Range: U+2018-U+2019 Range: U+2018-U+201D Character: U+2022 Range: U+2120-U+2122 Characters: U+2501, U+2503, U+250F, U+2513, U+2517, U+251B, U+2588, U+266A CEA608 closed captions don't support the line breaking character sequences (LF, CR, or CF+LF).

func (*AVCaption) TextAlignment ¶

func (o *AVCaption) TextAlignment() AVCaptionTextAlignment

@property textAlignment @abstract The text alignment within the containing region. @discussion This property throws an exception if a value is set which is not a valid AVCaptionTextAlignment.

func (*AVCaption) TextColorAtIndexRange ¶

func (o *AVCaption) TextColorAtIndexRange(index int, outRange *foundation.NSRange) unsafe.Pointer

@method textColorAtIndex:range: @abstract The color of the character(s). @discussion A value of NULL means that the color is not specified. The caller must release the returned object via CGColorRelease. The range parameter receives UTF-16 code unit index range the style is effective. The range will indicate where the current style returned (including NULL) will be active and allows discovery of the next change in the style. CEA608 closed captions support the following 8 colors with 1.0 alpha value. White (RGB:1.0, 1.0, 1.0) Red (RGB:1.0, 0.0, 0.0) Blue (RGB:0.0, 0.0, 1.0) Green (RGB:0.0, 1.0, 0.0) Yellow (RGB:1.0, 1.0, 0.0) Cyan (RGB:0.0, 1.0, 1.0) Magenta (RGB:1.0, 0.0, 1.0) Black (RGB:0.0, 0.0, 0.0)

func (*AVCaption) TextCombineAtIndexRange ¶

func (o *AVCaption) TextCombineAtIndexRange(index int, outRange *foundation.NSRange) AVCaptionTextCombine

@method textCombineAtIndex:range: @abstract Text combine (Tate-Chu-Yoko) @discussion The style is effective only in a vertical text region. When specified, the renderer combines all the characters in the style range so that their glyph areas consume the nominal bounding box of a single em square of the surrounding vertical text.

func (*AVCaption) TimeRange ¶

func (o *AVCaption) TimeRange() coremedia.CMTimeRange

@property timeRange @abstract The time range during which the caption should be presented. Apple iTT format doesn't allow two captions to have overlapped time range except when the two captions are associated with different regions. CEA608 closed caption time ranges can't start with zero, because the decoder needs some transmission time. CEA608 closed caption time ranges should be aligned with the video frame rate because this is how often the commands are delivered.

type AVCaptionAnimation ¶

type AVCaptionAnimation int64
const (
	AVCaptionAnimationNone            AVCaptionAnimation = 0
	AVCaptionAnimationCharacterReveal AVCaptionAnimation = 1
)

func (AVCaptionAnimation) String ¶

func (e AVCaptionAnimation) String() string

type AVCaptionConversionAdjustment ¶

type AVCaptionConversionAdjustment struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionconversionadjustment

func AVCaptionConversionAdjustmentFromID ¶

func AVCaptionConversionAdjustmentFromID(id objc.ID) *AVCaptionConversionAdjustment

func (*AVCaptionConversionAdjustment) AdjustmentType ¶

func (o *AVCaptionConversionAdjustment) AdjustmentType() *foundation.NSString

type AVCaptionConversionTimeRangeAdjustment ¶

type AVCaptionConversionTimeRangeAdjustment struct {
	AVCaptionConversionAdjustment
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionconversiontimerangeadjustment

func AVCaptionConversionTimeRangeAdjustmentFromID ¶

func AVCaptionConversionTimeRangeAdjustmentFromID(id objc.ID) *AVCaptionConversionTimeRangeAdjustment

func (*AVCaptionConversionTimeRangeAdjustment) DurationOffset ¶

@property durationOffset @abstract Indicates the amount by which the timeRange.duration of the captions must be adjusted in order to correct a problem. @discussion The value may any numeric value, positive, negative, or zero.

func (*AVCaptionConversionTimeRangeAdjustment) StartTimeOffset ¶

@property startTimeOffset @abstract Indicates the amount by which the timeRange.start of the captions must be adjusted in order to correct a problem. @discussion The value may any numeric value, positive, negative, or zero.

type AVCaptionConversionValidator ¶

type AVCaptionConversionValidator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionconversionvalidator

func AVCaptionConversionValidatorCaptionConversionValidatorWithCaptionsTimeRangeConversionSettings ¶

func AVCaptionConversionValidatorCaptionConversionValidatorWithCaptionsTimeRangeConversionSettings(captions *foundation.NSArray[*AVCaption], timeRange coremedia.CMTimeRange, conversionSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVCaptionConversionValidator

@method captionConversionValidatorWithCaptions:startTime:conversionSettings: @abstract Returns an instance of AVCaptionConversionValidator that can validate an array of captions for a specific conversion operation and warn about problems that are encountered. @param captions The array of captions to be validated. @param timeRange The timeRange of the media timeline into which the specified captions must be integrated. See the timeRange property for further details. @param conversionSettings Describes the conversion operation for which the captions are to be validated. @result A new instance of AVCaptionConversionValidator configured to perform the specified validation. @discussion This method throws an exception if the conversion setting's AVCaptionMediaTypeKey is not equal to AVMediaTypeClosedCaption, or if its AVCaptionMediaSubTypeKey is not equal to kCMClosedCaptionFormatType_CEA608.

func AVCaptionConversionValidatorFromID ¶

func AVCaptionConversionValidatorFromID(id objc.ID) *AVCaptionConversionValidator

func (*AVCaptionConversionValidator) Captions ¶

@property captions @abstract The array of captions to be validated for the specified conversion operation.

func (*AVCaptionConversionValidator) InitWithCaptionsTimeRangeConversionSettings ¶

func (o *AVCaptionConversionValidator) InitWithCaptionsTimeRangeConversionSettings(captions *foundation.NSArray[*AVCaption], timeRange coremedia.CMTimeRange, conversionSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVCaptionConversionValidator

@method initWithCaptions:startTime:conversionSettings: @abstract Returns an instance of AVCaptionConversionValidator that can validate an array of captions for a specific conversion operation and warn about problems that are encountered. @param captions The array of captions for which the validation is requested. @param timeRange The timeRange of the media timeline into which the specified captions must be integrated. See the timeRange property for further details. @param conversionSettings Describes the conversion operation for which the captions are to be validated. @result A new instance of AVCaptionConversionValidator configured to perform the specified validation.

func (*AVCaptionConversionValidator) Status ¶

@property status @abstract Indicates the status of the validation.

func (*AVCaptionConversionValidator) StopValidating ¶

func (o *AVCaptionConversionValidator) StopValidating()

@method stopValidating @abstract Stops validation and changes the value of status to AVCaptionConversionValidatorStatusStopped. @discussion You can call this method at any time, even within your warning handler.

func (*AVCaptionConversionValidator) TimeRange ¶

@property timeRange @abstract The timeRange of the media timeline into which the specified captions must be integrated. @discussion The start of this timeRange may be less than the start of the timeRange of the initial caption in the captions array, if the captions are to appear only after the start of accompanying video or audio. If no definite duration for the media timeline is known, the timeRange can have a duration of kCMTimePositiveInfinity. However, in order to perform a comprehensive validation of a conversion to closed captions, setting the duration of the timeRange to the duration of accompanying video media is recommended.

func (*AVCaptionConversionValidator) ValidateCaptionConversionWithWarningHandler ¶

func (o *AVCaptionConversionValidator) ValidateCaptionConversionWithWarningHandler(handler func(*AVCaptionConversionWarning))

@method validateCaptionConversionWithWarningHandler: @abstract Initiates the specified validation and changes the value of status to AVCaptionConversionValidatorStatusValidating. @param handler Specifies a block to be executed in order to warn you of a specific problem. @discussion It is an error to invoke this method when the value of status is greater than AVCaptionConversionValidatorStatusUnknown. If you wish to stop a validation operation in progress before it has been completed, send the message stopValidating to the receiver. When the validation is complete and all warnings have been reported, the block will be executed once with a value of nil for its warning parameter. When this occurs, the value of status will have been changed to AVCaptionConversionValidatorStatusCompleted.

func (*AVCaptionConversionValidator) Warnings ¶

@property warnings @abstract Provides the collection of warnings for problems that have been encountered. While the value of status is AVCaptionConversionValidatorStatusValidating, the count of warnings may increase.

type AVCaptionConversionValidatorStatus ¶

type AVCaptionConversionValidatorStatus int64
const (
	AVCaptionConversionValidatorStatusUnknown    AVCaptionConversionValidatorStatus = 0
	AVCaptionConversionValidatorStatusValidating AVCaptionConversionValidatorStatus = 1
	AVCaptionConversionValidatorStatusCompleted  AVCaptionConversionValidatorStatus = 2
	AVCaptionConversionValidatorStatusStopped    AVCaptionConversionValidatorStatus = 3
)

func (AVCaptionConversionValidatorStatus) String ¶

type AVCaptionConversionWarning ¶

type AVCaptionConversionWarning struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionconversionwarning

func AVCaptionConversionWarningFromID ¶

func AVCaptionConversionWarningFromID(id objc.ID) *AVCaptionConversionWarning

func (*AVCaptionConversionWarning) Adjustment ¶

@property adjustment @abstract Indicates an adjustment to the indicated captions that can be applied in order to correct the problem. @discussion If the value of adjustment is not nil and the conversion operation is performed without correcting the problem, the adjustment will be applied during conversion. If the value of adjustment is nil and the conversion operation is performed without correcting the problem, the indicated captions will be omitted from the output media data.

func (*AVCaptionConversionWarning) RangeOfCaptions ¶

func (o *AVCaptionConversionWarning) RangeOfCaptions() foundation.NSRange

@property rangeOfCaptions @abstract Indicates the range of captions in the validator's captions array for which the specified warning has been issued. @discussion Only captions with the same start time and duration will be referenced. If captions with different start times and durations exhibit similar problems, a separate instance of AVCaptionConversionWarning will be used to indicate each problematic case. If the referenced captions have multiple problems, a separate instance of AVCaptionConversionWarning will be issued to indicate each problem.

func (*AVCaptionConversionWarning) WarningType ¶

@property warningType @abstract Indicates the type of warning provided by the receiver.

type AVCaptionDecoration ¶

type AVCaptionDecoration uint64
const (
	AVCaptionDecorationNone        AVCaptionDecoration = 0
	AVCaptionDecorationUnderline   AVCaptionDecoration = 1
	AVCaptionDecorationLineThrough AVCaptionDecoration = 2
	AVCaptionDecorationOverline    AVCaptionDecoration = 4
)

func (AVCaptionDecoration) String ¶

func (e AVCaptionDecoration) String() string

type AVCaptionDimension ¶

type AVCaptionDimension struct {
	Value float64
	Units AVCaptionUnitsType
}

@typedef AVCaptionDimension @abstract The length with a unit or coordinate on a 2D geometric axis @field value The value of the coordinate or length. @field units The units of the coordinate (e.g., cells, points)

func AVCaptionDimensionMake ¶

func AVCaptionDimensionMake(value float64, units AVCaptionUnitsType) AVCaptionDimension

@function AVCaptionDimensionMake @abstract Makes an AVCaptionDimension from a value and units.

type AVCaptionFontStyle ¶

type AVCaptionFontStyle int64
const (
	AVCaptionFontStyleUnknown AVCaptionFontStyle = 0
	AVCaptionFontStyleNormal  AVCaptionFontStyle = 1
	AVCaptionFontStyleItalic  AVCaptionFontStyle = 2
)

func (AVCaptionFontStyle) String ¶

func (e AVCaptionFontStyle) String() string

type AVCaptionFontWeight ¶

type AVCaptionFontWeight int64
const (
	AVCaptionFontWeightUnknown AVCaptionFontWeight = 0
	AVCaptionFontWeightNormal  AVCaptionFontWeight = 1
	AVCaptionFontWeightBold    AVCaptionFontWeight = 2
)

func (AVCaptionFontWeight) String ¶

func (e AVCaptionFontWeight) String() string

type AVCaptionFormatConformer ¶

type AVCaptionFormatConformer struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionformatconformer

func AVCaptionFormatConformerCaptionFormatConformerWithConversionSettings ¶

func AVCaptionFormatConformerCaptionFormatConformerWithConversionSettings(conversionSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVCaptionFormatConformer

@method captionFormatConformerWithConversionSettings:conversionSettings: @abstract Returns an instance of AVCaptionFormatConformer that can convert a canonical caption to conform to a specific format. @param conversionSettings Describes the conversion operation for which the caption is to be conformed. @result A new instance of AVCaptionFormatConformer configured to perform the specified conversion.

func AVCaptionFormatConformerFromID ¶

func AVCaptionFormatConformerFromID(id objc.ID) *AVCaptionFormatConformer

func (*AVCaptionFormatConformer) ConformedCaptionForCaptionError ¶

func (o *AVCaptionFormatConformer) ConformedCaptionForCaptionError(caption *AVCaption) (*AVCaption, error)

@method conformedCaptionForCaption:error: @abstract Creates a format-compliant caption that conforms to a specific format by converting a given canonical caption. @param caption Specifies a canonical caption to be converted. @param outError A pointer where a NSError object may be returned. @result A format-compliant caption that conforms to a specific format.

func (*AVCaptionFormatConformer) ConformsCaptionsToTimeRange ¶

func (o *AVCaptionFormatConformer) ConformsCaptionsToTimeRange() bool

@property conformsCaptionsToTimeRange @abstract Specifies whether to conform the time range of a given canonical caption as well. @discussion When set to YES, conforms time range. When set to NO, the time range of the conformed caption will be same as a given canonical caption. In the case of conforming to CAE608 format, AVCaption is encoded so that each CAE608 control code (2 bytes) fits into 1 frame duration (1001/30000). When set to YES and if all the encoded data can not fit inside the canonical caption time range, the caption time range will be extended to fit all the data and will be returned in the conformed AVCaption. The default value is NO.

func (*AVCaptionFormatConformer) InitWithConversionSettings ¶

func (o *AVCaptionFormatConformer) InitWithConversionSettings(conversionSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVCaptionFormatConformer

@method initWithConversionSettings:conversionSettings: @abstract Returns an instance of AVCaptionFormatConformer that can convert a canonical caption to conform to a specific format. @param conversionSettings Describes the conversion operation for which the caption is to be conformed. @result A new instance of AVCaptionFormatConformer configured to perform the specified conversion. @discussion This method throws an exception if the conversion setting's AVCaptionMediaTypeKey is not equal to AVMediaTypeClosedCaption, or if its AVCaptionMediaSubTypeKey is not equal to kCMClosedCaptionFormatType_CEA608.

func (*AVCaptionFormatConformer) SetConformsCaptionsToTimeRange ¶

func (o *AVCaptionFormatConformer) SetConformsCaptionsToTimeRange(conformsCaptionsToTimeRange bool)

type AVCaptionGroup ¶

type AVCaptionGroup struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptiongroup

func AVCaptionGroupFromID ¶

func AVCaptionGroupFromID(id objc.ID) *AVCaptionGroup

func (*AVCaptionGroup) Captions ¶

func (o *AVCaptionGroup) Captions() *foundation.NSArray[*AVCaption]

@property captions @abstract An array of AVCaption objects. @discussion If the value is an empty array, the caption group represents a region of the timeline in which there are no captions.

func (*AVCaptionGroup) InitWithCaptionsTimeRange ¶

func (o *AVCaptionGroup) InitWithCaptionsTimeRange(captions *foundation.NSArray[*AVCaption], timeRange coremedia.CMTimeRange) *AVCaptionGroup

@method initWithCaptions:timeRange: @abstract Initializes a caption group with the given set of captions and the time range. @discussion Every caption in the array must be equal or sub range of the time range, otherwise an exception is raised. @param captions The captions that will be included in the group. The array is coped. @result A newly-initialized caption group.

func (*AVCaptionGroup) InitWithTimeRange ¶

func (o *AVCaptionGroup) InitWithTimeRange(timeRange coremedia.CMTimeRange) *AVCaptionGroup

@method initWithTimeRange: @abstract Initializes an empty caption group with the given time range. @discussion This is a convenient initializer to create an empty caption group time range. @param timeRange The time range for which there are no captions. @result A newly-initialized empty caption group.

func (*AVCaptionGroup) TimeRange ¶

func (o *AVCaptionGroup) TimeRange() coremedia.CMTimeRange

@property timeRange @abstract The time range represented by the caption group. @discussion If there are no captions in the group (i.e. the value of the captions property is an empty array), then the value of this property represents the time range of a sequence where no captions are present.

type AVCaptionGrouper ¶

type AVCaptionGrouper struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptiongrouper

func AVCaptionGrouperFromID ¶

func AVCaptionGrouperFromID(id objc.ID) *AVCaptionGrouper

func (*AVCaptionGrouper) AddCaption ¶

func (o *AVCaptionGrouper) AddCaption(input *AVCaption)

func (*AVCaptionGrouper) FlushAddedCaptionsIntoGroupsUpToTime ¶

func (o *AVCaptionGrouper) FlushAddedCaptionsIntoGroupsUpToTime(upToTime coremedia.CMTime) *foundation.NSArray[*AVCaptionGroup]

type AVCaptionPoint ¶

type AVCaptionPoint struct {
	X AVCaptionDimension
	Y AVCaptionDimension
}

@typedef AVCaptionPoint @abstract A two dimensional point made of x and y AVCaptionDimension coordinates @field x An AVCaptionDimension holding the x coordinate of the point @field y An AVCaptionDimension holding the y coordinate of the point

func AVCaptionPointMake ¶

func AVCaptionPointMake(x AVCaptionDimension, y AVCaptionDimension) AVCaptionPoint

@function AVCaptionPointMake @abstract Makes an AVCaptionPoint from x and y coordinate AVCaptionDimensions.

type AVCaptionRegion ¶

type AVCaptionRegion struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionregion

func AVCaptionRegionAppleITTBottomRegion ¶

func AVCaptionRegionAppleITTBottomRegion() *AVCaptionRegion

@property appleITTBottomRegion @abstract The bottom region for iTT format @discussion This region can be used in iTT format and it occupies the bottom 15% of the display area. The region uses LRTB, a line progresses left to right and the block extends from top to bottom. Each line is stacked with bottom justified.

func AVCaptionRegionAppleITTLeftRegion ¶

func AVCaptionRegionAppleITTLeftRegion() *AVCaptionRegion

@property appleITTLeftRegion @abstract The left region for iTT format @discussion This region can be used in iTT format and it occupies the left 15% of the display area. The region uses TBRL, a line progresses top to bottom and the block extends from right to left. Each line is stacked with right justified.

func AVCaptionRegionAppleITTRightRegion ¶

func AVCaptionRegionAppleITTRightRegion() *AVCaptionRegion

@property appleITTRightRegion @abstract The right region for iTT format @discussion This region can be used in iTT format and it occupies the right 15% of the display area. The region uses TBRL, a line progresses top to bottom and the block extends from right to left. Each line is stacked with right justified.

func AVCaptionRegionAppleITTTopRegion ¶

func AVCaptionRegionAppleITTTopRegion() *AVCaptionRegion

@property appleITTTopRegion @abstract The top region for iTT format @discussion This region can be used in iTT format and it occupies the top 15% of the display area. The region uses LRTB, a line progresses left to right and the block extends from top to bottom. Each line is stacked with top justified.

func AVCaptionRegionFromID ¶

func AVCaptionRegionFromID(id objc.ID) *AVCaptionRegion

func AVCaptionRegionSubRipTextBottomRegion ¶

func AVCaptionRegionSubRipTextBottomRegion() *AVCaptionRegion

@property subRipTextBottomRegion @abstract The bottom region for SubRip Text (SRT) format @discussion This region can be used in SRT format and it occupies the entire video display area. The region uses LRTB, a line progresses left to right and the block extends from top to bottom. Each line is stacked with bottom justified.

func (*AVCaptionRegion) DisplayAlignment ¶

func (o *AVCaptionRegion) DisplayAlignment() AVCaptionRegionDisplayAlignment

@property displayAlignment @abstract Alignment of lines for the region

func (*AVCaptionRegion) EncodeWithCoder ¶

func (o *AVCaptionRegion) EncodeWithCoder(encoder *foundation.NSCoder)

@method encodeWithCoder: @abstract NSCoding protocol method override @discussion This method throws an exception if the caption region's size has different units for width and height, or if the units are unrecognizeable.

func (*AVCaptionRegion) Identifier ¶

func (o *AVCaptionRegion) Identifier() *foundation.NSString

@property identifier @abstract Identifier for the region @discussion When regionIdentifier is nil, two regions with the same position and endPosition are considered to be same, that is captions referring these regions belong to the same region when serialized to a format like TTML. In addition, the AVCaptionRegion cannot be mutably copied. When regionIdentifier is not nil, two regions are same if and only if the region identifier is equal. It is a client's responsibility to ensure these AVCaptionRegion objects have the same properties.

func (*AVCaptionRegion) IsEqual ¶

func (o *AVCaptionRegion) IsEqual(object objc.ID) bool

func (*AVCaptionRegion) Origin ¶

func (o *AVCaptionRegion) Origin() AVCaptionPoint

@property origin @abstract The position of the top-left of the region, potentially with unspecified fields. @discussion It returns an AVCaptionPoint potentially with unspecified x and/or y fields. Unspecified dimensions indicate the region doesn't have positioning information for that dimension.

func (*AVCaptionRegion) Scroll ¶

@property scroll @abstract Scroll mode for the region @discussion See AVCaptionRegionScrollXXX enum for possible values.

func (*AVCaptionRegion) Size ¶

func (o *AVCaptionRegion) Size() AVCaptionSize

@property size @abstract The width and height of the region, potentally with unspecified fields. @discussion It returns an AVCaptionSize potentially with unspecified width and/or height. CEA608 closed captions support limits the size.height property’s value to 1 cell except when the AVCaptionRegionScroll is AVCaptionRegionScrollRollUp. If the AVCaptionRegionScroll is AVCaptionRegionScrollRollUp, the size.height property’s value must be 2, 3 or 4 cells. It returns an AVCaptionSize with unspecifed width and height when the region doesn't have width or height information.

func (*AVCaptionRegion) WritingMode ¶

@property writingMode @abstract The block and inline progression direction of the region.

type AVCaptionRegionDisplayAlignment ¶

type AVCaptionRegionDisplayAlignment int64
const (
	AVCaptionRegionDisplayAlignmentBefore AVCaptionRegionDisplayAlignment = 0
	AVCaptionRegionDisplayAlignmentCenter AVCaptionRegionDisplayAlignment = 1
	AVCaptionRegionDisplayAlignmentAfter  AVCaptionRegionDisplayAlignment = 2
)

func (AVCaptionRegionDisplayAlignment) String ¶

type AVCaptionRegionScroll ¶

type AVCaptionRegionScroll int64
const (
	AVCaptionRegionScrollNone   AVCaptionRegionScroll = 0
	AVCaptionRegionScrollRollUp AVCaptionRegionScroll = 1
)

func (AVCaptionRegionScroll) String ¶

func (e AVCaptionRegionScroll) String() string

type AVCaptionRegionWritingMode ¶

type AVCaptionRegionWritingMode int64
const (
	AVCaptionRegionWritingModeLeftToRightAndTopToBottom AVCaptionRegionWritingMode = 0
	AVCaptionRegionWritingModeTopToBottomAndRightToLeft AVCaptionRegionWritingMode = 2
)

func (AVCaptionRegionWritingMode) String ¶

type AVCaptionRenderer ¶

type AVCaptionRenderer struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionrenderer

func AVCaptionRendererFromID ¶

func AVCaptionRendererFromID(id objc.ID) *AVCaptionRenderer

func (*AVCaptionRenderer) Bounds ¶

@property bounds @abstract A CGRect holding bounds for the drawing of caption scene(s). @discussion This is a CGRect indicating where captions are drawn using renderInContext:atTime: Once established, this CGRect is used in each call to renderInContext:atTime: until it is changed to another value. This should be set up earlier than drawing.

func (*AVCaptionRenderer) CaptionSceneChangesInRange ¶

func (o *AVCaptionRenderer) CaptionSceneChangesInRange(consideredTimeRange coremedia.CMTimeRange) *foundation.NSArray[*AVCaptionRendererScene]

@method captionSceneChangesInRange: @abstract Determine render time ranges within an enclosing time range to account for visual changes among captions. @result An NSArray of AVCaptionRendererScenes; perhaps empty if there are no captions intersecting with the consideredTimeRange @discussion This is an optional service useful for optimizing drawing. A client can perform drawing without it. As captions may become active and inactive throughout the timeline, this method will return a NSArray holding scene objects with time ranges on whose edges there's a visual change. The client can use the ranges of time between these edges with -renderInContext:atTime: to ensure all visual changes are rendered. The returned time ranges consider activation/deactivation of captions, temporal overlapping, and intra-caption timing requirements (e.g., character reveal animations). Time ranges may be returned where no captions are active as this is also a change in the caption "scene". The returned NSArray contains AVCaptionRendererScenes, each holding the CMTimeRange of that scene but potentially other information that may be useful to the client during renderering. The consideredTimeRange parameter is a CMTimeRange expressing the limits for consideration. The extent of this range does not need to correspond to the timing of captions. It might be the range from 0 to some duration. For efficiency, the range can be limited to a window of time. It is also possible to use the range anchored at a time and extending in the direction of playback.

func (*AVCaptionRenderer) Captions ¶

func (o *AVCaptionRenderer) Captions() *foundation.NSArray[*AVCaption]

@property captions @abstract A NSArray holding captions to consider for rendering. @discussion This is the array of AVCaptions to consider when drawing. The array can contain no captions.

func (*AVCaptionRenderer) Init ¶

func (*AVCaptionRenderer) RenderInContextForTime ¶

func (o *AVCaptionRenderer) RenderInContextForTime(ctx unsafe.Pointer, time_ coremedia.CMTime)

@method renderInContext:forTime: @abstract Draw the captions corresponding to a time established by the AVCaptions to a CGContext. @discussion Captions are drawn into the CGContextRef based upon their activation at the specified time. If there are no captions or no captions at the specified time, "emptiness" will still be drawn (e.g., flood filling with zero alpha or a color).

func (*AVCaptionRenderer) SetBounds ¶

func (o *AVCaptionRenderer) SetBounds(bounds corefoundation.CGRect)

func (*AVCaptionRenderer) SetCaptions ¶

func (o *AVCaptionRenderer) SetCaptions(captions *foundation.NSArray[*AVCaption])

type AVCaptionRendererScene ¶

type AVCaptionRendererScene struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionrendererscene

func AVCaptionRendererSceneFromID ¶

func AVCaptionRendererSceneFromID(id objc.ID) *AVCaptionRendererScene

func (*AVCaptionRendererScene) HasActiveCaptions ¶

func (o *AVCaptionRendererScene) HasActiveCaptions() bool

@property hasActiveCaptions @abstract The scene contains one or more active captions. @discussion Clients should not use this to restrict their drawing and should call renderInContext:atTime: to draw "emptiness". However, this information may be useful for purposes such as scrubbing to times where captions are present, skipping scenes in which no captions are present.

func (*AVCaptionRendererScene) NeedsPeriodicRefresh ¶

func (o *AVCaptionRendererScene) NeedsPeriodicRefresh() bool

@property needsPeriodicRefresh @abstract The scene may have embedded animations or other state where periodic redrawing while playing through this scene is needed. @discussion This property indicates if refreshing should occur if the client is progressing through the content. If the client is not progressing (i.e., it is treating playback as though the rate is 0.0), a single render at the current render time suffices. This property does not prescribe a refresh rate. A client is free to choose a refresh rate corresponding to rates of associated video frames or other timing appropriate for the client.

func (*AVCaptionRendererScene) TimeRange ¶

@property timeRange @abstract The time range during which new captions will not be introduced into or existing captions will be retired from the caption scene

type AVCaptionRuby ¶

type AVCaptionRuby struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptionruby

func AVCaptionRubyFromID ¶

func AVCaptionRubyFromID(id objc.ID) *AVCaptionRuby

func (*AVCaptionRuby) Alignment ¶

func (o *AVCaptionRuby) Alignment() AVCaptionRubyAlignment

@property alignment @abstract The alignment of ruby text.

func (*AVCaptionRuby) InitWithText ¶

func (o *AVCaptionRuby) InitWithText(text *foundation.NSString) *AVCaptionRuby

func (*AVCaptionRuby) InitWithTextPositionAlignment ¶

func (o *AVCaptionRuby) InitWithTextPositionAlignment(text *foundation.NSString, position AVCaptionRubyPosition, alignment AVCaptionRubyAlignment) *AVCaptionRuby

func (*AVCaptionRuby) Position ¶

func (o *AVCaptionRuby) Position() AVCaptionRubyPosition

@property position @abstract The position of ruby text with respect to the ruby base.

func (*AVCaptionRuby) Text ¶

func (o *AVCaptionRuby) Text() *foundation.NSString

@property text @abstract The ruby text

type AVCaptionRubyAlignment ¶

type AVCaptionRubyAlignment int64
const (
	AVCaptionRubyAlignmentStart                  AVCaptionRubyAlignment = 0
	AVCaptionRubyAlignmentCenter                 AVCaptionRubyAlignment = 1
	AVCaptionRubyAlignmentDistributeSpaceBetween AVCaptionRubyAlignment = 2
	AVCaptionRubyAlignmentDistributeSpaceAround  AVCaptionRubyAlignment = 3
)

func (AVCaptionRubyAlignment) String ¶

func (e AVCaptionRubyAlignment) String() string

type AVCaptionRubyPosition ¶

type AVCaptionRubyPosition int64
const (
	AVCaptionRubyPositionBefore AVCaptionRubyPosition = 0
	AVCaptionRubyPositionAfter  AVCaptionRubyPosition = 1
)

func (AVCaptionRubyPosition) String ¶

func (e AVCaptionRubyPosition) String() string

type AVCaptionSize ¶

type AVCaptionSize struct {
	Width  AVCaptionDimension
	Height AVCaptionDimension
}

@typedef AVCaptionSize @abstract A two dimensional size made of width and height AVCaptionDimensions @field width An AVCaptionDimension holding the width @field height An AVCaptionDimension holding the height

func AVCaptionSizeMake ¶

func AVCaptionSizeMake(width AVCaptionDimension, height AVCaptionDimension) AVCaptionSize

@function AVCaptionSizeMake @abstract Makes an AVCaptionSize from width and height AVCaptionDimensions.

type AVCaptionTextAlignment ¶

type AVCaptionTextAlignment int64
const (
	AVCaptionTextAlignmentStart  AVCaptionTextAlignment = 0
	AVCaptionTextAlignmentEnd    AVCaptionTextAlignment = 1
	AVCaptionTextAlignmentCenter AVCaptionTextAlignment = 2
	AVCaptionTextAlignmentLeft   AVCaptionTextAlignment = 3
	AVCaptionTextAlignmentRight  AVCaptionTextAlignment = 4
)

func (AVCaptionTextAlignment) String ¶

func (e AVCaptionTextAlignment) String() string

type AVCaptionTextCombine ¶

type AVCaptionTextCombine int64
const (
	AVCaptionTextCombineAll         AVCaptionTextCombine = -1
	AVCaptionTextCombineNone        AVCaptionTextCombine = 0
	AVCaptionTextCombineOneDigit    AVCaptionTextCombine = 1
	AVCaptionTextCombineTwoDigits   AVCaptionTextCombine = 2
	AVCaptionTextCombineThreeDigits AVCaptionTextCombine = 3
	AVCaptionTextCombineFourDigits  AVCaptionTextCombine = 4
)

func (AVCaptionTextCombine) String ¶

func (e AVCaptionTextCombine) String() string

type AVCaptionUnitsType ¶

type AVCaptionUnitsType int64
const (
	AVCaptionUnitsTypeUnspecified AVCaptionUnitsType = 0
	AVCaptionUnitsTypeCells       AVCaptionUnitsType = 1
	AVCaptionUnitsTypePercent     AVCaptionUnitsType = 2
)

func (AVCaptionUnitsType) String ¶

func (e AVCaptionUnitsType) String() string

type AVCaptureAudioChannel ¶

type AVCaptureAudioChannel struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureaudiochannel

func AVCaptureAudioChannelFromID ¶

func AVCaptureAudioChannelFromID(id objc.ID) *AVCaptureAudioChannel

func (*AVCaptureAudioChannel) AveragePowerLevel ¶

func (o *AVCaptureAudioChannel) AveragePowerLevel() float32

@property averagePowerLevel @abstract A measurement of the instantaneous average power level of the audio flowing through the receiver. @discussion A client may poll an AVCaptureAudioChannel object for its current averagePowerLevel to get its instantaneous average power level in decibels. This property is not key-value observable.

func (*AVCaptureAudioChannel) IsEnabled ¶

func (o *AVCaptureAudioChannel) IsEnabled() bool

@property enabled @abstract A property indicating whether the receiver is currently enabled for data capture. @discussion By default, all AVCaptureAudioChannel objects exposed by a connection are enabled. You may set enabled to NO to stop the flow of data for a particular AVCaptureAudioChannel.

func (*AVCaptureAudioChannel) PeakHoldLevel ¶

func (o *AVCaptureAudioChannel) PeakHoldLevel() float32

@property peakHoldLevel @abstract A measurement of the peak/hold level of the audio flowing through the receiver. @discussion A client may poll an AVCaptureAudioChannel object for its current peakHoldLevel to get its most recent peak hold level in decibels. This property is not key-value observable.

func (*AVCaptureAudioChannel) SetEnabled ¶

func (o *AVCaptureAudioChannel) SetEnabled(enabled bool)

func (*AVCaptureAudioChannel) SetVolume ¶

func (o *AVCaptureAudioChannel) SetVolume(volume float32)

func (*AVCaptureAudioChannel) Volume ¶

func (o *AVCaptureAudioChannel) Volume() float32

@property volume @abstract A property indicating the current volume (gain) of the receiver. @discussion The volume property indicates the current volume or gain of the receiver as a floating point value between 0.0 -> 1.0. If you desire to boost the gain in software, you may specify a a value greater than 1.0.

type AVCaptureAudioDataOutput ¶

type AVCaptureAudioDataOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureaudiodataoutput

func AVCaptureAudioDataOutputFromID ¶

func AVCaptureAudioDataOutputFromID(id objc.ID) *AVCaptureAudioDataOutput

func AVCaptureAudioDataOutputNew ¶

func AVCaptureAudioDataOutputNew() *AVCaptureAudioDataOutput

func (*AVCaptureAudioDataOutput) AudioSettings ¶

@property audioSettings @abstract Specifies the settings used to decode or re-encode audio before it is output by the receiver. @discussion The value of this property is an NSDictionary containing values for audio settings keys defined in AVAudioSettings.h. When audioSettings is set to nil, the AVCaptureAudioDataOutput vends samples in their device native format.

func (*AVCaptureAudioDataOutput) Init ¶

func (*AVCaptureAudioDataOutput) RecommendedAudioSettingsForAssetWriterWithOutputFileType ¶

func (o *AVCaptureAudioDataOutput) RecommendedAudioSettingsForAssetWriterWithOutputFileType(outputFileType *foundation.NSString) *foundation.NSDictionary[*foundation.NSString, objc.ID]

@method recommendedAudioSettingsForAssetWriterWithOutputFileType: @abstract Specifies the recommended settings for use with an AVAssetWriterInput. @param outputFileType Specifies the UTI of the file type to be written (see AVMediaFormat.h for a list of file format UTIs). @result A fully populated dictionary of keys and values that are compatible with AVAssetWriter. @discussion The value of this property is an NSDictionary containing values for compression settings keys defined in AVAudioSettings.h. This dictionary is suitable for use as the "outputSettings" parameter when creating an AVAssetWriterInput, such as, [AVAssetWriterInput assetWriterInputWithMediaType:AVMediaTypeAudio outputSettings:outputSettings sourceFormatHint:hint]; The dictionary returned contains all necessary keys and values needed by AVAssetWriter (see AVAssetWriterInput.h, -initWithMediaType:outputSettings: for a more in depth discussion). For QuickTime movie and ISO files, the recommended audio settings will always produce output comparable to that of AVCaptureMovieFileOutput. Note that the dictionary of settings is dependent on the current configuration of the receiver's AVCaptureSession and its inputs. The settings dictionary may change if the session's configuration changes. As such, you should configure your session first, then query the recommended audio settings.

func (*AVCaptureAudioDataOutput) SampleBufferCallbackQueue ¶

func (o *AVCaptureAudioDataOutput) SampleBufferCallbackQueue() *foundation.NSObject

@property sampleBufferCallbackQueue @abstract The dispatch queue on which all sample buffer delegate methods will be called. @discussion The value of this property is a dispatch_queue_t. The queue is set using the setSampleBufferDelegate:queue: method.

func (*AVCaptureAudioDataOutput) SampleBufferDelegate ¶

@property sampleBufferDelegate @abstract The receiver's delegate. @discussion The value of this property is an object conforming to the AVCaptureAudioDataOutputSampleBufferDelegate protocol that will receive sample buffers after they are captured. The delegate is set using the setSampleBufferDelegate:queue: method.

func (*AVCaptureAudioDataOutput) SetAudioSettings ¶

func (o *AVCaptureAudioDataOutput) SetAudioSettings(audioSettings *foundation.NSDictionary[*foundation.NSString, objc.ID])

func (*AVCaptureAudioDataOutput) SetSampleBufferDelegateQueue ¶

func (o *AVCaptureAudioDataOutput) SetSampleBufferDelegateQueue(sampleBufferDelegate AVCaptureAudioDataOutputSampleBufferDelegate, sampleBufferCallbackQueue *foundation.NSObject)

@method setSampleBufferDelegate:queue: @abstract Sets the receiver's delegate that will accept captured buffers and dispatch queue on which the delegate will be called. @param sampleBufferDelegate An object conforming to the AVCaptureAudioDataOutputSampleBufferDelegate protocol that will receive sample buffers after they are captured. @param sampleBufferCallbackQueue A dispatch queue on which all sample buffer delegate methods will be called. @discussion When a new audio sample buffer is captured it will be vended to the sample buffer delegate using the captureOutput:didOutputSampleBuffer:fromConnection: delegate method. All delegate methods will be called on the specified dispatch queue. If the queue is blocked when new samples are captured, those samples will be automatically dropped when they become sufficiently late. This allows clients to process existing samples on the same queue without having to manage the potential memory usage increases that would otherwise occur when that processing is unable to keep up with the rate of incoming samples. Clients that need to minimize the chances of samples being dropped should specify a queue on which a sufficiently small amount of processing is being done outside of receiving sample buffers. However, if such clients migrate extra processing to another queue, they are responsible for ensuring that memory usage does not grow without bound from samples that have not been processed. A serial dispatch queue must be used to guarantee that audio samples will be delivered in order. The sampleBufferCallbackQueue parameter may not be NULL, except when setting sampleBufferDelegate to nil otherwise -setSampleBufferDelegate:queue: throws an NSInvalidArgumentException.

func (*AVCaptureAudioDataOutput) SetSpatialAudioChannelLayoutTag ¶

func (o *AVCaptureAudioDataOutput) SetSpatialAudioChannelLayoutTag(spatialAudioChannelLayoutTag uint)

func (*AVCaptureAudioDataOutput) SpatialAudioChannelLayoutTag ¶

func (o *AVCaptureAudioDataOutput) SpatialAudioChannelLayoutTag() uint

The audio channel layout tag of the audio sample buffers produced by the audio data output. When you set your audio data output's associated “AVCaptureDeviceInput/multichannelAudioMode“ property to “AVCaptureMultichannelAudioModeFirstOrderAmbisonics“, the “AVCaptureSession“ allows up to two “AVCaptureAudioDataOutput“ instances to be connected to the First-order Ambisonsics (FOA) input. If you connect a single “AVCaptureAudioDataOutput“ instance, you must configure its “AVCaptureAudioDataOutput/spatialAudioChannelLayoutTag“ property to produce either four channels of FOA audio or two channels of Stereo audio. If you connect two “AVCaptureAudioDataOutput“ instances, you must configure one to output four channels of FOA audio and the other to output two channels of Stereo audio. Thus, when you set your associated “AVCaptureDeviceInput/multichannelAudioMode“ property to “AVCaptureMultichannelAudioModeFirstOrderAmbisonics“, you must set your connected “AVCaptureAudioDataOutput“ instance's “AVCaptureAudioDataOutput/spatialAudioChannelLayoutTag“ property to either `kAudioChannelLayoutTag_Stereo` for stereo, or `(kAudioChannelLayoutTag_HOA_ACN_SN3D | 4)` for FOA (see <doc://com.apple.documentation/documentation/coreaudiotypes/audiochannellayouttag>). When you set your associated “AVCaptureDeviceInput/multichannelAudioMode“ to any other value, the “AVCaptureSession“ only supports one “AVCaptureAudioDataOutput“, and you may only set “AVCaptureAudioDataOutput/spatialAudioChannelLayoutTag“ to `kAudioChannelLayoutTag_Unknown` (the default value). Your “AVCaptureSession“ validates your app's adherence to the the above rules when you call “AVCaptureSession/startRunning:“ or “AVCaptureSession/commitConfiguration“ and throws a `NSInvalidArgumentException` if necessary.

type AVCaptureAudioDataOutputSampleBufferDelegate ¶

type AVCaptureAudioDataOutputSampleBufferDelegate interface {
}

AVCaptureAudioDataOutputSampleBufferDelegate wraps the ObjC protocol AVCaptureAudioDataOutputSampleBufferDelegate.

type AVCaptureAudioFileOutput ¶

type AVCaptureAudioFileOutput struct {
	AVCaptureFileOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureaudiofileoutput

func AVCaptureAudioFileOutputFromID ¶

func AVCaptureAudioFileOutputFromID(id objc.ID) *AVCaptureAudioFileOutput

func AVCaptureAudioFileOutputNew ¶

func AVCaptureAudioFileOutputNew() *AVCaptureAudioFileOutput

func (*AVCaptureAudioFileOutput) AudioSettings ¶

@property audioSettings @abstract Specifies the options the receiver uses to re-encode audio as it is being recorded. @discussion The output settings dictionary can contain values for keys from AVAudioSettings.h. A value of nil indicates that the format of the audio should not be changed before being written to the file.

func (*AVCaptureAudioFileOutput) Init ¶

func (*AVCaptureAudioFileOutput) Metadata ¶

@property metadata @abstract A collection of metadata to be written to the receiver's output files. @discussion The value of this property is an array of AVMetadataItem objects representing the collection of top-level metadata to be written in each output file. Only ID3 v2.2, v2.3, or v2.4 style metadata items are supported.

func (*AVCaptureAudioFileOutput) SetAudioSettings ¶

func (o *AVCaptureAudioFileOutput) SetAudioSettings(audioSettings *foundation.NSDictionary[*foundation.NSString, objc.ID])

func (*AVCaptureAudioFileOutput) SetMetadata ¶

func (o *AVCaptureAudioFileOutput) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVCaptureAudioFileOutput) StartRecordingToOutputFileURLOutputFileTypeRecordingDelegate ¶

func (o *AVCaptureAudioFileOutput) StartRecordingToOutputFileURLOutputFileTypeRecordingDelegate(outputFileURL *foundation.NSURL, fileType *foundation.NSString, delegate AVCaptureFileOutputRecordingDelegate)

@method startRecordingToOutputFileURL:outputFileType:recordingDelegate: @abstract Tells the receiver to start recording to a new file of the specified format, and specifies a delegate that will be notified when recording is finished. @param outputFileURL An NSURL object containing the URL of the output file. This method throws an NSInvalidArgumentException if the URL is not a valid file URL. @param fileType A UTI indicating the format of the file to be written. @param delegate An object conforming to the AVCaptureFileOutputRecordingDelegate protocol. Clients must specify a delegate so that they can be notified when recording to the given URL is finished. @discussion The method sets the file URL to which the receiver is currently writing output media. If a file at the given URL already exists when capturing starts, recording to the new file will fail. The fileType argument is a UTI corresponding to the audio file format that should be written. UTIs for common audio file types are declared in AVMediaFormat.h. Clients need not call stopRecording before calling this method while another recording is in progress. If this method is invoked while an existing output file was already being recorded, no media samples will be discarded between the old file and the new file. When recording is stopped either by calling stopRecording, by changing files using this method, or because of an error, the remaining data that needs to be included to the file will be written in the background. Therefore, clients must specify a delegate that will be notified when all data has been written to the file using the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: method. The recording delegate can also optionally implement methods that inform it when data starts being written, when recording is paused and resumed, and when recording is about to be finished. On macOS, if this method is called within the captureOutput:didOutputSampleBuffer:fromConnection: delegate method, the first samples written to the new file are guaranteed to be those contained in the sample buffer passed to that method.

type AVCaptureAudioPreviewOutput ¶

type AVCaptureAudioPreviewOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureaudiopreviewoutput

func AVCaptureAudioPreviewOutputFromID ¶

func AVCaptureAudioPreviewOutputFromID(id objc.ID) *AVCaptureAudioPreviewOutput

func AVCaptureAudioPreviewOutputNew ¶

func AVCaptureAudioPreviewOutputNew() *AVCaptureAudioPreviewOutput

func (*AVCaptureAudioPreviewOutput) Init ¶

func (*AVCaptureAudioPreviewOutput) OutputDeviceUniqueID ¶

func (o *AVCaptureAudioPreviewOutput) OutputDeviceUniqueID() *foundation.NSString

@property outputDeviceUniqueID @abstract Specifies the unique ID of the Core Audio output device being used to play preview audio. @discussion The value of this property is an NSString containing the unique ID of the Core Audio device to be used for output, or nil if the default system output should be used.

func (*AVCaptureAudioPreviewOutput) SetOutputDeviceUniqueID ¶

func (o *AVCaptureAudioPreviewOutput) SetOutputDeviceUniqueID(outputDeviceUniqueID *foundation.NSString)

func (*AVCaptureAudioPreviewOutput) SetVolume ¶

func (o *AVCaptureAudioPreviewOutput) SetVolume(volume float32)

func (*AVCaptureAudioPreviewOutput) Volume ¶

@property volume @abstract Specifies the preview volume of the output. @discussion The value of this property is the preview volume of the receiver, where 1.0 is the maximum volume and 0.0 is muted.

type AVCaptureAutoFocusSystem ¶

type AVCaptureAutoFocusSystem int64
const (
	AVCaptureAutoFocusSystemNone              AVCaptureAutoFocusSystem = 0
	AVCaptureAutoFocusSystemContrastDetection AVCaptureAutoFocusSystem = 1
	AVCaptureAutoFocusSystemPhaseDetection    AVCaptureAutoFocusSystem = 2
)

func (AVCaptureAutoFocusSystem) String ¶

func (e AVCaptureAutoFocusSystem) String() string

type AVCaptureCameraLensSmudgeDetectionStatus ¶

type AVCaptureCameraLensSmudgeDetectionStatus int64
const (
	// Indicates that the detection is not enabled.
	AVCaptureCameraLensSmudgeDetectionStatusDisabled AVCaptureCameraLensSmudgeDetectionStatus = 0
	// Indicates that the most recent detection found no smudge on the camera lens.
	AVCaptureCameraLensSmudgeDetectionStatusSmudgeNotDetected AVCaptureCameraLensSmudgeDetectionStatus = 1
	// Indicates that the most recent detection found the camera lens to be smudged.
	AVCaptureCameraLensSmudgeDetectionStatusSmudged AVCaptureCameraLensSmudgeDetectionStatus = 2
	// Indicates that the detection result has not settled, commonly caused by excessive camera movement or the content of the scene.
	AVCaptureCameraLensSmudgeDetectionStatusUnknown AVCaptureCameraLensSmudgeDetectionStatus = 3
)

func (AVCaptureCameraLensSmudgeDetectionStatus) String ¶

type AVCaptureCenterStageControlMode ¶

type AVCaptureCenterStageControlMode int64
const (
	AVCaptureCenterStageControlModeUser        AVCaptureCenterStageControlMode = 0
	AVCaptureCenterStageControlModeApp         AVCaptureCenterStageControlMode = 1
	AVCaptureCenterStageControlModeCooperative AVCaptureCenterStageControlMode = 2
)

func AVCaptureDeviceCenterStageControlMode ¶

func AVCaptureDeviceCenterStageControlMode() AVCaptureCenterStageControlMode

@property centerStageControlMode @abstract A class property indicating the current mode of Center Stage control (user, app, or cooperative). @discussion This class property determines how the Center Stage feature is controlled. When set to the default value of AVCaptureCenterStageControlModeUser, centerStageEnabled may not be set programmatically and throws an NSInvalidArgumentException. In User mode, the feature may only be set by the user in Control Center. If you wish to take Center Stage control away from the user and exclusively enable / disable it programmatically, set this property to AVCaptureCenterStageControlModeApp. When under exclusive app control, Center Stage user control is disallowed (for instance, the toggle is grayed out in Control Center). If you wish to take control of Center Stage, but also cooperate with the user by listening for and appropriately reacting to their changes to the centerStageEnabled property, set this property to AVCaptureCenterStageControlModeCooperative. Note that in this mode, the onus is on you, the app developer, to honor user intent and conform your AVCaptureSession configuration to make Center Stage active (see the AVCaptureDevice instance property centerStageActive). In cooperative mode, the centerStageEnabled property may change at any time (such as when the user enables / disables the feature in Control Center).

func (AVCaptureCenterStageControlMode) String ¶

type AVCaptureCinematicVideoFocusMode ¶

type AVCaptureCinematicVideoFocusMode int64
const (
	// Indicates that no focus mode is specified, in which case weak focus is used as default.
	AVCaptureCinematicVideoFocusModeNone AVCaptureCinematicVideoFocusMode = 0
	// Indicates that the subject should remain in focus until it exits the scene.
	AVCaptureCinematicVideoFocusModeStrong AVCaptureCinematicVideoFocusMode = 1
	// Indicates that the Cinematic Video algorithm should automatically adjust focus according to the prominence of the subjects in the scene.
	AVCaptureCinematicVideoFocusModeWeak AVCaptureCinematicVideoFocusMode = 2
)

func (AVCaptureCinematicVideoFocusMode) String ¶

type AVCaptureColorSpace ¶

type AVCaptureColorSpace int64
const (
	// The sRGB color space ( https://www.w3.org/Graphics/Color/srgb ).
	AVCaptureColorSpace_sRGB AVCaptureColorSpace = 0
	// The P3 D65 wide color space which uses Illuminant D65 as the white point.
	AVCaptureColorSpace_P3_D65 AVCaptureColorSpace = 1
)

func (AVCaptureColorSpace) String ¶

func (e AVCaptureColorSpace) String() string

type AVCaptureConnection ¶

type AVCaptureConnection struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureconnection

func AVCaptureConnectionConnectionWithInputPortVideoPreviewLayer ¶

func AVCaptureConnectionConnectionWithInputPortVideoPreviewLayer(port *AVCaptureInputPort, layer *AVCaptureVideoPreviewLayer) *AVCaptureConnection

@method connectionWithInputPort:videoPreviewLayer: @abstract Returns an AVCaptureConnection instance describing a connection between the specified inputPort and the specified AVCaptureVideoPreviewLayer instance. @param port An AVCaptureInputPort object associated with an AVCaptureInput object. @param layer An AVCaptureVideoPreviewLayer object. @result An AVCaptureConnection instance joining the specified inputPort to the specified video preview layer. @discussion This method returns an instance of AVCaptureConnection that may be subsequently added to an AVCaptureSession instance using AVCaptureSession's -addConnection: method. When using AVCaptureVideoPreviewLayer's -initWithSession: or -setSession:, a connection is formed between the first compatible input port and the video preview layer automatically. You do not need to manually create and add connections to the session unless you use AVCaptureVideoPreviewLayer's primitive -initWithSessionWithNoConnection: or -setSessionWithNoConnection: methods.

func AVCaptureConnectionConnectionWithInputPortsOutput ¶

func AVCaptureConnectionConnectionWithInputPortsOutput(ports *foundation.NSArray[*AVCaptureInputPort], output *AVCaptureOutput) *AVCaptureConnection

@method connectionWithInputPorts:output: @abstract Returns an AVCaptureConnection instance describing a connection between the specified inputPorts and the specified output. @param ports An array of AVCaptureInputPort objects associated with AVCaptureInput objects. @param output An AVCaptureOutput object. @result An AVCaptureConnection instance joining the specified inputPorts to the specified output port. @discussion This method returns an instance of AVCaptureConnection that may be subsequently added to an AVCaptureSession instance using AVCaptureSession's -addConnection: method. When using -addInput: or -addOutput:, connections are formed between all compatible inputs and outputs automatically. You do not need to manually create and add connections to the session unless you use the primitive -addInputWithNoConnections: or -addOutputWithNoConnections: methods.

func AVCaptureConnectionFromID ¶

func AVCaptureConnectionFromID(id objc.ID) *AVCaptureConnection

func (*AVCaptureConnection) AudioChannels ¶

@property audioChannels @abstract An array of AVCaptureAudioChannel objects representing individual channels of audio data flowing through the connection. @discussion This property is only applicable to AVCaptureConnection instances involving audio. In such connections, the audioChannels array contains one AVCaptureAudioChannel object for each channel of audio data flowing through this connection.

func (*AVCaptureConnection) AutomaticallyAdjustsVideoMirroring ¶

func (o *AVCaptureConnection) AutomaticallyAdjustsVideoMirroring() bool

@property automaticallyAdjustsVideoMirroring @abstract Specifies whether or not the value of @"videoMirrored" can change based on configuration of the session. @discussion For some session configurations, video data flowing through the connection will be mirrored by default. When the value of this property is YES, the value of @"videoMirrored" may change depending on the configuration of the session, for example after switching to a different AVCaptureDeviceInput. The default value is YES.

func (*AVCaptureConnection) InitWithInputPortVideoPreviewLayer ¶

func (o *AVCaptureConnection) InitWithInputPortVideoPreviewLayer(port *AVCaptureInputPort, layer *AVCaptureVideoPreviewLayer) *AVCaptureConnection

@method initWithInputPort:videoPreviewLayer: @abstract Returns an AVCaptureConnection instance describing a connection between the specified inputPort and the specified AVCaptureVideoPreviewLayer instance. @param port An AVCaptureInputPort object associated with an AVCaptureInput object. @param layer An AVCaptureVideoPreviewLayer object. @result An AVCaptureConnection instance joining the specified inputPort to the specified video preview layer. @discussion This method returns an instance of AVCaptureConnection that may be subsequently added to an AVCaptureSession instance using AVCaptureSession's -addConnection: method. When using AVCaptureVideoPreviewLayer's -initWithSession: or -setSession:, a connection is formed between the first compatible input port and the video preview layer automatically. You do not need to manually create and add connections to the session unless you use AVCaptureVideoPreviewLayer's primitive -initWithSessionWithNoConnection: or -setSessionWithNoConnection: methods.

func (*AVCaptureConnection) InitWithInputPortsOutput ¶

func (o *AVCaptureConnection) InitWithInputPortsOutput(ports *foundation.NSArray[*AVCaptureInputPort], output *AVCaptureOutput) *AVCaptureConnection

@method initWithInputPorts:output: @abstract Returns an AVCaptureConnection instance describing a connection between the specified inputPorts and the specified output. @param ports An array of AVCaptureInputPort objects associated with AVCaptureInput objects. @param output An AVCaptureOutput object. @result An AVCaptureConnection instance joining the specified inputPorts to the specified output port. @discussion This method returns an instance of AVCaptureConnection that may be subsequently added to an AVCaptureSession instance using AVCaptureSession's -addConnection: method. When using -addInput: or -addOutput:, connections are formed between all compatible inputs and outputs automatically. You do not need to manually create and add connections to the session unless you use the primitive -addInputWithNoConnections: or -addOutputWithNoConnections: methods.

func (*AVCaptureConnection) InputPorts ¶

@property inputPorts @abstract An array of AVCaptureInputPort instances providing data through this connection. @discussion An AVCaptureConnection may involve one or more AVCaptureInputPorts producing data to the connection's AVCaptureOutput. This property is read-only. An AVCaptureConnection's inputPorts remain static for the life of the object.

func (*AVCaptureConnection) IsActive ¶

func (o *AVCaptureConnection) IsActive() bool

@property active @abstract Indicates whether the receiver's output is currently capable of consuming data through this connection. @discussion The value of this property is a BOOL that determines whether the receiver's output can consume data provided through this connection. This property is read-only. Clients may key-value observe this property to know when a session's configuration forces a connection to become inactive. The default value is YES. Prior to iOS 11, the audio connection feeding an AVCaptureAudioDataOutput is made inactive when using AVCaptureSessionPresetPhoto or the equivalent photo format using -[AVCaptureDevice activeFormat]. On iOS 11 and later, the audio connection feeding AVCaptureAudioDataOutput is active for all presets and device formats.

func (*AVCaptureConnection) IsEnabled ¶

func (o *AVCaptureConnection) IsEnabled() bool

@property enabled @abstract Indicates whether the connection's output should consume data. @discussion The value of this property is a BOOL that determines whether the receiver's output should consume data from its connected inputPorts when a session is running. Clients can set this property to stop the flow of data to a given output during capture. The default value is YES.

func (*AVCaptureConnection) IsVideoFieldModeSupported ¶

func (o *AVCaptureConnection) IsVideoFieldModeSupported() bool

@property supportsVideoFieldMode @abstract Indicates whether the connection supports setting the videoFieldMode property. @discussion This property is only applicable to AVCaptureConnection instances involving video. In such connections, the videoFieldMode property may only be set if -isVideoFieldModeSupported returns YES.

func (*AVCaptureConnection) IsVideoMaxFrameDurationSupported ¶

func (o *AVCaptureConnection) IsVideoMaxFrameDurationSupported() bool

@property supportsVideoMaxFrameDuration @abstract Indicates whether the connection supports setting the videoMaxFrameDuration property. @discussion This property is only applicable to AVCaptureConnection instances involving video. In such connections, the videoMaxFrameDuration property may only be set if -isVideoMaxFrameDurationSupported returns YES. This property is deprecated on iOS, where min and max frame rate adjustments are applied exclusively at the AVCaptureDevice using the activeVideoMinFrameDuration and activeVideoMaxFrameDuration properties. On macOS, frame rate adjustments are supported both at the AVCaptureDevice and at AVCaptureConnection, enabling connections to output different frame rates.

func (*AVCaptureConnection) IsVideoMinFrameDurationSupported ¶

func (o *AVCaptureConnection) IsVideoMinFrameDurationSupported() bool

@property supportsVideoMinFrameDuration @abstract Indicates whether the connection supports setting the videoMinFrameDuration property. @discussion This property is only applicable to AVCaptureConnection instances involving video. In such connections, the videoMinFrameDuration property may only be set if -isVideoMinFrameDurationSupported returns YES. This property is deprecated on iOS, where min and max frame rate adjustments are applied exclusively at the AVCaptureDevice using the activeVideoMinFrameDuration and activeVideoMaxFrameDuration properties. On macOS, frame rate adjustments are supported both at the AVCaptureDevice and at AVCaptureConnection, enabling connections to output different frame rates.

func (*AVCaptureConnection) IsVideoMirrored ¶

func (o *AVCaptureConnection) IsVideoMirrored() bool

@property videoMirrored @abstract Indicates whether the video flowing through the connection should be mirrored about its vertical axis. @discussion This property is only applicable to AVCaptureConnection instances involving video. if -isVideoMirroringSupported returns YES, videoMirrored may be set to flip the video about its vertical axis and produce a mirror-image effect. This property may not be set unless -isVideoMirroringSupported returns YES, otherwise a NSInvalidArgumentException is thrown. This property may not be set if -automaticallyAdjustsVideoMirroring returns YES, otherwise an NSInvalidArgumentException is thrown.

func (*AVCaptureConnection) IsVideoMirroringSupported ¶

func (o *AVCaptureConnection) IsVideoMirroringSupported() bool

@property supportsVideoMirroring @abstract Indicates whether the connection supports setting the videoMirrored property. @discussion This property is only applicable to AVCaptureConnection instances involving video. In such connections, the videoMirrored property may only be set if -isVideoMirroringSupported returns YES.

func (*AVCaptureConnection) IsVideoOrientationSupported ¶

func (o *AVCaptureConnection) IsVideoOrientationSupported() bool

@property supportsVideoOrientation @abstract Indicates whether the connection supports setting the videoOrientation property. @discussion This property is deprecated. Use -isVideoRotationAngleSupported: instead. Deprecated: Use -isVideoRotationAngleSupported: instead

func (*AVCaptureConnection) IsVideoRotationAngleSupported ¶

func (o *AVCaptureConnection) IsVideoRotationAngleSupported(videoRotationAngle float64) bool

@method isVideoRotationAngleSupported: @abstract Returns whether the connection supports the given rotation angle in degrees. @param videoRotationAngle A video rotation angle to be checked. @result YES if the connection supports the given video rotation angle, NO otherwise. @discussion The connection's videoRotationAngle property can only be set to a certain angle if this method returns YES for that angle. Only rotation angles of 0, 90, 180 and 270 are supported.

func (*AVCaptureConnection) Output ¶

func (o *AVCaptureConnection) Output() *AVCaptureOutput

@property output @abstract The AVCaptureOutput instance consuming data from this connection's inputPorts. @discussion An AVCaptureConnection may involve one or more AVCaptureInputPorts producing data to the connection's AVCaptureOutput. This property is read-only. An AVCaptureConnection's output remains static for the life of the object. Note that a connection can either be to an output or a video preview layer, but never to both.

func (*AVCaptureConnection) SetAutomaticallyAdjustsVideoMirroring ¶

func (o *AVCaptureConnection) SetAutomaticallyAdjustsVideoMirroring(automaticallyAdjustsVideoMirroring bool)

func (*AVCaptureConnection) SetEnabled ¶

func (o *AVCaptureConnection) SetEnabled(enabled bool)

func (*AVCaptureConnection) SetVideoFieldMode ¶

func (o *AVCaptureConnection) SetVideoFieldMode(videoFieldMode AVVideoFieldMode)

func (*AVCaptureConnection) SetVideoMaxFrameDuration ¶

func (o *AVCaptureConnection) SetVideoMaxFrameDuration(videoMaxFrameDuration coremedia.CMTime)

func (*AVCaptureConnection) SetVideoMinFrameDuration ¶

func (o *AVCaptureConnection) SetVideoMinFrameDuration(videoMinFrameDuration coremedia.CMTime)

func (*AVCaptureConnection) SetVideoMirrored ¶

func (o *AVCaptureConnection) SetVideoMirrored(videoMirrored bool)

func (*AVCaptureConnection) SetVideoOrientation deprecated

func (o *AVCaptureConnection) SetVideoOrientation(videoOrientation AVCaptureVideoOrientation)

Deprecated: Use -videoRotationAngle instead

func (*AVCaptureConnection) SetVideoRotationAngle ¶

func (o *AVCaptureConnection) SetVideoRotationAngle(videoRotationAngle float64)

func (*AVCaptureConnection) VideoFieldMode ¶

func (o *AVCaptureConnection) VideoFieldMode() AVVideoFieldMode

@property videoFieldMode @abstract Indicates how interlaced video flowing through the connection should be treated. @discussion This property is only applicable to AVCaptureConnection instances involving video. If -isVideoFieldModeSupported returns YES, videoFieldMode may be set to affect interlaced video content flowing through the connection.

func (*AVCaptureConnection) VideoMaxFrameDuration ¶

func (o *AVCaptureConnection) VideoMaxFrameDuration() coremedia.CMTime

@property videoMaxFrameDuration @abstract Indicates the maximum time interval at which the receiver should output consecutive video frames. @discussion The value of this property is a CMTime specifying the maximum duration of each video frame output by the receiver, placing an upper bound on the amount of time that should separate consecutive frames. This is equivalent to the reciprocal of the minimum frame rate. A value of kCMTimeZero or kCMTimeInvalid indicates an unlimited minimum frame rate. The default value is kCMTimeInvalid. This property is deprecated on iOS, where min and max frame rate adjustments are applied exclusively at the AVCaptureDevice using the activeVideoMinFrameDuration and activeVideoMaxFrameDuration properties. On macOS, frame rate adjustments are supported both at the AVCaptureDevice and at AVCaptureConnection, enabling connections to output different frame rates.

func (*AVCaptureConnection) VideoMinFrameDuration ¶

func (o *AVCaptureConnection) VideoMinFrameDuration() coremedia.CMTime

@property videoMinFrameDuration @abstract Indicates the minimum time interval at which the receiver should output consecutive video frames. @discussion The value of this property is a CMTime specifying the minimum duration of each video frame output by the receiver, placing a lower bound on the amount of time that should separate consecutive frames. This is equivalent to the reciprocal of the maximum frame rate. A value of kCMTimeZero or kCMTimeInvalid indicates an unlimited maximum frame rate. The default value is kCMTimeInvalid. This property is deprecated on iOS, where min and max frame rate adjustments are applied exclusively at the AVCaptureDevice using the activeVideoMinFrameDuration and activeVideoMaxFrameDuration properties. On macOS, frame rate adjustments are supported both at the AVCaptureDevice and at AVCaptureConnection, enabling connections to output different frame rates.

func (*AVCaptureConnection) VideoOrientation ¶

func (o *AVCaptureConnection) VideoOrientation() AVCaptureVideoOrientation

@property videoOrientation @abstract Indicates whether the video flowing through the connection should be rotated to a given orientation. @discussion This property is deprecated. Use -videoRotationAngle instead. This property may only be set if -isVideoOrientationSupported returns YES, otherwise an NSInvalidArgumentException is thrown. Deprecated: Use -videoRotationAngle instead

func (*AVCaptureConnection) VideoPreviewLayer ¶

func (o *AVCaptureConnection) VideoPreviewLayer() *AVCaptureVideoPreviewLayer

@property videoPreviewLayer @abstract The AVCaptureVideoPreviewLayer instance consuming data from this connection's inputPort. @discussion An AVCaptureConnection may involve one AVCaptureInputPort producing data to an AVCaptureVideoPreviewLayer object. This property is read-only. An AVCaptureConnection's videoPreviewLayer remains static for the life of the object. Note that a connection can either be to an output or a video preview layer, but never to both.

func (*AVCaptureConnection) VideoRotationAngle ¶

func (o *AVCaptureConnection) VideoRotationAngle() float64

@property videoRotationAngle @abstract Indicates whether the video flowing through the connection should be rotated with a given angle in degrees. @discussion This property is only applicable to AVCaptureConnection instances involving video or depth. -setVideoRotationAngle: throws an NSInvalidArgumentException if set to an unsupported value (see -isVideoRotationAngleSupported:). Note that setting videoRotationAngle does not necessarily result in physical rotation of video buffers. For instance, a video connection to an AVCaptureMovieFileOutput handles orientation using a Quicktime track matrix. In the AVCapturePhotoOutput, orientation is handled using Exif tags. And the AVCaptureVideoPreviewLayer applies transforms to its contents to perform rotations. However, the AVCaptureVideoDataOutput and AVCaptureDepthDataOutput do output physically rotated video buffers. Setting a video rotation angle for an output that does physically rotate buffers requires a lengthy configuration of the capture render pipeline and should be done before calling -[AVCaptureSession startRunning]. Starting with the Spring 2024 iPad line, the default value of videoRotationAngle is 180 degrees for video data on Front Camera as compared to 0 degrees on previous devices. So clients using AVCaptureVideoDataOutput and AVCaptureDepthDataOutput should set videoRotationAngle to 0 to avoid the physical buffer rotation described above. And clients rotating video data by themselves must account for the default value of videoRotationAngle when applying angles (videoRotationAngleForHorizonLevelPreview, videoRotationAngleForHorizonLevelCapture) from AVCaptureDeviceRotationCoordinator. Note that this change in default value is currently limited to these iPads, however it is recommended that clients rotating video data themselves incorporate the default rotation value into their workflows for all devices. Clients using AVCaptureVideoDataOutput with ProRes Raw should set videoRotationAngle to 0 as rotation is not supported for RAW buffers. If clients want to rotate these buffers themselves they need to apply rotation angles (videoRotationAngleForHorizonLevelPreview, videoRotationAngleForHorizonLevelCapture) provided by AVCaptureDeviceRotationCoordinator.

type AVCaptureControl ¶

type AVCaptureControl struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturecontrol

func AVCaptureControlFromID ¶

func AVCaptureControlFromID(id objc.ID) *AVCaptureControl

func (*AVCaptureControl) IsEnabled ¶

func (o *AVCaptureControl) IsEnabled() bool

func (*AVCaptureControl) SetEnabled ¶

func (o *AVCaptureControl) SetEnabled(enabled bool)

type AVCaptureDeskViewApplication ¶

type AVCaptureDeskViewApplication struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedeskviewapplication

func AVCaptureDeskViewApplicationFromID ¶

func AVCaptureDeskViewApplicationFromID(id objc.ID) *AVCaptureDeskViewApplication

func (*AVCaptureDeskViewApplication) PresentWithCompletionHandler ¶

func (o *AVCaptureDeskViewApplication) PresentWithCompletionHandler(completionHandler func(unsafe.Pointer))

@method presentWithCompletionHandler: @abstract Presents the Desk View application to the user with no launch configuration. @param completionHandler A block to be called once the Desk View application has been completely launched (or brought to the foreground). @discussion This method allows you to programmatically launch the Desk View application from your own application UI. If the Desk View application is already running, this method brings it to the front. If the Desk View application is minimized in the Dock, this method un-minimizes it and brings it to the front.

func (*AVCaptureDeskViewApplication) PresentWithLaunchConfigurationCompletionHandler ¶

func (o *AVCaptureDeskViewApplication) PresentWithLaunchConfigurationCompletionHandler(launchConfiguration *AVCaptureDeskViewApplicationLaunchConfiguration, completionHandler func(unsafe.Pointer))

@method presentWithLaunchConfiguration:completionHandler: @abstract Presents the Desk View application to the user. @param launchConfiguration Launch configuration governing how the Desk View application will be presented. @param completionHandler A block to be called once the Desk View application has been completely launched (or brought to the foreground). Optionally, this completionHandler may fire later, once the user has completed set up mode (see AVCaptureDeskViewApplicationLaunchConfiguration.requiresSetUpModeCompletion). @discussion This method allows you to programmatically launch the Desk View application from your own application UI. If the Desk View application is already running, this method brings it to the front. If the Desk View application is minimized in the Dock, this method un-minimizes it and brings it to the front.

type AVCaptureDeskViewApplicationLaunchConfiguration ¶

type AVCaptureDeskViewApplicationLaunchConfiguration struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedeskviewapplicationlaunchconfiguration

func AVCaptureDeskViewApplicationLaunchConfigurationFromID ¶

func AVCaptureDeskViewApplicationLaunchConfigurationFromID(id objc.ID) *AVCaptureDeskViewApplicationLaunchConfiguration

func (*AVCaptureDeskViewApplicationLaunchConfiguration) MainWindowFrame ¶

@property mainWindowFrame @abstract Specifies the desired frame of the Desk View application's main window when launched. @discussion Default value is CGRectZero. The app will use a default value in this case (the user's previously selected position). mainWindowFrame is specified in global screen coordinates. When launching the Desk View application from a Mac Catalyst app, window origin is top left. When launched from a native macOS app, window origin is bottom left.

func (*AVCaptureDeskViewApplicationLaunchConfiguration) RequiresSetUpModeCompletion ¶

func (o *AVCaptureDeskViewApplicationLaunchConfiguration) RequiresSetUpModeCompletion() bool

@property requiresSetUpModeCompletion @abstract Specifies whether presentWithLaunchConfiguration:completionHandler:'s completionHandler fires immediately after the application is launched, or only after the user has completed set up. @discussion The Desk View application launches in set up mode, showing the full field of view of an Ultra Wide camera with a superimposed trapezoid indicating the desk region crop that will be shown once set up is complete. By default, your presentWithLaunchConfiguration:completionHandler:'s completionHandler fires after the Desk View application is launched and visible to the user. By setting this property to YES, your completionHandler only fires when the user has completed set up mode and transitioned to the cropped Desk View mode.

func (*AVCaptureDeskViewApplicationLaunchConfiguration) SetMainWindowFrame ¶

func (o *AVCaptureDeskViewApplicationLaunchConfiguration) SetMainWindowFrame(mainWindowFrame corefoundation.CGRect)

func (*AVCaptureDeskViewApplicationLaunchConfiguration) SetRequiresSetUpModeCompletion ¶

func (o *AVCaptureDeskViewApplicationLaunchConfiguration) SetRequiresSetUpModeCompletion(requiresSetUpModeCompletion bool)

type AVCaptureDevice ¶

type AVCaptureDevice struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedevice

func AVCaptureDeviceDefaultDeviceWithDeviceTypeMediaTypePosition ¶

func AVCaptureDeviceDefaultDeviceWithDeviceTypeMediaTypePosition(deviceType *foundation.NSString, mediaType *foundation.NSString, position AVCaptureDevicePosition) *AVCaptureDevice

@method defaultDeviceWithDeviceType:mediaType:position: @abstract Returns an AVCaptureDevice instance for the default device of the given device type, media type, and position. @param deviceType The device type supported by the returned device. It must be a valid AVCaptureDeviceType. @param mediaType The media type, such as AVMediaTypeVideo, AVMediaTypeAudio, or AVMediaTypeMuxed, supported by the returned device. Pass nil to consider devices with any media type. @param position The position supported by the returned device. Pass AVCaptureDevicePositionUnspecified to consider devices with any position. @result The default device with the given device type, media type and position or nil if no device with that media type exists and nil otherwise. @discussion This method returns the default device of the given combination of device type, media type, and position currently available on the system.

func AVCaptureDeviceDefaultDeviceWithMediaType ¶

func AVCaptureDeviceDefaultDeviceWithMediaType(mediaType *foundation.NSString) *AVCaptureDevice

@method defaultDeviceWithMediaType: @abstract Returns an AVCaptureDevice instance for the default device of the given media type. @param mediaType The media type, such as AVMediaTypeVideo, AVMediaTypeAudio, or AVMediaTypeMuxed, supported by the returned device. @result The default device with the given media type, or nil if no device with that media type exists. @discussion This method returns the default device of the given media type currently available on the system. For example, for AVMediaTypeVideo, this method will return the built in camera that is primarily used for capture and recording. Media type constants are defined in AVMediaFormat.h.

func AVCaptureDeviceDeviceWithUniqueID ¶

func AVCaptureDeviceDeviceWithUniqueID(deviceUniqueID *foundation.NSString) *AVCaptureDevice

@method deviceWithUniqueID: @abstract Returns an AVCaptureDevice instance with the given unique ID. @param deviceUniqueID The unique ID of the device instance to be returned. @result An AVCaptureDevice instance with the given unique ID, or nil if no device with that unique ID is available. @discussion Every available capture device has a unique ID that persists on one system across device connections and disconnections, application restarts, and reboots of the system itself. This method can be used to recall or track the status of a specific device whose unique ID has previously been saved.

func AVCaptureDeviceFromID ¶

func AVCaptureDeviceFromID(id objc.ID) *AVCaptureDevice

func AVCaptureDeviceSystemPreferredCamera ¶

func AVCaptureDeviceSystemPreferredCamera() *AVCaptureDevice

@property systemPreferredCamera @abstract Specifies the best camera to use as determined by the system. @discussion Apple chooses the default value. This property incorporates userPreferredCamera as well as other factors, such as camera suspension and Apple cameras appearing that should be automatically chosen. The property may change spontaneously, such as when the preferred camera goes away. This property always returns a device that is present. If no camera is available nil is returned. Applications that adopt this API should always key-value observe this property and update their AVCaptureSession’s input device to reflect changes to the systemPreferredCamera. The application can still offer users the ability to pick a camera by setting userPreferredCamera, which will cause the systemPreferredCamera API to put the user’s choice first until either another Apple-preferred device becomes available or the machine is rebooted (after which it reverts to its original behavior of returning the internally determined best camera to use). If the application wishes to offer users a fully manual camera selection mode in addition to automatic camera selection, it is recommended to call setUserPreferredCamera: each time the user makes a camera selection, but ignore key-value observer updates to systemPreferredCamera while in manual selection mode.

func AVCaptureDeviceUserPreferredCamera ¶

func AVCaptureDeviceUserPreferredCamera() *AVCaptureDevice

@property userPreferredCamera @abstract Settable property that specifies a user preferred camera. @discussion Setting this property allows an application to persist its user’s preferred camera across app launches and reboots. The property internally maintains a short history, so if your user’s most recent preferred camera is not currently connected, it still reports the next best choice. This property always returns a device that is present. If no camera is available nil is returned. Setting the property to nil has no effect.

func (*AVCaptureDevice) ActiveColorSpace ¶

func (o *AVCaptureDevice) ActiveColorSpace() AVCaptureColorSpace

func (*AVCaptureDevice) ActiveFormat ¶

func (o *AVCaptureDevice) ActiveFormat() *AVCaptureDeviceFormat

@property activeFormat @abstract The currently active format of the receiver. @discussion This property can be used to get or set the currently active device format. -setActiveFormat: throws an NSInvalidArgumentException if set to a format not present in the formats array. -setActiveFormat: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's activeFormat by key value observing this property. On iOS, use of AVCaptureDevice's setActiveFormat: and AVCaptureSession's setSessionPreset: are mutually exclusive. If you set a capture device's active format, the session to which it is attached changes its preset to AVCaptureSessionPresetInputPriority. Likewise if you set the AVCaptureSession's sessionPreset property, the session assumes control of its input devices, and configures their activeFormat appropriately. Note that audio devices do not expose any user-configurable formats on iOS. To configure audio input on iOS, you should use the AVAudioSession APIs instead (see AVAudioSession.h). The activeFormat, activeVideoMinFrameDuration, and activeVideoMaxFrameDuration properties may be set simultaneously by using AVCaptureSession's begin/commitConfiguration methods: [session beginConfiguration]; // the session to which the receiver's AVCaptureDeviceInput is added. if ( [device lockForConfiguration:&error] ) { [device setActiveFormat:newFormat]; [device setActiveVideoMinFrameDuration:newMinDuration]; [device setActiveVideoMaxFrameDuration:newMaxDuration]; [device unlockForConfiguration]; } [session commitConfiguration]; // The new format and frame rates are applied together in commitConfiguration Note that when configuring a session to use an active format intended for high resolution still photography and applying one or more of the following operations to an AVCaptureVideoDataOutput, the system may not meet the target framerate: zoom, orientation changes, format conversion.

func (*AVCaptureDevice) ActiveInputSource ¶

func (o *AVCaptureDevice) ActiveInputSource() *AVCaptureDeviceInputSource

@property activeInputSource @abstract The currently active input source of the receiver. @discussion This property can be used to get or set the currently active device input source. -setActiveInputSource: throws an NSInvalidArgumentException if set to a value not present in the inputSources array. -setActiveInputSource: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's activeInputSource by key value observing this property.

func (*AVCaptureDevice) ActivePrimaryConstituentDevice ¶

func (o *AVCaptureDevice) ActivePrimaryConstituentDevice() *AVCaptureDevice

@property activePrimaryConstituentDevice @abstract For virtual devices, this property indicates which constituent device is currently the primary constituent device. The primary constituent device may change when zoom, exposure, or focus changes. @discussion This property returns nil for non-virtual devices. On virtual devices this property returns nil until the device is used in a running AVCaptureSession. This property is key-value observable.

func (*AVCaptureDevice) ActivePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions ¶

func (o *AVCaptureDevice) ActivePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions() AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions

@property activePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions @abstract The active constituent device restricted switching behavior. @discussion For virtual devices with multiple constituent devices, this property returns the active restricted switching behavior conditions. This is equal to primaryConstituentDeviceRestrictedSwitchingBehaviorConditions except while recording using an AVCaptureMovieFileOutput configured with different restricted switching behavior conditions (see -[AVCaptureMovieFileOutput setPrimaryConstituentDeviceSwitchingBehaviorForRecording:restrictedSwitchingBehaviorConditions]). Devices that do not support constituent device switching return AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionNone. This property is key-value observable.

func (*AVCaptureDevice) ActivePrimaryConstituentDeviceSwitchingBehavior ¶

func (o *AVCaptureDevice) ActivePrimaryConstituentDeviceSwitchingBehavior() AVCapturePrimaryConstituentDeviceSwitchingBehavior

@property activePrimaryConstituentDeviceSwitchingBehavior @abstract The active constituent device switching behavior. @discussion For virtual devices with multiple constituent devices, this property returns the active switching behavior. This is equal to primaryConstituentDeviceSwitchingBehavior except while recording using an AVCaptureMovieFileOutput configured with a different switching behavior (see -[AVCaptureMovieFileOutput setPrimaryConstituentDeviceSwitchingBehavior:restrictedSwitchingBehaviorConditions]). Devices that do not support constituent device switching return AVCapturePrimaryConstituentDeviceSwitchingBehaviorUnsupported. This property is key-value observable.

func (*AVCaptureDevice) ActiveVideoMaxFrameDuration ¶

func (o *AVCaptureDevice) ActiveVideoMaxFrameDuration() coremedia.CMTime

@property activeVideoMaxFrameDuration @abstract A property indicating the receiver's current active maximum frame duration (the reciprocal of its min frame rate). @discussion An AVCaptureDevice's activeVideoMaxFrameDuration property is the reciprocal of its active minimum frame rate. To limit the min frame rate of the capture device, clients may set this property to a value supported by the receiver's activeFormat (see AVCaptureDeviceFormat's videoSupportedFrameRateRanges property). Clients may set this property's value to kCMTimeInvalid to return activeVideoMaxFrameDuration to its default value for the given activeFormat. -setActiveVideoMaxFrameDuration: throws an NSInvalidArgumentException if set to an unsupported value. -setActiveVideoMaxFrameDuration: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's activeVideoMaxFrameDuration by key value observing this property. On iOS, the receiver's activeVideoMaxFrameDuration resets to its default value under the following conditions: - The receiver's activeFormat changes - The receiver's AVCaptureDeviceInput's session's sessionPreset changes - The receiver's AVCaptureDeviceInput is added to a session When exposureMode is AVCaptureExposureModeCustom, frame rate and exposure duration are interrelated. If you call setExposureModeCustomWithDuration:ISO:completionHandler: with an exposureDuration longer than the current activeVideoMaxFrameDuration, the activeVideoMaxFrameDuration will be lengthened to accommodate the longer exposure time. Setting a shorter exposure duration does not automatically change the activeVideoMinFrameDuration or activeVideoMaxFrameDuration. To explicitly increase the frame rate in custom exposure mode, you must set the activeVideoMaxFrameDuration to a shorter value. If your new max frame duration is shorter than the current exposureDuration, the exposureDuration will shorten as well to accommodate the new frame rate. When autoVideoFrameRateEnabled is true, setting activeVideoMaxFrameDuration throws an NSInvalidArgumentException.

func (*AVCaptureDevice) ActiveVideoMinFrameDuration ¶

func (o *AVCaptureDevice) ActiveVideoMinFrameDuration() coremedia.CMTime

@property activeVideoMinFrameDuration @abstract A property indicating the receiver's current active minimum frame duration (the reciprocal of its max frame rate). @discussion An AVCaptureDevice's activeVideoMinFrameDuration property is the reciprocal of its active maximum frame rate. To limit the max frame rate of the capture device, clients may set this property to a value supported by the receiver's activeFormat (see AVCaptureDeviceFormat's videoSupportedFrameRateRanges property). Clients may set this property's value to kCMTimeInvalid to return activeVideoMinFrameDuration to its default value for the given activeFormat. -setActiveVideoMinFrameDuration: throws an NSInvalidArgumentException if set to an unsupported value. -setActiveVideoMinFrameDuration: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's activeVideoMinFrameDuration by key value observing this property. On iOS, the receiver's activeVideoMinFrameDuration resets to its default value under the following conditions: - The receiver's activeFormat changes - The receiver's AVCaptureDeviceInput's session's sessionPreset changes - The receiver's AVCaptureDeviceInput is added to a session When exposureMode is AVCaptureExposureModeCustom, setting the activeVideoMinFrameDuration affects max frame rate, but not exposureDuration. You may use setExposureModeCustomWithDuration:ISO:completionHandler: to set a shorter exposureDuration than your activeVideoMinFrameDuration, if desired. When autoVideoFrameRateEnabled is true, setting activeVideoMinFrameDuration throws an NSInvalidArgumentException.

func (*AVCaptureDevice) AvailableReactionTypes ¶

func (o *AVCaptureDevice) AvailableReactionTypes() *foundation.NSSet[*foundation.NSString]

@property availableReactionTypes @abstract Returns a list of reaction types which can be passed to performEffectForReaction. @discussion The list may differ between devices, or be affected by changes to active format, and can be key-value observed.

func (*AVCaptureDevice) CameraLensSmudgeDetectionInterval ¶

func (o *AVCaptureDevice) CameraLensSmudgeDetectionInterval() coremedia.CMTime

The camera lens smudge detection interval. “cameraLensSmudgeDetectionInterval“ is set by calling “setCameraLensSmudgeDetectionEnabled:detectionInterval:“. By default, this property returns `kCMTimeInvalid`.

func (*AVCaptureDevice) CameraLensSmudgeDetectionStatus ¶

func (o *AVCaptureDevice) CameraLensSmudgeDetectionStatus() AVCaptureCameraLensSmudgeDetectionStatus

A value specifying the status of camera lens smudge detection. During initial detection execution, “cameraLensSmudgeDetectionStatus“ returns “AVCaptureCameraLensSmudgeDetectionStatusUnknown“ until the detection result settles. Once a detection result is produced, “cameraLensSmudgeDetectionStatus“ returns the most recent detection result. This property can be key-value observed.

func (*AVCaptureDevice) CanPerformReactionEffects ¶

func (o *AVCaptureDevice) CanPerformReactionEffects() bool

@property canPerformReactionEffects @abstract Indicates whether reactions can be performed on a particular AVCaptureDevice. This requires reactionEffectsEnabled to be YES, as well as using a AVCaptureDeviceFormat with reactionEffectsSupported. @discussion This readonly property returns YES when resources for reactions are available on the device instance. When YES, calls to performEffectForReaction: will render on the video feed, otherwise those calls are ignored. It is key-value observable.

func (*AVCaptureDevice) CenterStageRectOfInterest ¶

func (o *AVCaptureDevice) CenterStageRectOfInterest() corefoundation.CGRect

@property centerStageRectOfInterest @abstract Specifies the effective region within the output pixel buffer that will be used to perform Center Stage framing. @discussion Applications that wish to apply additional processing (such as cropping) on top of Center Stage's output can use this property to guide Center Stage's framing. The rectangle's origin is top left and is relative to the coordinate space of the output pixel buffer. The default value of this property is the value CGRectMake(0, 0, 1, 1), where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This rectangle of interest is applied prior to rotation, mirroring or scaling. Pixels outside of this rectangle of interest will be blackened out. Setting this property has no impact on objects specified in the metadata output. -setCenterStageRectOfInterest: throws an NSGenericException if called without first obtaining exclusive access to the receiver using -lockForConfiguration:. -setCenterStageRectOfInterest: throws an NSInvalidArgumentException if none of the AVCaptureDeviceFormats supported by the receiver support CenterStage. -setCenterStageRectOfInterest: throws an NSInvalidArgumentException if +centerStageEnabled is NO on the AVCaptureDevice class. -setCenterStageRectOfInterest: throws an NSInvalidArgumentException if the provided rectOfInterest goes outside the normalized (0-1) coordinate space.

func (*AVCaptureDevice) CinematicVideoCaptureSceneMonitoringStatuses ¶

func (o *AVCaptureDevice) CinematicVideoCaptureSceneMonitoringStatuses() *foundation.NSSet[*foundation.NSString]

func (*AVCaptureDevice) CompanionDeskViewCamera ¶

func (o *AVCaptureDevice) CompanionDeskViewCamera() *AVCaptureDevice

func (*AVCaptureDevice) DefaultRectForExposurePointOfInterest ¶

func (o *AVCaptureDevice) DefaultRectForExposurePointOfInterest(pointOfInterest corefoundation.CGPoint) corefoundation.CGRect

The default rectangle of interest used for a given exposure point of interest. - Parameter pointOfInterest: The point of interest for which you want the default rectangle of interest. For example, pass `(0.5, 0.5)` to get the exposure rectangle of interest used for the default exposure point of interest at `(0.5, 0.5)`. This method returns `CGRectNull` if “exposureRectOfInterestSupported“ returns `false`.

func (*AVCaptureDevice) DefaultRectForFocusPointOfInterest ¶

func (o *AVCaptureDevice) DefaultRectForFocusPointOfInterest(pointOfInterest corefoundation.CGPoint) corefoundation.CGRect

The default rectangle of interest used for a given focus point of interest. - Parameter pointOfInterest: The point of interest for which you want the default rectangle of interest. For example, pass `(0.5, 0.5)` to get the focus rectangle of interest used for the default focus point of interest at `(0.5, 0.5)`. - Note: The particular default rectangle returned depends on the current focus mode. This method returns `CGRectNull` if “focusRectOfInterestSupported“ returns `false`.

func (*AVCaptureDevice) DeviceType ¶

func (o *AVCaptureDevice) DeviceType() *foundation.NSString

func (*AVCaptureDevice) DisplayVideoZoomFactorMultiplier ¶

func (o *AVCaptureDevice) DisplayVideoZoomFactorMultiplier() float64

@property displayVideoZoomFactorMultiplier @abstract A multiplier that can be used with the receiver's videoZoomFactor property for displaying a video zoom factor in a user interface. @discussion In some system user interfaces, like the macOS Video Effects Menu, the video zoom factor value is displayed in a way most appropriate for visual representation and might differ from the videoZoomFactor property value on the receiver by a fixed ratio. For example, if the videoZoomFactor property value is 1.0 and the displayVideoZoomFactorMultiplier property value is 0.5, then multiplying 1.0 and 0.5 produces 0.5 which can be displayed in the UI. Client applications can key value observe this property to update the display video zoom factor values in their UI to stay consistent with Apple's system UIs.

func (*AVCaptureDevice) DynamicAspectRatio ¶

func (o *AVCaptureDevice) DynamicAspectRatio() *foundation.NSString

A key-value observable property indicating the current aspect ratio for a device. This property is initialized to the first “AVCaptureAspectRatio“ listed in the device's activeFormat's “AVCaptureDeviceFormat/supportedDynamicAspectRatios“ property. If the activeFormat's “AVCaptureDeviceFormat/supportedDynamicAspectRatios“ is an empty array, this property returns nil.

func (*AVCaptureDevice) DynamicDimensions ¶

func (o *AVCaptureDevice) DynamicDimensions() coremedia.CMVideoDimensions

A key-value observable property describing the output dimensions of the video buffer based on the device's dynamic aspect ratio. If the device's activeFormat's “AVCaptureDeviceFormat/supportedDynamicAspectRatios“ is an empty array, this property returns {0,0}.

func (*AVCaptureDevice) ExposureMode ¶

func (o *AVCaptureDevice) ExposureMode() AVCaptureExposureMode

@property exposureMode @abstract Indicates current exposure mode of the receiver, if it has adjustable exposure. @discussion The value of this property is an AVCaptureExposureMode that determines the receiver's exposure mode, if it has adjustable exposure. -setExposureMode: throws an NSInvalidArgumentException if set to an unsupported value (see -isExposureModeSupported:). -setExposureMode: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. When using AVCapturePhotoOutput and capturing photos with AVCapturePhotoSettings' photoQualityPrioritization property set to AVCapturePhotoQualityPrioritizationBalanced or higher, the receiver's ISO and exposureDuration values may be overridden when exposing the photo if the scene is dark enough to warrant some form of multi-image fusion to improve quality. To ensure that the receiver's ISO and exposureDuration values are honored while in AVCaptureExposureModeCustom or AVCaptureExposureModeLocked, you must set your AVCapturePhotoSettings.photoQualityPrioritization property to AVCapturePhotoQualityPrioritizationSpeed. The same rule applies if you are using the deprecated AVCapturePhotoSettings.autoStillImageStabilizationEnabled property; you must set it to NO to preserve your custom exposure values in the photo capture. Likewise if you're using AVCaptureStillImageOutput, automaticallyEnablesStillImageStabilizationWhenAvailable must be set to NO to preserve your custom exposure values in a still image capture. Clients can observe automatic changes to the receiver's exposureMode by key value observing this property.

func (*AVCaptureDevice) ExposurePointOfInterest ¶

func (o *AVCaptureDevice) ExposurePointOfInterest() corefoundation.CGPoint

@property exposurePointOfInterest @abstract Indicates current exposure point of interest of the receiver, if it has one. @discussion The value of this property is a CGPoint that determines the receiver's exposure point of interest, if it has adjustable exposure. A value of (0,0) indicates that the camera should adjust exposure based on the top left corner of the image, while a value of (1,1) indicates that it should adjust exposure based on the bottom right corner. The default value is (0.5,0.5). -setExposurePointOfInterest: throws an NSInvalidArgumentException if isExposurePointOfInterestSupported returns NO. -setExposurePointOfInterest: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Note that setting exposurePointOfInterest alone does not initiate an exposure operation. After setting exposurePointOfInterest, call -setExposureMode: to apply the new point of interest.

func (*AVCaptureDevice) ExposureRectOfInterest ¶

func (o *AVCaptureDevice) ExposureRectOfInterest() corefoundation.CGRect

The device's current exposure rectangle of interest, if it has one. The value of this property is a “CGRect“ determining the device's exposure rectangle of interest. Use this as an alternative to setting “exposurePointOfInterest“, as it allows you to specify both a location and size. For example, a value of `CGRectMake(0, 0, 1, 1)` tells the device to use the entire field of view when determining the exposure, while `CGRectMake(0, 0, 0.25, 0.25)` indicates the top left sixteenth, and `CGRectMake(0.75, 0.75, 0.25, 0.25)` indicates the bottom right sixteenth. Setting “exposureRectOfInterest“ throws an `NSInvalidArgumentException` if “exposureRectOfInterestSupported“ returns `false`. Setting “exposureRectOfInterest“ throws an `NSInvalidArgumentException` if your provided rectangle's size is smaller than the “minExposureRectOfInterestSize“. Setting “exposureRectOfInterest“ throws an `NSGenericException` if you call it without first obtaining exclusive access to the device using “AVCaptureDevice/lockForConfiguration:“. Setting “exposureRectOfInterest“ updates the device's “exposurePointOfInterest“ to the center of your provided rectangle of interest. If you later set the device's “exposurePointOfInterest“, the “exposureRectOfInterest“ resets to the default sized rectangle of interest for the new exposure point of interest. If you change your “AVCaptureDevice/activeFormat“, the point of interest and rectangle of interest both revert to their default values. You can observe automatic changes to the device's “exposureRectOfInterest“ by key-value observing this property. - Note: Setting “exposureRectOfInterest“ alone does not initiate an exposure operation. After setting “exposureRectOfInterest“, set “exposureMode“ to apply the new rectangle of interest.

func (*AVCaptureDevice) FallbackPrimaryConstituentDevices ¶

func (o *AVCaptureDevice) FallbackPrimaryConstituentDevices() *foundation.NSArray[*AVCaptureDevice]

@property fallbackPrimaryConstituentDevices @abstract The constituent devices that may be used as a fallback device when a constituent device with a longer focal length becomes limited by its light sensitivity or minimum focus distance. @discussion This may only be set to the supportedFallbackPrimaryConstituentDevices or a subset thereof. By default this is set to all supportedFallbackPrimaryConstituentDevices. This property will throw an NSInvalidArgumentException if the array includes any device not reported in supportedFallbackPrimaryConstituentDevices. This property is key-value observable.

func (*AVCaptureDevice) FlashMode ¶

func (o *AVCaptureDevice) FlashMode() AVCaptureFlashMode

@property flashMode @abstract Indicates current mode of the receiver's flash, if it has one. @discussion The value of this property is an AVCaptureFlashMode that determines the mode of the receiver's flash, if it has one. -setFlashMode: throws an NSInvalidArgumentException if set to an unsupported value (see -isFlashModeSupported:). -setFlashMode: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's flashMode by key value observing this property. When using AVCapturePhotoOutput, AVCaptureDevice's flashMode property is ignored. You specify flashMode on a per photo basis by setting the AVCapturePhotoSettings.flashMode property.

func (*AVCaptureDevice) FocusMode ¶

func (o *AVCaptureDevice) FocusMode() AVCaptureFocusMode

@property focusMode @abstract Indicates current focus mode of the receiver, if it has one. @discussion The value of this property is an AVCaptureFocusMode that determines the receiver's focus mode, if it has one. -setFocusMode: throws an NSInvalidArgumentException if set to an unsupported value (see -isFocusModeSupported:). -setFocusMode: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's focusMode by key value observing this property.

func (*AVCaptureDevice) FocusPointOfInterest ¶

func (o *AVCaptureDevice) FocusPointOfInterest() corefoundation.CGPoint

@property focusPointOfInterest @abstract Indicates current focus point of interest of the receiver, if it has one. @discussion The value of this property is a CGPoint that determines the receiver's focus point of interest, if it has one. A value of (0,0) indicates that the camera should focus on the top left corner of the image, while a value of (1,1) indicates that it should focus on the bottom right. The default value is (0.5,0.5). -setFocusPointOfInterest: throws an NSInvalidArgumentException if isFocusPointOfInterestSupported returns NO. -setFocusPointOfInterest: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's focusPointOfInterest by key value observing this property. Note that setting focusPointOfInterest alone does not initiate a focus operation. After setting focusPointOfInterest, call -setFocusMode: to apply the new point of interest.

func (*AVCaptureDevice) FocusRectOfInterest ¶

func (o *AVCaptureDevice) FocusRectOfInterest() corefoundation.CGRect

The device's current focus rectangle of interest, if it has one. The value of this property is a “CGRect“ determining the device's focus rectangle of interest. Use this as an alternative to setting “focusPointOfInterest“, as it allows you to specify both a location and size. For example, a value of `CGRectMake(0, 0, 1, 1)` tells the device to use the entire field of view when determining the focus, while `CGRectMake(0, 0, 0.25, 0.25)` indicates the top left sixteenth, and `CGRectMake(0.75, 0.75, 0.25, 0.25)` indicates the bottom right sixteenth. Setting “focusRectOfInterest“ throws an `NSInvalidArgumentException` if “focusRectOfInterestSupported“ returns `false`. Setting “focusRectOfInterest“ throws an `NSInvalidArgumentException` if your provided rectangle's size is smaller than the “minFocusRectOfInterestSize“. Setting “focusRectOfInterest“ throws an `NSGenericException` if you call it without first obtaining exclusive access to the device using “AVCaptureDevice/lockForConfiguration:“. Setting “focusRectOfInterest“ updates the device's “focusPointOfInterest“ to the center of your provided rectangle of interest. If you later set the device's “focusPointOfInterest“, the “focusRectOfInterest“ resets to the default sized rectangle of interest for the new focus point of interest. If you change your “AVCaptureDevice/activeFormat“, the point of interest and rectangle of interest both revert to their default values. You can observe automatic changes to the device's “focusRectOfInterest“ by key-value observing this property. - Note: Setting “focusRectOfInterest“ alone does not initiate a focus operation. After setting “focusRectOfInterest“, set “focusMode“ to apply the new rectangle of interest.

func (*AVCaptureDevice) Formats ¶

@property formats @abstract An array of AVCaptureDeviceFormat objects supported by the receiver. @discussion This property can be used to enumerate the formats natively supported by the receiver. The capture device's activeFormat property may be set to one of the formats in this array. Clients can observe automatic changes to the receiver's formats by key value observing this property.

func (*AVCaptureDevice) HasFlash ¶

func (o *AVCaptureDevice) HasFlash() bool

@property hasFlash @abstract Indicates whether the receiver has a flash. @discussion The value of this property is a BOOL indicating whether the receiver has a flash. The receiver's flashMode property can only be set when this property returns YES.

func (*AVCaptureDevice) HasMediaType ¶

func (o *AVCaptureDevice) HasMediaType(mediaType *foundation.NSString) bool

@method hasMediaType: @abstract Returns whether the receiver provides media with the given media type. @param mediaType A media type, such as AVMediaTypeVideo, AVMediaTypeAudio, or AVMediaTypeMuxed. @result YES if the device outputs the given media type, NO otherwise. @discussion Media type constants are defined in AVMediaFormat.h.

func (*AVCaptureDevice) HasTorch ¶

func (o *AVCaptureDevice) HasTorch() bool

@property hasTorch @abstract Indicates whether the receiver has a torch. @discussion The value of this property is a BOOL indicating whether the receiver has a torch. The receiver's torchMode property can only be set when this property returns YES.

func (*AVCaptureDevice) InputSources ¶

@property inputSources @abstract An array of AVCaptureDeviceInputSource objects supported by the receiver. @discussion Some devices can capture data from one of multiple data sources (different input jacks on the same audio device, for example). For devices with multiple possible data sources, inputSources can be used to enumerate the possible choices. Clients can observe automatic changes to the receiver's inputSources by key value observing this property.

func (*AVCaptureDevice) IsAdjustingExposure ¶

func (o *AVCaptureDevice) IsAdjustingExposure() bool

@property adjustingExposure @abstract Indicates whether the receiver is currently adjusting camera exposure. @discussion The value of this property is a BOOL indicating whether the receiver's camera exposure is being automatically adjusted because its exposure mode is AVCaptureExposureModeAutoExpose or AVCaptureExposureModeContinuousAutoExposure. Clients can observe the value of this property to determine whether the camera exposure is stable or is being automatically adjusted.

func (*AVCaptureDevice) IsAdjustingFocus ¶

func (o *AVCaptureDevice) IsAdjustingFocus() bool

@property adjustingFocus @abstract Indicates whether the receiver is currently performing a focus scan to adjust focus. @discussion The value of this property is a BOOL indicating whether the receiver's camera focus is being automatically adjusted by means of a focus scan, because its focus mode is AVCaptureFocusModeAutoFocus or AVCaptureFocusModeContinuousAutoFocus. Clients can observe the value of this property to determine whether the camera's focus is stable. @seealso lensPosition @seealso AVCaptureAutoFocusSystem

func (*AVCaptureDevice) IsAdjustingWhiteBalance ¶

func (o *AVCaptureDevice) IsAdjustingWhiteBalance() bool

@property adjustingWhiteBalance @abstract Indicates whether the receiver is currently adjusting camera white balance. @discussion The value of this property is a BOOL indicating whether the receiver's camera white balance is being automatically adjusted because its white balance mode is AVCaptureWhiteBalanceModeAutoWhiteBalance or AVCaptureWhiteBalanceModeContinuousAutoWhiteBalance. Clients can observe the value of this property to determine whether the camera white balance is stable or is being automatically adjusted.

func (*AVCaptureDevice) IsAutoVideoFrameRateEnabled ¶

func (o *AVCaptureDevice) IsAutoVideoFrameRateEnabled() bool

Indicates whether the receiver should enable auto video frame rate. When you enable this property, the device automatically adjusts the active frame rate, depending on light level. Under low light conditions, it decreases the frame rate to properly expose the scene. For formats with a maximum frame rate of 30 fps, the device switches the frame rate between 30 - 24. For formats with a maximum frame rate of 60 fps, the device switches the frame rate between 60 - 30 - 24. Setting this property throws an `NSInvalidArgumentException` if the active format's “AVCaptureDeviceFormat/autoVideoFrameRateSupported“ returns `false`. When you change the device's active format, this property resets to its default value of `false`. If you set this property to `true`, frame rate is under device control, and you may not set “activeVideoMinFrameDuration“ or “activeVideoMaxFrameDuration“. Doing so throws an `NSInvalidArgumentException`. - Note: Setting this property to `true` throws an `NSInvalidArgumentException` if “videoFrameDurationLocked“ or “followingExternalSyncDevice“ are `true`.

func (*AVCaptureDevice) IsBackgroundReplacementActive ¶

func (o *AVCaptureDevice) IsBackgroundReplacementActive() bool

@property backgroundReplacementActive @abstract Indicates whether Background Replacement is currently active on a particular AVCaptureDevice. @discussion This property is key-value observable.

func (*AVCaptureDevice) IsCameraLensSmudgeDetectionEnabled ¶

func (o *AVCaptureDevice) IsCameraLensSmudgeDetectionEnabled() bool

Whether camera lens smudge detection is enabled. You enable lens smudge detection by calling “setCameraLensSmudgeDetectionEnabled:detectionInterval:“. By default, this property is returns `false`.

func (*AVCaptureDevice) IsCenterStageActive ¶

func (o *AVCaptureDevice) IsCenterStageActive() bool

@property centerStageActive @abstract Indicates whether Center Stage is currently active on a particular AVCaptureDevice. @discussion This readonly property returns YES when Center Stage is currently active on the receiver. When active, the camera automatically adjusts to keep people optimally framed within the field of view. The field of view may pan, tighten or widen as needed. Certain restrictions come into play when Center Stage is active: - The device's minAvailableVideoZoomFactor and maxAvailableVideoZoomFactor become restricted (see AVCaptureDeviceFormat's videoMinZoomFactorForCenterStage and videoMaxZoomFactorForCenterStage). - The device's activeVideoMinFrameDuration and activeVideoMaxFrameDuration are limited (see AVCaptureDeviceFormat's videoFrameRateRangeForCenterStage). Center Stage may be enabled via user control or application control, depending on the current +AVCaptureDevice.centerStageControlMode. When +AVCaptureDevice.centerStageEnabled is YES, a particular AVCaptureDevice instance may return YES for this property, depending whether it supports the feature in its current configuration. Some device features are mutually exclusive to Center Stage: - If depth data delivery is enabled on any output, such as AVCaptureDepthDataOutput, or -AVCapturePhotoOutput.depthDataDeliveryEnabled, Center Stage is deactivated. - If geometricDistortionCorrectionSupported is YES, geometricDistortionCorrectionEnabled must also be YES, or Center Stage is deactivated. This property is key-value observable.

func (*AVCaptureDevice) IsConnected ¶

func (o *AVCaptureDevice) IsConnected() bool

@property connected @abstract Indicates whether the device is connected and available to the system. @discussion The value of this property is a BOOL indicating whether the device represented by the receiver is connected and available for use as a capture device. Clients can key value observe the value of this property to be notified when a device is no longer available. When the value of this property becomes NO for a given instance, it will not become YES again. If the same physical device again becomes available to the system, it will be represented using a new instance of AVCaptureDevice.

func (*AVCaptureDevice) IsContinuityCamera ¶

func (o *AVCaptureDevice) IsContinuityCamera() bool

func (*AVCaptureDevice) IsExposureModeSupported ¶

func (o *AVCaptureDevice) IsExposureModeSupported(exposureMode AVCaptureExposureMode) bool

@method isExposureModeSupported: @abstract Returns whether the receiver supports the given exposure mode. @param exposureMode An AVCaptureExposureMode to be checked. @result YES if the receiver supports the given exposure mode, NO otherwise. @discussion The receiver's exposureMode property can only be set to a certain mode if this method returns YES for that mode.

func (*AVCaptureDevice) IsExposurePointOfInterestSupported ¶

func (o *AVCaptureDevice) IsExposurePointOfInterestSupported() bool

@property exposurePointOfInterestSupported: @abstract Indicates whether the receiver supports exposure points of interest. @discussion The receiver's exposurePointOfInterest property can only be set if this property returns YES.

func (*AVCaptureDevice) IsExposureRectOfInterestSupported ¶

func (o *AVCaptureDevice) IsExposureRectOfInterestSupported() bool

Whether the device supports exposure rectangles of interest. You may only set the device's “exposureRectOfInterest“ property if this property returns `true`.

func (*AVCaptureDevice) IsFlashAvailable ¶

func (o *AVCaptureDevice) IsFlashAvailable() bool

@property flashAvailable @abstract Indicates whether the receiver's flash is currently available for use. @discussion The value of this property is a BOOL indicating whether the receiver's flash is currently available. The flash may become unavailable if, for example, the device overheats and needs to cool off. This property is key-value observable.

func (*AVCaptureDevice) IsFlashModeSupported ¶

func (o *AVCaptureDevice) IsFlashModeSupported(flashMode AVCaptureFlashMode) bool

@method isFlashModeSupported: @abstract Returns whether the receiver supports the given flash mode. @param flashMode An AVCaptureFlashMode to be checked. @result YES if the receiver supports the given flash mode, NO otherwise. @discussion The receiver's flashMode property can only be set to a certain mode if this method returns YES for that mode.

func (*AVCaptureDevice) IsFocusModeSupported ¶

func (o *AVCaptureDevice) IsFocusModeSupported(focusMode AVCaptureFocusMode) bool

@method isFocusModeSupported: @abstract Returns whether the receiver supports the given focus mode. @param focusMode An AVCaptureFocusMode to be checked. @result YES if the receiver supports the given focus mode, NO otherwise. @discussion The receiver's focusMode property can only be set to a certain mode if this method returns YES for that mode.

func (*AVCaptureDevice) IsFocusPointOfInterestSupported ¶

func (o *AVCaptureDevice) IsFocusPointOfInterestSupported() bool

@property focusPointOfInterestSupported @abstract Indicates whether the receiver supports focus points of interest. @discussion The receiver's focusPointOfInterest property can only be set if this property returns YES.

func (*AVCaptureDevice) IsFocusRectOfInterestSupported ¶

func (o *AVCaptureDevice) IsFocusRectOfInterestSupported() bool

Whether the receiver supports focus rectangles of interest. You may only set the device's “focusRectOfInterest“ property if this property returns `true`.

func (*AVCaptureDevice) IsFollowingExternalSyncDevice ¶

func (o *AVCaptureDevice) IsFollowingExternalSyncDevice() bool

Whether the device is following an external sync device. See “AVCaptureDeviceInput/followExternalSyncDevice:videoFrameDuration:delegate:“ for more information on external sync.

func (*AVCaptureDevice) IsInUseByAnotherApplication ¶

func (o *AVCaptureDevice) IsInUseByAnotherApplication() bool

@property inUseByAnotherApplication @abstract Indicates whether the device is in use by another application. @discussion The value of this property is a BOOL indicating whether the device represented by the receiver is in use by another application. Clients can key value observe the value of this property to be notified when another app starts or stops using this device.

func (*AVCaptureDevice) IsPortraitEffectActive ¶

func (o *AVCaptureDevice) IsPortraitEffectActive() bool

@property portraitEffectActive @abstract Indicates whether Portrait Effect is currently active for a particular AVCaptureDevice. @discussion This readonly property returns YES when Portrait Effect is currently active on the receiver. When active, the device blurs the background, simulating a shallow depth of field effect. Certain restrictions come into play when Portrait Effect is active: - The device's activeVideoMinFrameDuration and activeVideoMaxFrameDuration are limited (see AVCaptureDeviceFormat's videoFrameRateRangeForPortraitEffect). Note that when +AVCaptureDevice.portraitEffectEnabled is YES, a particular AVCaptureDevice instance may return YES for this property, depending whether it supports the feature in its current configuration. This property is key-value observable.

func (*AVCaptureDevice) IsStudioLightActive ¶

func (o *AVCaptureDevice) IsStudioLightActive() bool

@property studioLightActive @abstract Indicates whether Studio Light is currently active on a particular AVCaptureDevice. @discussion This readonly property returns YES when Studio Light is currently active on the receiver. When active, the subject's face is artificially lit to simulate the presence of a studio light near the camera.

func (*AVCaptureDevice) IsSuspended ¶

func (o *AVCaptureDevice) IsSuspended() bool

@property suspended @abstract Indicates whether the device is suspended. @discussion The value of this property is a BOOL indicating whether the device represented by the receiver is currently suspended. Some devices disallow data capture due to a feature on the device. For example, isSuspended returns YES for the external iSight when its privacy iris is closed, or for the internal iSight on a notebook when the notebook's display is closed. Clients can key value observe the value of this property to be notified when the device becomes suspended or unsuspended.

func (*AVCaptureDevice) IsTorchActive ¶

func (o *AVCaptureDevice) IsTorchActive() bool

@property torchActive @abstract Indicates whether the receiver's torch is currently active. @discussion The value of this property is a BOOL indicating whether the receiver's torch is currently active. If the current torchMode is AVCaptureTorchModeAuto and isTorchActive is YES, the torch will illuminate once a recording starts (see AVCaptureOutput.h -startRecordingToOutputFileURL:recordingDelegate:). This property is key-value observable.

func (*AVCaptureDevice) IsTorchAvailable ¶

func (o *AVCaptureDevice) IsTorchAvailable() bool

@property torchAvailable @abstract Indicates whether the receiver's torch is currently available for use. @discussion The value of this property is a BOOL indicating whether the receiver's torch is currently available. The torch may become unavailable if, for example, the device overheats and needs to cool off. This property is key-value observable.

func (*AVCaptureDevice) IsTorchModeSupported ¶

func (o *AVCaptureDevice) IsTorchModeSupported(torchMode AVCaptureTorchMode) bool

@method isTorchModeSupported: @abstract Returns whether the receiver supports the given torch mode. @param torchMode An AVCaptureTorchMode to be checked. @result YES if the receiver supports the given torch mode, NO otherwise. @discussion The receiver's torchMode property can only be set to a certain mode if this method returns YES for that mode.

func (*AVCaptureDevice) IsVideoFrameDurationLocked ¶

func (o *AVCaptureDevice) IsVideoFrameDurationLocked() bool

Whether the device's video frame rate (expressed as a duration) is currently locked. Returns `true` when an “AVCaptureDeviceInput“ associated with the device has its “AVCaptureDeviceInput/activeLockedVideoFrameDuration“ property set to something other than `kCMTimeInvalid`. See “AVCaptureDeviceInput/activeLockedVideoFrameDuration“ for more information on video frame duration locking.

func (*AVCaptureDevice) IsWhiteBalanceModeSupported ¶

func (o *AVCaptureDevice) IsWhiteBalanceModeSupported(whiteBalanceMode AVCaptureWhiteBalanceMode) bool

@method isWhiteBalanceModeSupported: @abstract Returns whether the receiver supports the given white balance mode. @param whiteBalanceMode An AVCaptureWhiteBalanceMode to be checked. @result YES if the receiver supports the given white balance mode, NO otherwise. @discussion The receiver's whiteBalanceMode property can only be set to a certain mode if this method returns YES for that mode.

func (*AVCaptureDevice) LinkedDevices ¶

func (o *AVCaptureDevice) LinkedDevices() *foundation.NSArray[*AVCaptureDevice]

@property linkedDevices @abstract An array of AVCaptureDevice objects physically linked to the receiver. @discussion The value of this property is an array of AVCaptureDevice objects that are a part of the same physical device as the receiver. For example, for the external iSight camera, linkedDevices returns an array containing an AVCaptureDevice for the external iSight microphone.

func (*AVCaptureDevice) LocalizedName ¶

func (o *AVCaptureDevice) LocalizedName() *foundation.NSString

@property localizedName @abstract A localized human-readable name for the receiver. @discussion This property can be used for displaying the name of a capture device in a user interface.

func (*AVCaptureDevice) LockForConfiguration ¶

func (o *AVCaptureDevice) LockForConfiguration() (bool, error)

@method lockForConfiguration: @abstract Requests exclusive access to configure device hardware properties. @param outError On return, if the device could not be locked, points to an NSError describing why the failure occurred. @result A BOOL indicating whether the device was successfully locked for configuration. @discussion In order to set hardware properties on an AVCaptureDevice, such as focusMode and exposureMode, clients must first acquire a lock on the device. Clients should only hold the device lock if they require settable device properties to remain unchanged. Holding the device lock unnecessarily may degrade capture quality in other applications sharing the device.

func (*AVCaptureDevice) Manufacturer ¶

func (o *AVCaptureDevice) Manufacturer() *foundation.NSString

@property manufacturer @abstract The human-readable manufacturer name for the receiver. @discussion This property can be used to identify capture devices from a particular manufacturer. All Apple devices return "Apple Inc.". Devices from third party manufacturers may return an empty string.

func (*AVCaptureDevice) MinExposureRectOfInterestSize ¶

func (o *AVCaptureDevice) MinExposureRectOfInterestSize() corefoundation.CGSize

The minimum size you may use when specifying a rectangle of interest. The size returned is in normalized coordinates, and depends on the current “AVCaptureDevice/activeFormat“. If “exposureRectOfInterestSupported“ returns `false`, this property returns { 0, 0 }.

func (*AVCaptureDevice) MinFocusRectOfInterestSize ¶

func (o *AVCaptureDevice) MinFocusRectOfInterestSize() corefoundation.CGSize

The minimum size you may use when specifying a rectangle of interest. The size returned is in normalized coordinates, and depends on the current “AVCaptureDevice/activeFormat“. If “focusRectOfInterestSupported“ returns `false`, this property returns { 0, 0 }.

func (*AVCaptureDevice) MinSupportedExternalSyncFrameDuration ¶

func (o *AVCaptureDevice) MinSupportedExternalSyncFrameDuration() coremedia.CMTime

The minimum frame duration that can be passed as the `videoFrameDuration` when directing your device input to follow an external sync device. Use this property as the minimum allowable frame duration to pass to “AVCaptureDeviceInput/follow:externalSyncDevice:videoFrameDuration:delegate:“ when you want to follow an external sync device. This property returns `kCMTimeInvalid` when the device's' current configuration does not support external sync device following.

func (*AVCaptureDevice) MinSupportedLockedVideoFrameDuration ¶

func (o *AVCaptureDevice) MinSupportedLockedVideoFrameDuration() coremedia.CMTime

The maximum frame rate (expressed as a minimum duration) that can be set on an input associated with this device. `kCMTimeInvalid` is returned when the device or its current configuration does not support locked frame rate. Use “AVCaptureDeviceInput/activeLockedVideoFrameDuration“ to set the locked frame rate on the input.

func (*AVCaptureDevice) MinimumFocusDistance ¶

func (o *AVCaptureDevice) MinimumFocusDistance() int

@property minimumFocusDistance @abstract A property indicating the minimum focus distance. @discussion The minimum focus distance is given in millimeters, -1 if unknown. For virtual cameras (AVCaptureDeviceTypeBuiltInDualCamera, AVCaptureDeviceTypeBuiltInTripleCamera, etc.), the value reported is the smallest minimum focus distance of the auto-focus-capable cameras that it sources.

func (*AVCaptureDevice) ModelID ¶

func (o *AVCaptureDevice) ModelID() *foundation.NSString

@property modelID @abstract The model ID of the receiver. @discussion The value of this property is an identifier unique to all devices of the same model. The value is persistent across device connections and disconnections, and across different systems. For example, the model ID of the camera built in to two identical iPhone models will be the same even though they are different physical devices.

func (*AVCaptureDevice) PerformEffectForReaction ¶

func (o *AVCaptureDevice) PerformEffectForReaction(reactionType *foundation.NSString)

@method performEffectForReaction: @abstract Triggers a specified reaction on the video stream. @param reactionType Indicates which reaction to perform. @discussion The entries in reactionEffectsInProgress may not reflect one-to-one against calls to this method. Depending on reaction style or resource limits, triggering multiple overlapping reactions of the same type may be coalesced into extending an existing reaction rather than overlaying a new one. The reactionType requested must be one of those listed in availableReactionTypes or an exception will be thrown. Performing a reaction when canPerformReactionEffects is NO is ignored, and VoIP applications are encouraged to transmit and display such reactions outside of the video feed.

func (*AVCaptureDevice) Position ¶

func (*AVCaptureDevice) PrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions ¶

func (o *AVCaptureDevice) PrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions() AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions

@property primaryConstituentDeviceRestrictedSwitchingBehaviorConditions @abstract The primaryConstituentDeviceRestrictedSwitchingBehaviorConditions as set by -[AVCaptureDevice setPrimaryConstituentDeviceSwitchingBehavior:restrictedSwitchingBehaviorConditions:]. @discussion By default, this propety is set to AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionNone. This property is key-value observable.

func (*AVCaptureDevice) PrimaryConstituentDeviceSwitchingBehavior ¶

func (o *AVCaptureDevice) PrimaryConstituentDeviceSwitchingBehavior() AVCapturePrimaryConstituentDeviceSwitchingBehavior

@property primaryConstituentDeviceSwitchingBehavior @abstract The primaryConstituentDeviceSwitchingBehavior as set by -[AVCaptureDevice setPrimaryConstituentDeviceSwitchingBehavior:restrictedSwitchingBehaviorConditions:]. @discussion By default, this property is set to AVCapturePrimaryConstituentDeviceSwitchingBehaviorAuto for AVCaptureDevices that support it. This property is key-value observable.

func (*AVCaptureDevice) ReactionEffectsInProgress ¶

func (o *AVCaptureDevice) ReactionEffectsInProgress() *foundation.NSArray[*AVCaptureReactionEffectState]

@property reactionEffectsInProgress @abstract Contains an array of reaction effects that are currently being performed by the device, sorted by timestamp. If observing old and new values in the KVO callback, the reaction effects which are still running in the new array will have kCMTimeInvalid as their endTime property. Reaction effects which have ended will only be in the old array, and will have their endTime property set to the presentation time of the first frame where the reaction effect was no longer present. @discussion Reaction effects which are triggered by either a call to performEffectForReaction: or by the automatic gesture detection will be reflected in this array. It is key-value observable to be notified when reaction effects begin or end.

func (*AVCaptureDevice) SetActiveColorSpace ¶

func (o *AVCaptureDevice) SetActiveColorSpace(activeColorSpace AVCaptureColorSpace)

func (*AVCaptureDevice) SetActiveFormat ¶

func (o *AVCaptureDevice) SetActiveFormat(activeFormat *AVCaptureDeviceFormat)

func (*AVCaptureDevice) SetActiveInputSource ¶

func (o *AVCaptureDevice) SetActiveInputSource(activeInputSource *AVCaptureDeviceInputSource)

func (*AVCaptureDevice) SetActiveVideoMaxFrameDuration ¶

func (o *AVCaptureDevice) SetActiveVideoMaxFrameDuration(activeVideoMaxFrameDuration coremedia.CMTime)

func (*AVCaptureDevice) SetActiveVideoMinFrameDuration ¶

func (o *AVCaptureDevice) SetActiveVideoMinFrameDuration(activeVideoMinFrameDuration coremedia.CMTime)

func (*AVCaptureDevice) SetAutoVideoFrameRateEnabled ¶

func (o *AVCaptureDevice) SetAutoVideoFrameRateEnabled(autoVideoFrameRateEnabled bool)

func (*AVCaptureDevice) SetCameraLensSmudgeDetectionEnabledDetectionInterval ¶

func (o *AVCaptureDevice) SetCameraLensSmudgeDetectionEnabledDetectionInterval(cameraLensSmudgeDetectionEnabled bool, detectionInterval coremedia.CMTime)

Specify whether to enable camera lens smudge detection, and the interval time between each run of detections. - Parameter cameraLensSmudgeDetectionEnabled: Specify whether camera lens smudge detection should be enabled. - Parameter detectionInterval: The detection running interval if detection is enabled. Each run of detection processes frames over a short period, and produces one detection result. Use `detectionInterval` to specify the interval time between each run of detections. For example, when “cameraLensSmudgeDetectionEnabled“ is set to `true` and `detectionInterval` is set to 1 minute, detection runs once per minute, and updates “AVCaptureCameraLensSmudgeDetectionStatus“. If `detectionInterval` is set to “kCMTimeInvalid“, detection runs only once after the session starts. If `detectionInterval` is set to “kCMTimeZero“, detection runs continuously. “AVCaptureDevice“ throws an `NSInvalidArgumentException` if the “AVCaptureDeviceFormat/cameraLensSmudgeDetectionSupported“ property on the current active format returns `false`. Enabling detection requires a lengthy reconfiguration of the capture render pipeline, so you should enable detection before calling “AVCaptureSession/startRunning“ or within “AVCaptureSession/beginConfiguration“ and “AVCaptureSession/commitConfiguration“ while running.

func (*AVCaptureDevice) SetCenterStageRectOfInterest ¶

func (o *AVCaptureDevice) SetCenterStageRectOfInterest(centerStageRectOfInterest corefoundation.CGRect)

func (*AVCaptureDevice) SetCinematicVideoFixedFocusAtPointFocusMode ¶

func (o *AVCaptureDevice) SetCinematicVideoFixedFocusAtPointFocusMode(point corefoundation.CGPoint, focusMode AVCaptureCinematicVideoFocusMode)

Fix focus at a distance. - Parameter point: A normalized point of interest (i.e., [0,1]) in the coordinate space of the device. - Parameter focusMode: Specify whether to focus strongly or weakly. The distance at which focus is set is determined internally using signals such as depth data.

func (*AVCaptureDevice) SetCinematicVideoTrackingFocusAtPointFocusMode ¶

func (o *AVCaptureDevice) SetCinematicVideoTrackingFocusAtPointFocusMode(point corefoundation.CGPoint, focusMode AVCaptureCinematicVideoFocusMode)

Focus on and start tracking an object if it can be detected at the region specified by the point. - Parameter point: A normalized point of interest (i.e., [0,1]) in the coordinate space of the device. - Parameter focusMode: Specify whether to focus strongly or weakly.

func (*AVCaptureDevice) SetCinematicVideoTrackingFocusWithDetectedObjectIDFocusMode ¶

func (o *AVCaptureDevice) SetCinematicVideoTrackingFocusWithDetectedObjectIDFocusMode(detectedObjectID int, focusMode AVCaptureCinematicVideoFocusMode)

Focus on and start tracking a detected object. - Parameter detectedObjectID: The ID of the detected object. - Parameter focusMode: Specify whether to focus strongly or weakly.

func (*AVCaptureDevice) SetDynamicAspectRatioCompletionHandler ¶

func (o *AVCaptureDevice) SetDynamicAspectRatioCompletionHandler(dynamicAspectRatio *foundation.NSString, handler objc.Block)

Updates the dynamic aspect ratio of the device. - Parameter dynamicAspectRatio: The new “AVCaptureAspectRatio“ the device should output. - Parameter handler: A block called by the device when `dynamicAspectRatio` is set to the value specified. If you call “setDynamicAspectRatio:completionHandler:“ multiple times, the completion handlers are called in FIFO order. The block receives a timestamp which matches that of the first buffer to which all settings have been applied. Note that the timestamp is synchronized to the device clock, and thus must be converted to the “AVCaptureSession/synchronizationClock“ prior to comparison with the timestamps of buffers delivered via an “AVCaptureVideoDataOutput“. You may pass `nil` for the `handler` parameter if you do not need to know when the operation completes. This is the only way of setting “dynamicAspectRatio“. This method throws an `NSInvalidArgumentException` if `dynamicAspectRatio` is not a supported aspect ratio found in the device's activeFormat's “AVCaptureDeviceFormat/supportedDynamicAspectRatios“. This method throws an `NSGenericException` if you call it without first obtaining exclusive access to the device using “AVCaptureDevice/lockForConfiguration:“.

func (*AVCaptureDevice) SetExposureMode ¶

func (o *AVCaptureDevice) SetExposureMode(exposureMode AVCaptureExposureMode)

func (*AVCaptureDevice) SetExposurePointOfInterest ¶

func (o *AVCaptureDevice) SetExposurePointOfInterest(exposurePointOfInterest corefoundation.CGPoint)

func (*AVCaptureDevice) SetExposureRectOfInterest ¶

func (o *AVCaptureDevice) SetExposureRectOfInterest(exposureRectOfInterest corefoundation.CGRect)

func (*AVCaptureDevice) SetFallbackPrimaryConstituentDevices ¶

func (o *AVCaptureDevice) SetFallbackPrimaryConstituentDevices(fallbackPrimaryConstituentDevices *foundation.NSArray[*AVCaptureDevice])

func (*AVCaptureDevice) SetFlashMode ¶

func (o *AVCaptureDevice) SetFlashMode(flashMode AVCaptureFlashMode)

func (*AVCaptureDevice) SetFocusMode ¶

func (o *AVCaptureDevice) SetFocusMode(focusMode AVCaptureFocusMode)

func (*AVCaptureDevice) SetFocusPointOfInterest ¶

func (o *AVCaptureDevice) SetFocusPointOfInterest(focusPointOfInterest corefoundation.CGPoint)

func (*AVCaptureDevice) SetFocusRectOfInterest ¶

func (o *AVCaptureDevice) SetFocusRectOfInterest(focusRectOfInterest corefoundation.CGRect)

func (*AVCaptureDevice) SetPrimaryConstituentDeviceSwitchingBehaviorRestrictedSwitchingBehaviorConditions ¶

func (o *AVCaptureDevice) SetPrimaryConstituentDeviceSwitchingBehaviorRestrictedSwitchingBehaviorConditions(switchingBehavior AVCapturePrimaryConstituentDeviceSwitchingBehavior, restrictedSwitchingBehaviorConditions AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions)

@method setPrimaryConstituentDeviceSwitchingBehavior:restrictedSwitchingBehaviorConditions: @abstract The switching behavior and conditions, unless overwritten via -[AVCaptureMovieFileOutput setPrimaryConstituentDeviceSwitchingBehavior:restrictedSwitchingBehaviorConditions]. @param switchingBehavior The desired switching behavior. @param restrictedSwitchingBehaviorConditions The desired conditions for restricting camera switching. This must be set to AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionNone whenever switchingBehavior is not equal to AVCapturePrimaryConstituentDeviceSwitchingBehaviorRestricted. @discussion The switching behavior may be overridden on the AVCaptureMovieFileOutput while recording (see -[AVCaptureMovieFileOutput setPrimaryConstituentDeviceSwitchingBehavior:restrictedSwitchingBehaviorConditions]). This method throws an NSInvalidArgumentException if constituent device switching is not supported by the receiver or if restrictedSwitchingBehaviorConditions is not equal to AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionNone and switchingBehavior is not equal to AVCapturePrimaryConstituentDeviceSwitchingBehaviorRestricted.

func (*AVCaptureDevice) SetTorchMode ¶

func (o *AVCaptureDevice) SetTorchMode(torchMode AVCaptureTorchMode)

func (*AVCaptureDevice) SetTorchModeOnWithLevelError ¶

func (o *AVCaptureDevice) SetTorchModeOnWithLevelError(torchLevel float32) (bool, error)

@method setTorchModeOnWithLevel:error: @abstract Sets the current mode of the receiver's torch to AVCaptureTorchModeOn at the specified level. @discussion This method sets the torch mode to AVCaptureTorchModeOn at a specified level. torchLevel must be a value between 0 and 1, or the special value AVCaptureMaxAvailableTorchLevel. The specified value may not be available if the iOS device is too hot. This method throws an NSInvalidArgumentException if set to an unsupported level. If the specified level is valid, but unavailable, the method returns NO with AVErrorTorchLevelUnavailable. -setTorchModeOnWithLevel:error: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's torchMode by key value observing the torchMode property.

func (*AVCaptureDevice) SetTransportControlsPlaybackModeSpeed ¶

func (o *AVCaptureDevice) SetTransportControlsPlaybackModeSpeed(mode AVCaptureDeviceTransportControlsPlaybackMode, speed float32)

@method setTransportControlsPlaybackMode:speed: @abstract Sets both the transport controls playback mode and speed in a single method. @param mode A AVCaptureDeviceTransportControlsPlaybackMode indicating whether the deck should be put into play mode. @param speed A AVCaptureDeviceTransportControlsSpeed indicating the speed at which to wind or play the tape. @discussion A method for setting the receiver's transport controls playback mode and speed. The receiver must be locked for configuration using lockForConfiguration: before clients can set this method, otherwise an NSGenericException is thrown.

func (*AVCaptureDevice) SetWhiteBalanceMode ¶

func (o *AVCaptureDevice) SetWhiteBalanceMode(whiteBalanceMode AVCaptureWhiteBalanceMode)

func (*AVCaptureDevice) SmartFramingMonitor ¶

func (o *AVCaptureDevice) SmartFramingMonitor() objc.ID

func (*AVCaptureDevice) SpatialCaptureDiscomfortReasons ¶

func (o *AVCaptureDevice) SpatialCaptureDiscomfortReasons() *foundation.NSSet[*foundation.NSString]

func (*AVCaptureDevice) SupportedFallbackPrimaryConstituentDevices ¶

func (o *AVCaptureDevice) SupportedFallbackPrimaryConstituentDevices() *foundation.NSArray[*AVCaptureDevice]

@property supportedFallbackPrimaryConstituentDevices @abstract The constituent devices that may be selected as a fallback for a longer focal length primary constituent device. @discussion This property returns an empty array for non-virtual devices. This property never changes for a given virtual device.

func (*AVCaptureDevice) SupportsAVCaptureSessionPreset ¶

func (o *AVCaptureDevice) SupportsAVCaptureSessionPreset(preset *foundation.NSString) bool

@method supportsAVCaptureSessionPreset: @abstract Returns whether the receiver can be used in an AVCaptureSession configured with the given preset. @param preset An AVCaptureSession preset. @result YES if the receiver can be used with the given preset, NO otherwise. @discussion An AVCaptureSession instance can be associated with a preset that configures its inputs and outputs to fulfill common use cases. This method can be used to determine if the receiver can be used in a capture session with the given preset. Presets are defined in AVCaptureSession.h.

func (*AVCaptureDevice) TorchLevel ¶

func (o *AVCaptureDevice) TorchLevel() float32

@property torchLevel @abstract Indicates the receiver's current torch brightness level as a floating point value. @discussion The value of this property is a float indicating the receiver's torch level from 0.0 (off) -> 1.0 (full). This property is key-value observable.

func (*AVCaptureDevice) TorchMode ¶

func (o *AVCaptureDevice) TorchMode() AVCaptureTorchMode

@property torchMode @abstract Indicates current mode of the receiver's torch, if it has one. @discussion The value of this property is an AVCaptureTorchMode that determines the mode of the receiver's torch, if it has one. -setTorchMode: throws an NSInvalidArgumentException if set to an unsupported value (see -isTorchModeSupported:). -setTorchMode: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's torchMode by key value observing this property.

func (*AVCaptureDevice) TransportControlsPlaybackMode ¶

func (o *AVCaptureDevice) TransportControlsPlaybackMode() AVCaptureDeviceTransportControlsPlaybackMode

@property transportControlsPlaybackMode @abstract Returns the receiver's current playback mode. @discussion For devices that support transport control, this property may be queried to discover the current playback mode.

func (*AVCaptureDevice) TransportControlsSpeed ¶

func (o *AVCaptureDevice) TransportControlsSpeed() float32

@property transportControlsSpeed @abstract Returns the receiver's current playback speed as a floating point value. @discussion For devices that support transport control, this property may be queried to discover the current playback speed of the deck. 0.0 -> stopped. 1.0 -> forward at normal speed. -1.0-> reverse at normal speed. 2.0 -> forward at 2x normal speed. etc.

func (*AVCaptureDevice) TransportControlsSupported ¶

func (o *AVCaptureDevice) TransportControlsSupported() bool

@property transportControlsSupported @abstract Returns whether the receiver supports transport control commands. @discussion For devices with transport controls, such as AVC tape-based camcorders or pro capture devices with RS422 deck control, the value of this property is YES. If transport controls are not supported, none of the associated transport control methods and properties are available on the receiver.

func (*AVCaptureDevice) TransportType ¶

func (o *AVCaptureDevice) TransportType() int32

@property transportType @abstract The transport type of the receiver (e.g. USB, PCI, etc). @discussion This property can be used to discover the transport type of a capture device. Transport types are defined in <IOKit/audio/IOAudioTypes.h> as kIOAudioDeviceTransportType*.

func (*AVCaptureDevice) UniqueID ¶

func (o *AVCaptureDevice) UniqueID() *foundation.NSString

@property uniqueID @abstract An ID unique to the model of device corresponding to the receiver. @discussion Every available capture device has a unique ID that persists on one system across device connections and disconnections, application restarts, and reboots of the system itself. Applications can store the value returned by this property to recall or track the status of a specific device in the future.

func (*AVCaptureDevice) UnlockForConfiguration ¶

func (o *AVCaptureDevice) UnlockForConfiguration()

@method unlockForConfiguration @abstract Release exclusive control over device hardware properties. @discussion This method should be called to match an invocation of lockForConfiguration: when an application no longer needs to keep device hardware properties from changing automatically.

func (*AVCaptureDevice) WhiteBalanceMode ¶

func (o *AVCaptureDevice) WhiteBalanceMode() AVCaptureWhiteBalanceMode

@property whiteBalanceMode @abstract Indicates current white balance mode of the receiver, if it has adjustable white balance. @discussion The value of this property is an AVCaptureWhiteBalanceMode that determines the receiver's white balance mode, if it has adjustable white balance. -setWhiteBalanceMode: throws an NSInvalidArgumentException if set to an unsupported value (see -isWhiteBalanceModeSupported:). -setWhiteBalanceMode: throws an NSGenericException if called without first obtaining exclusive access to the receiver using lockForConfiguration:. Clients can observe automatic changes to the receiver's whiteBalanceMode by key value observing this property.

type AVCaptureDeviceDiscoverySession ¶

type AVCaptureDeviceDiscoverySession struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedevicediscoverysession

func AVCaptureDeviceDiscoverySessionDiscoverySessionWithDeviceTypesMediaTypePosition ¶

func AVCaptureDeviceDiscoverySessionDiscoverySessionWithDeviceTypesMediaTypePosition(deviceTypes *foundation.NSArray[*foundation.NSString], mediaType *foundation.NSString, position AVCaptureDevicePosition) *AVCaptureDeviceDiscoverySession

@method discoverySessionWithDeviceTypes: @abstract Returns an AVCaptureDeviceDiscoverySession instance for the given device types, media type, and position. @param deviceTypes An array specifying the device types to include in the list of discovered devices. @param mediaType The media type, such as AVMediaTypeVideo, AVMediaTypeAudio, or AVMediaTypeMuxed, to include in the list of discovered devices. Pass nil to search for devices with any media type. @param position The position to include in the list of discovered devices. Pass AVCaptureDevicePositionUnspecified to search for devices with any position. @result The AVCaptureDeviceDiscoverySession from which the list of devices can be obtained. @discussion The list of device types is mandatory. This is used to make sure that clients only get access to devices of types they expect. This prevents new device types from automatically being included in the list of devices.

func AVCaptureDeviceDiscoverySessionFromID ¶

func AVCaptureDeviceDiscoverySessionFromID(id objc.ID) *AVCaptureDeviceDiscoverySession

func (*AVCaptureDeviceDiscoverySession) Devices ¶

@property devices @abstract The list of devices that comply to the search criteria specified on the discovery session. @discussion The returned array contains only devices that are available at the time the method is called. Applications can key-value observe this property to be notified when the list of available devices has changed. For apps linked against iOS 10, the devices returned are unsorted. For apps linked against iOS 11 or later, the devices are sorted by AVCaptureDeviceType, matching the order specified in the deviceTypes parameter of +[AVCaptureDeviceDiscoverySession discoverySessionWithDeviceTypes:mediaType:position:]. If a position of AVCaptureDevicePositionUnspecified is specified, the results are further ordered by position in the AVCaptureDevicePosition enum. Starting in Mac Catalyst 14.0, clients can key value observe the value of this property to be notified when the devices change.

type AVCaptureDeviceFormat ¶

type AVCaptureDeviceFormat struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedeviceformat

func AVCaptureDeviceFormatFromID ¶

func AVCaptureDeviceFormatFromID(id objc.ID) *AVCaptureDeviceFormat

func (*AVCaptureDeviceFormat) AutoFocusSystem ¶

func (o *AVCaptureDeviceFormat) AutoFocusSystem() AVCaptureAutoFocusSystem

@property autoFocusSystem @abstract A property indicating the autofocus system. @discussion This read-only property indicates the autofocus system.

func (*AVCaptureDeviceFormat) DefaultSimulatedAperture ¶

func (o *AVCaptureDeviceFormat) DefaultSimulatedAperture() float32

Default shallow depth of field simulated aperture. This property return a non-zero value on devices that support the shallow depth of field effect.

func (*AVCaptureDeviceFormat) FormatDescription ¶

func (o *AVCaptureDeviceFormat) FormatDescription() unsafe.Pointer

@property formatDescription @abstract A CMFormatDescription describing an AVCaptureDevice active or supported format. @discussion A CMFormatDescription describing an AVCaptureDevice active or supported format. This is a read-only property. The caller assumes no ownership of the returned value and should not CFRelease it.

func (*AVCaptureDeviceFormat) IsAutoVideoFrameRateSupported ¶

func (o *AVCaptureDeviceFormat) IsAutoVideoFrameRateSupported() bool

@property autoVideoFrameRateSupported @abstract Indicates whether the device format supports auto video frame rate. @discussion See -[AVCaptureDevice autoVideoFrameRateEnabled] (above) for a detailed description of the feature.

func (*AVCaptureDeviceFormat) IsBackgroundReplacementSupported ¶

func (o *AVCaptureDeviceFormat) IsBackgroundReplacementSupported() bool

@property backgroundReplacementSupported @abstract Indicates whether the format supports the Background Replacement feature. @discussion This property returns YES if the format supports Background Replacement background replacement. See +AVCaptureDevice.backgroundReplacementEnabled.

func (*AVCaptureDeviceFormat) IsCameraLensSmudgeDetectionSupported ¶

func (o *AVCaptureDeviceFormat) IsCameraLensSmudgeDetectionSupported() bool

func (*AVCaptureDeviceFormat) IsCenterStageSupported ¶

func (o *AVCaptureDeviceFormat) IsCenterStageSupported() bool

@property centerStageSupported @abstract Indicates whether the format supports the Center Stage feature. @discussion This property returns YES if the format supports "Center Stage", which automatically adjusts the camera to keep people optimally framed within the field of view. See +AVCaptureDevice.centerStageEnabled for a detailed discussion.

func (*AVCaptureDeviceFormat) IsCinematicVideoCaptureSupported ¶

func (o *AVCaptureDeviceFormat) IsCinematicVideoCaptureSupported() bool

Indicates whether the format supports Cinematic Video capture. This property returns `true` if the format supports Cinematic Video that produces a controllable, simulated depth of field and adds beautiful focus transitions for a cinema-grade look.

func (*AVCaptureDeviceFormat) IsEdgeLightSupported ¶

func (o *AVCaptureDeviceFormat) IsEdgeLightSupported() bool

func (*AVCaptureDeviceFormat) IsHighPhotoQualitySupported ¶

func (o *AVCaptureDeviceFormat) IsHighPhotoQualitySupported() bool

@property highPhotoQualitySupported @abstract A boolean value specifying whether this format supports high photo quality when selecting an AVCapturePhotoQualityPrioritization of .balanced or .quality. @discussion If an AVCaptureDeviceFormat's highPhotoQualitySupported property is YES, the format produces higher image quality when selecting .balanced or .quality AVCapturePhotoQualityPrioritization compared to .speed. Such formats adhere to the following rules: - Photo requests with a prioritization of .speed produce the fastest image result (suitable for burst captures). - Photo requests with a prioritization of .balanced produce higher image quality without dropping frames if a video recording is underway. - Photo requests with a prioritization of .quality produce high image quality and may cause frame drops if a video recording is underway. For maximum backward compatibility, photo requests on high photo quality formats set to .quality only cause video frame drops if your app is linked on or after iOS 15. Formats that don't support high photo quality produce the same image quality whether you select .speed, .balanced, or .quality. Note that high photo quality is only attainable when using the AVCapturePhotoOutput with these supported formats.

func (*AVCaptureDeviceFormat) IsPortraitEffectSupported ¶

func (o *AVCaptureDeviceFormat) IsPortraitEffectSupported() bool

@property portraitEffectSupported @abstract Indicates whether the format supports the Portrait Effect feature. @discussion This property returns YES if the format supports Portrait Effect, the application of a shallow depth of field effect to objects in the background. See +AVCaptureDevice.portraitEffectEnabled for a detailed discussion.

func (*AVCaptureDeviceFormat) IsSmartFramingSupported ¶

func (o *AVCaptureDeviceFormat) IsSmartFramingSupported() bool

func (*AVCaptureDeviceFormat) IsSpatialVideoCaptureSupported ¶

func (o *AVCaptureDeviceFormat) IsSpatialVideoCaptureSupported() bool

func (*AVCaptureDeviceFormat) IsStudioLightSupported ¶

func (o *AVCaptureDeviceFormat) IsStudioLightSupported() bool

@property studioLightSupported @abstract Indicates whether the format supports the Studio Light feature. @discussion This property returns YES if the format supports Studio Light (artificial re-lighting of the subject's face). See +AVCaptureDevice.studioLightEnabled.

func (*AVCaptureDeviceFormat) MaxSimulatedAperture ¶

func (o *AVCaptureDeviceFormat) MaxSimulatedAperture() float32

Maximum supported shallow depth of field simulated aperture. On devices that do not support changing the simulated aperture value, this returns a value of `0`.

func (*AVCaptureDeviceFormat) MediaType ¶

func (o *AVCaptureDeviceFormat) MediaType() *foundation.NSString

@property mediaType @abstract An NSString describing the media type of an AVCaptureDevice active or supported format. @discussion Supported mediaTypes are listed in AVMediaFormat.h. This is a read-only property. The caller assumes no ownership of the returned value and should not CFRelease it.

func (*AVCaptureDeviceFormat) MinSimulatedAperture ¶

func (o *AVCaptureDeviceFormat) MinSimulatedAperture() float32

Minimum supported shallow depth of field simulated aperture. On devices that do not support changing the simulated aperture value, this returns a value of `0`.

func (*AVCaptureDeviceFormat) ReactionEffectsSupported ¶

func (o *AVCaptureDeviceFormat) ReactionEffectsSupported() bool

@property reactionEffectsSupported @abstract Indicates whether the format supports the Reaction Effects feature. @discussion This property returns YES if the format supports Reaction Effects. See +AVCaptureDevice.reactionEffectsEnabled.

func (*AVCaptureDeviceFormat) SecondaryNativeResolutionZoomFactors ¶

func (o *AVCaptureDeviceFormat) SecondaryNativeResolutionZoomFactors() *foundation.NSArray[*foundation.NSNumber]

@property secondaryNativeResolutionZoomFactors @abstract Indicates zoom factors at which this device transitions to secondary native resolution modes. @discussion Devices with this property have the means to switch their pixel sampling mode on the fly to produce a high-fidelity, non-upsampled images at a fixed zoom factor beyond 1.0x.

func (*AVCaptureDeviceFormat) SupportedColorSpaces ¶

func (o *AVCaptureDeviceFormat) SupportedColorSpaces() *foundation.NSArray[*foundation.NSNumber]

@property supportedColorSpaces @abstract A property indicating the receiver's supported color spaces. @discussion This read-only property indicates the receiver's supported color spaces as an array of AVCaptureColorSpace constants sorted from narrow to wide color.

func (*AVCaptureDeviceFormat) SupportedDynamicAspectRatios ¶

func (o *AVCaptureDeviceFormat) SupportedDynamicAspectRatios() *foundation.NSArray[*foundation.NSString]

Indicates the supported aspect ratios for the device format. An array that describes the aspect ratios that are supported for this format. If this device format does not support dynamic aspect ratio, this property returns an empty array.

func (*AVCaptureDeviceFormat) SupportedMaxPhotoDimensions ¶

func (o *AVCaptureDeviceFormat) SupportedMaxPhotoDimensions() *foundation.NSArray[*foundation.NSValue]

@property supportedMaxPhotoDimensions @abstract This property lists all of the supported maximum photo dimensions for this format. The array contains CMVideoDimensions structs encoded as NSValues. @discussion Enumerate all supported resolution settings for which this format may be configured to capture photos. Use these values to set AVCapturePhotoOutput.maxPhotoDimensions and AVCapturePhotoSettings.maxPhotoDimensions.

func (*AVCaptureDeviceFormat) SupportedVideoZoomRangesForDepthDataDelivery ¶

func (o *AVCaptureDeviceFormat) SupportedVideoZoomRangesForDepthDataDelivery() *foundation.NSArray[*AVZoomRange]

@property supportedVideoZoomRangesForDepthDataDelivery @abstract This property returns the zoom ranges within which depth data can be delivered. @discussion Virtual devices support limited zoom ranges when delivering depth data to any output. If this device format has no -supportedDepthDataFormats, this property returns an empty array. The presence of one or more ranges where the min and max zoom factors are not equal means that "continuous zoom" with depth is supported. For example: a) ranges: @[ [2..2], [4..4] ] only zoom factors 2 and 4 are allowed to be set when depthDataDelivery is enabled. Any other zoom factor results in an exception. b) ranges: @[ [2..5] ] depthDataDelivery is supported with zoom factors [2..5]. Zoom factors outside of this range may be set, but will result in loss of depthDataDeliery. Whenever zoom is set back to a value within the range of [2..5], depthDataDelivery will resume. When depth data delivery is enabled, the effective videoZoomFactorUpscaleThreshold will be 1.0, meaning that all zoom factors that are not native zoom factors (see AVCaptureDevice.virtualDeviceSwitchOverVideoZoomFactors and AVCaptureDevice.secondaryNativeResolutionZoomFactors) result in digital upscaling.

func (*AVCaptureDeviceFormat) SystemRecommendedExposureBiasRange ¶

func (o *AVCaptureDeviceFormat) SystemRecommendedExposureBiasRange() *AVExposureBiasRange

@property systemRecommendedExposureBiasRange @abstract Indicates the system's recommended exposure bias range for this device format. @discussion This property can be used to create a slider in your app's user interface to control the device's exposure bias with a system-recommended exposure bias range. When a recommendation is not available, this property returns nil. The value of this property is also used for the AVCaptureSystemExposureBiasSlider's range.

func (*AVCaptureDeviceFormat) SystemRecommendedVideoZoomRange ¶

func (o *AVCaptureDeviceFormat) SystemRecommendedVideoZoomRange() *AVZoomRange

@property systemRecommendedVideoZoomRange @abstract Indicates the system's recommended zoom range for this device format. @discussion This property can be used to create a slider in your app's user interface to control the device's zoom with a system-recommended video zoom range. When a recommendation is not available, this property returns nil. Clients can key value observe AVCaptureDevice's minAvailableVideoZoomFactor and maxAvailableVideoZoomFactor properties to know when a device's supported zoom is restricted within the recommended zoom range. The value of this property is also used for the AVCaptureSystemZoomSlider's range.

func (*AVCaptureDeviceFormat) VideoFieldOfViewForAspectRatioGeometricDistortionCorrected ¶

func (o *AVCaptureDeviceFormat) VideoFieldOfViewForAspectRatioGeometricDistortionCorrected(aspectRatio *foundation.NSString, geometricDistortionCorrected bool) float32

Indicates the horizontal field of view for an aspect ratio, either uncorrected or corrected for geometric distortion. A float indicating the field of view for the corresponding “AVCaptureAspectRatio“. Set “AVCaptureDevice/geometricDistortionCorrected“ to `true` to receive the field of view corrected for geometric distortion. If this device format does not support dynamic aspect ratio, this function returns `0`.

func (*AVCaptureDeviceFormat) VideoFrameRateRangeForBackgroundReplacement ¶

func (o *AVCaptureDeviceFormat) VideoFrameRateRangeForBackgroundReplacement() *AVFrameRateRange

@property videoFrameRateRangeForBackgroundReplacement @abstract Indicates the minimum / maximum frame rates available when background replacement is active. @discussion Devices may support a limited frame rate range when Background Replacement is active. If this device format does not support Background Replacement, this property returns nil.

func (*AVCaptureDeviceFormat) VideoFrameRateRangeForCenterStage ¶

func (o *AVCaptureDeviceFormat) VideoFrameRateRangeForCenterStage() *AVFrameRateRange

@property videoFrameRateRangeForCenterStage @abstract Indicates the minimum / maximum frame rates available when centerStageActive is YES. @discussion Devices may support a limited frame rate range when Center Stage is active. If this device format does not support Center Stage, this property returns nil.

func (*AVCaptureDeviceFormat) VideoFrameRateRangeForCinematicVideo ¶

func (o *AVCaptureDeviceFormat) VideoFrameRateRangeForCinematicVideo() *AVFrameRateRange

Indicates the minimum / maximum frame rates available when Cinematic Video capture is enabled on the device input. Devices may support a limited frame rate range when Cinematic Video capture is active. If this device format does not support Cinematic Video capture, this property returns `nil`.

func (*AVCaptureDeviceFormat) VideoFrameRateRangeForPortraitEffect ¶

func (o *AVCaptureDeviceFormat) VideoFrameRateRangeForPortraitEffect() *AVFrameRateRange

@property videoFrameRateRangeForPortraitEffect @abstract Indicates the minimum / maximum frame rates available when portraitEffectActive is YES. @discussion Devices may support a limited frame rate range when Portrait Effect is active. If this device format does not support Portrait Effect, this property returns nil.

func (*AVCaptureDeviceFormat) VideoFrameRateRangeForReactionEffectsInProgress ¶

func (o *AVCaptureDeviceFormat) VideoFrameRateRangeForReactionEffectsInProgress() *AVFrameRateRange

@property videoFrameRateRangeForReactionEffectsInProgress @abstract Indicates the minimum / maximum frame rates available when a reaction effect is running. @discussion Unlike the other video effects, enabling reaction effects does not limit the stream's frame rate because most of the time no rendering is being performed. The frame rate will only ramp down when a reaction is actually being rendered on the stream (see AVCaptureDevice.reactionEffectsInProgress)

func (*AVCaptureDeviceFormat) VideoFrameRateRangeForStudioLight ¶

func (o *AVCaptureDeviceFormat) VideoFrameRateRangeForStudioLight() *AVFrameRateRange

@property videoFrameRateRangeForStudioLight @abstract Indicates the minimum / maximum frame rates available when studioLight is YES. @discussion Devices may support a limited frame rate range when Studio Light is active. If this device format does not support Studio Light, this property returns nil.

func (*AVCaptureDeviceFormat) VideoMaxZoomFactorForCenterStage ¶

func (o *AVCaptureDeviceFormat) VideoMaxZoomFactorForCenterStage() float64

@property videoMaxZoomFactorForCenterStage @abstract Indicates the maximum zoom factor available for the AVCaptureDevice's videoZoomFactor property when centerStageActive is YES. @discussion Devices support a limited zoom range when Center Stage is active. If this device format does not support Center Stage, this property returns videoMaxZoomFactor.

func (*AVCaptureDeviceFormat) VideoMaxZoomFactorForCinematicVideo ¶

func (o *AVCaptureDeviceFormat) VideoMaxZoomFactorForCinematicVideo() float64

Indicates the maximum zoom factor available for the “AVCaptureDevice/videoZoomFactor“ property when Cinematic Video capture is enabled on the device input. Devices support a limited zoom range when Cinematic Video capture is active. If this device format does not support Cinematic Video capture, this property returns `1.0`.

func (*AVCaptureDeviceFormat) VideoMinZoomFactorForCenterStage ¶

func (o *AVCaptureDeviceFormat) VideoMinZoomFactorForCenterStage() float64

@property videoMinZoomFactorForCenterStage @abstract Indicates the minimum zoom factor available for the AVCaptureDevice's videoZoomFactor property when centerStageActive is YES. @discussion Devices support a limited zoom range when Center Stage is active. If this device format does not support Center Stage, this property returns 1.0.

func (*AVCaptureDeviceFormat) VideoMinZoomFactorForCinematicVideo ¶

func (o *AVCaptureDeviceFormat) VideoMinZoomFactorForCinematicVideo() float64

Indicates the minimum zoom factor available for the “AVCaptureDevice/videoZoomFactor“ property when Cinematic Video capture is enabled on the device input. Devices support a limited zoom range when Cinematic Video capture is active. If this device format does not support Cinematic Video capture, this property returns `1.0`.

func (*AVCaptureDeviceFormat) VideoSupportedFrameRateRanges ¶

func (o *AVCaptureDeviceFormat) VideoSupportedFrameRateRanges() *foundation.NSArray[*AVFrameRateRange]

@property videoSupportedFrameRateRanges @abstract A property indicating the format's supported frame rate ranges. @discussion videoSupportedFrameRateRanges is an array of AVFrameRateRange objects, one for each of the format's supported video frame rate ranges.

func (*AVCaptureDeviceFormat) ZoomFactorsOutsideOfVideoZoomRangesForDepthDeliverySupported ¶

func (o *AVCaptureDeviceFormat) ZoomFactorsOutsideOfVideoZoomRangesForDepthDeliverySupported() bool

@property zoomFactorsOutsideOfVideoZoomRangesForDepthDeliverySupported @abstract This property returns whether the format supports zoom factors outside of the supportedVideoZoomFactorRangesForDepthDataDelivery. @discussion When a zoom factor outside of the supportedVideoZoomFactorRangesForDepthDataDelivery is set, depth data delivery will be suspended until a zoom factor within the supportedVideoZoomFactorRangesForDepthDataDelivery is set.

type AVCaptureDeviceInput ¶

type AVCaptureDeviceInput struct {
	AVCaptureInput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedeviceinput

func AVCaptureDeviceInputDeviceInputWithDeviceError ¶

func AVCaptureDeviceInputDeviceInputWithDeviceError(device *AVCaptureDevice) (*AVCaptureDeviceInput, error)

@method deviceInputWithDevice:error: @abstract Returns an AVCaptureDeviceInput instance that provides media data from the given device. @param device An AVCaptureDevice instance to be used for capture. @param outError On return, if the given device cannot be used for capture, points to an NSError describing the problem. @result An AVCaptureDeviceInput instance that provides data from the given device, or nil, if the device could not be used for capture. @discussion This method returns an instance of AVCaptureDeviceInput that can be used to capture data from an AVCaptureDevice in an AVCaptureSession. This method attempts to open the device for capture, taking exclusive control of it if necessary. If the device cannot be opened because it is no longer available or because it is in use, for example, this method returns nil, and the optional outError parameter points to an NSError describing the problem.

func AVCaptureDeviceInputFromID ¶

func AVCaptureDeviceInputFromID(id objc.ID) *AVCaptureDeviceInput

func (*AVCaptureDeviceInput) ActiveExternalSyncVideoFrameDuration ¶

func (o *AVCaptureDeviceInput) ActiveExternalSyncVideoFrameDuration() coremedia.CMTime

The receiver's external sync frame duration (the reciprocal of its frame rate) when being driven by an external sync device. Set up your input to follow an external sync device by calling “followExternalSyncDevice:videoFrameDuration:delegate:“. - Note: The value of this readonly property is `kCMTimeInvalid` unless the “AVExternalSyncDevice“ is actively driving the “AVCaptureDeviceInput“. This is reflected by the “AVExternalSyncDevice/status“ being either “AVExternalSyncDeviceStatusActiveSync“ or “AVExternalSyncDeviceStatusFreeRunSync“.

func (*AVCaptureDeviceInput) ActiveLockedVideoFrameDuration ¶

func (o *AVCaptureDeviceInput) ActiveLockedVideoFrameDuration() coremedia.CMTime

The receiver's locked frame duration (the reciprocal of its frame rate). Setting this property guarantees the intra-frame duration delivered by the device input is precisely the frame duration you request. Set this property to run the receiver's associated “AVCaptureDevice“ at precisely your provided frame rate (expressed as a duration). Query “AVCaptureDevice/minSupportedLockedVideoFrameDuration“ to find the minimum value supported by this “AVCaptureDeviceInput“. In order to disable locked video frame duration, set this property to `kCMTimeInvalid`. This property resets itself to `kCMTimeInvalid` when the receiver's attached “AVCaptureDevice/activeFormat“ changes. When you set this property, its value is also reflected in the receiver's “AVCaptureDevice/activeVideoMinFrameDuration“ and “AVCaptureDevice/activeVideoMaxFrameDuration“. - Note: Locked frame duration availability may change depending on the device configuration. For example, locked frame duration is unsupported when “AVCaptureDevice/autoVideoFrameRateEnabled“ or “AVCaptureMovieFileOutput/spatialVideoCaptureEnabled“ is set to `true`. - Note: Only one “AVCaptureDeviceInput“ added to an “AVCaptureMultiCamSession“ can follow an external sync device or run at a locked frame duration. - Note: Setting this property may cause a lengthy reconfiguration of the receiver, similar to setting “AVCaptureDevice/activeFormat“ or “AVCaptureSession/sessionPreset“. - Note: When using this property, set the exposure duration with “AVCaptureDevice/setExposureModeCustomWithDuration:ISO:completionHandler:“ to one half the frame duration (or less) to maintain full dynamic range. - Important: If you set this property to a valid value while the receiver's “AVCaptureDevice/minSupportedLockedVideoFrameDuration“ is `kCMTimeInvalid`, it throws an `NSInvalidArgumentException`. - Important: If you set this property while the receiver's “lockedVideoFrameDurationSupported“ property returns `false`, it throws an `NSInvalidArgumentException`.

func (*AVCaptureDeviceInput) Device ¶

@property device @abstract The device from which the receiver provides data. @discussion The value of this property is the AVCaptureDevice instance that was used to create the receiver.

func (*AVCaptureDeviceInput) ExternalSyncDevice ¶

func (o *AVCaptureDeviceInput) ExternalSyncDevice() *AVExternalSyncDevice

The external sync device currently being followed by this input. This readonly property returns the “AVExternalSyncDevice“ instance you provided in “followExternalSyncDevice:videoFrameDuration:delegate:“. This property returns `nil` when an external sync device is disconnected or fails to calibrate.

func (*AVCaptureDeviceInput) FollowExternalSyncDeviceVideoFrameDurationDelegate ¶

func (o *AVCaptureDeviceInput) FollowExternalSyncDeviceVideoFrameDurationDelegate(externalSyncDevice *AVExternalSyncDevice, frameDuration coremedia.CMTime, delegate AVExternalSyncDeviceDelegate)

Configures the the device input to follow an external sync device at the given frame duration. - Parameter externalSyncDevice: The “AVExternalSyncDevice“ hardware to follow. - Parameter videoFrameDuration: The frame duration to which the “AVExternalSyncDevice“ is calibrated. - Parameter delegate: The delegate to notify when the connection status changes, or an error occurs. Call this method to direct your “AVCaptureDeviceInput“ to follow the external sync pulse from a sync device at the given frame duration. Your provided `videoFrameDuration` value must match the sync pulse duration of the external sync device. If it does not, the request times out, the external sync device's status returns to “AVExternalSyncDeviceStatusReady“, and your session stops running, posting a “AVCaptureSessionRuntimeErrorNotification“ with “AVErrorFollowExternalSyncDeviceTimedOut“. The ability to follow an external sync device may change depending on the device configuration. For example, “followExternalSyncDevice:videoFrameDuration:delegate:“ cannot be used when “AVCaptureDevice/autoVideoFrameRateEnabled“ is `true`. To stop following an external pulse, call “unfollowExternalSyncDevice“. External sync device following is also disabled when your device's “AVCaptureDeviceFormat“ changes. Your provided delegate's “AVExternalSyncDeviceDelegate/externalSyncDeviceStatusDidChange:“ method is called with a status of “AVExternalSyncDeviceStatusReady“ if the external pulse signal is not close enough to the provided `videoFrameDuration` for successful calibration. Once your “AVExternalSyncDevice/status“ changes to “AVExternalSyncDeviceStatusActiveSync“, your input's “AVCaptureInput/activeExternalSyncVideoFrameDuration“ property reports the up-to-date frame duration. “AVCaptureInput/activeExternalSyncVideoFrameDuration“ is also reflected in the “AVCaptureDevice/activeVideoMinFrameDuration“ and “AVCaptureDevice/activeVideoMaxFrameDuration“ of your input's associated device. - Note: Calling this method may cause a lengthy reconfiguration of the receiver, similar to setting a new active format or “AVCaptureSession/sessionPreset“. - Note: When using this property, set the exposure duration with “AVCaptureDevice/setExposureModeCustomWithDuration:ISO:completionHandler:“ to one half the frame duration (or less) to maintain full dynamic range. - Important: Calling this method throws an `NSInvalidArgumentException` if “AVCaptureDeviceInput/externalSyncSupported“ returns `false`. - Important: The provided external sync device's “status“ must be “AVExternalSyncDeviceStatusReady“ when you call this method, otherwise an `NSInvalidArgumentException` is thrown.

func (*AVCaptureDeviceInput) InitWithDeviceError ¶

func (o *AVCaptureDeviceInput) InitWithDeviceError(device *AVCaptureDevice) (*AVCaptureDeviceInput, error)

@method initWithDevice:error: @abstract Creates an AVCaptureDeviceInput instance that provides media data from the given device. @param device An AVCaptureDevice instance to be used for capture. @param outError On return, if the given device cannot be used for capture, points to an NSError describing the problem. @result An AVCaptureDeviceInput instance that provides data from the given device, or nil, if the device could not be used for capture. @discussion This method creates an instance of AVCaptureDeviceInput that can be used to capture data from an AVCaptureDevice in an AVCaptureSession. This method attempts to open the device for capture, taking exclusive control of it if necessary. If the device cannot be opened because it is no longer available or because it is in use, for example, this method returns nil, and the optional outError parameter points to an NSError describing the problem.

func (*AVCaptureDeviceInput) IsAudioZoomEnabled ¶

func (o *AVCaptureDeviceInput) IsAudioZoomEnabled() bool

Whether or not audio zoom is enabled. Setting this property to `true` throws an exception if “isAudioZoomSupported“ is `false`. Default is `true` when supported. When enabled, the sound field narrows or expands to match the field of view of the video device's zoom factor. Set this property to `false` if you want to capture the full sound field regardless of video zoom. This property only takes effect when added to a session with a video device, and “AVCaptureMultichannelAudioMode“ is set to any value other than “AVCaptureMultichannelAudioModeNone“. When using multiple cameras in “AVCaptureMultiCamSession“, audio zoom is determined by the zoom factor of the preferred camera. The preferred camera is selected to match the mic position, either front or back. If more than one camera is available in that position, the camera with the widest field of view is chosen with virtual cameras preferred over single camera ones. If no camera is found to match the mic position, audio zoom is unavailable.

func (*AVCaptureDeviceInput) IsAudioZoomSupported ¶

func (o *AVCaptureDeviceInput) IsAudioZoomSupported() bool

Whether or not audio zoom is supported. This property returns `true` if the device supports audio zoom.

func (*AVCaptureDeviceInput) IsCinematicVideoCaptureEnabled ¶

func (o *AVCaptureDeviceInput) IsCinematicVideoCaptureEnabled() bool

A BOOL value specifying whether the Cinematic Video effect is being applied to any movie file output, video data output, metadata output, or video preview layer added to the capture session. Default is `false`. Set to `true` to enable support for Cinematic Video capture. When you set this property to `true`, your input's associated “AVCaptureDevice/focusMode“ changes to “AVCaptureFocusModeContinuousAutoFocus“. While Cinematic Video capture is enabled, you are not permitted to change your device's focus mode, and any attempt to do so results in an `NSInvalidArgumentException`. You may only set this property to `true` if “cinematicVideoCaptureSupported“ is `true`. - Note: Enabling Cinematic Video capture requires a lengthy reconfiguration of the capture render pipeline, so if you intend to capture Cinematic Video, you should set this property to `true` before calling “AVCaptureSession/startRunning“ or within “AVCaptureSession/beginConfiguration“ and “AVCaptureSession/commitConfiguration“ while running.

func (*AVCaptureDeviceInput) IsCinematicVideoCaptureSupported ¶

func (o *AVCaptureDeviceInput) IsCinematicVideoCaptureSupported() bool

A BOOL value specifying whether Cinematic Video capture is supported. With Cinematic Video capture, you get a simulated depth-of-field effect that keeps your subjects (people, pets, and more) in sharp focus while applying a pleasing blur to the background (or foreground). Depending on the focus mode (see “AVCaptureCinematicVideoFocusMode“ for detail), the camera either uses machine learning to automatically detect and focus on subjects in the scene, or it fixes focus on a subject until it exits the scene. Cinematic Videos can be played back and edited using the Cinematic framework. You can adjust the video's simulated aperture before starting a recording using the “simulatedAperture“ property. With Cinematic Video specific focus methods on “AVCaptureDevice“, you can dynamically control focus transitions. Movie files captured with Cinematic Video enabled can be played back and edited with the [Cinematic framework] (https://developer.apple.com/documentation/cinematic/playing-and-editing-cinematic-mode-video?language=objc). This property returns `true` if the session's current configuration allows Cinematic Video capture. When switching cameras or formats, this property may change. When this property changes from `true` to `false`, “cinematicVideoCaptureEnabled“ also reverts to `false`. If you've previously opted in for Cinematic Video capture and then change configuration, you may need to set “cinematicVideoCaptureEnabled“ to `true` again. This property is key-value observable. - Note: “AVCaptureDepthDataOutput“ is not supported when “cinematicVideoCaptureEnabled“ is set to `true`. Running an “AVCaptureSession“ with both of these features throws an `NSInvalidArgumentException`.

func (*AVCaptureDeviceInput) IsExternalSyncSupported ¶

func (o *AVCaptureDeviceInput) IsExternalSyncSupported() bool

Indicates whether the device input supports being configured to follow an external sync device. See “AVCaptureDeviceInput/followExternalSyncDevice:videoFrameDuration:delegate:“ for more information on external sync.

func (*AVCaptureDeviceInput) IsLockedVideoFrameDurationSupported ¶

func (o *AVCaptureDeviceInput) IsLockedVideoFrameDurationSupported() bool

Indicates whether the device input supports locked frame durations. See “AVCaptureDeviceInput/activeLockedVideoFrameDuration“ for more information on video frame duration locking.

func (*AVCaptureDeviceInput) IsMultichannelAudioModeSupported ¶

func (o *AVCaptureDeviceInput) IsMultichannelAudioModeSupported(multichannelAudioMode AVCaptureMultichannelAudioMode) bool

@method isMultichannelAudioModeSupported: @abstract Returns whether the receiver supports the given multichannel audio mode. @param multichannelAudioMode An AVCaptureMultichannelAudioMode to be checked. @result YES if the receiver supports the given multichannel audio mode, NO otherwise. @discussion The receiver's multichannelAudioMode property can only be set to a certain mode if this method returns YES for that mode.

func (*AVCaptureDeviceInput) IsWindNoiseRemovalEnabled ¶

func (o *AVCaptureDeviceInput) IsWindNoiseRemovalEnabled() bool

@property windNoiseRemovalEnabled @abstract Specifies whether or not wind noise is removed during audio capture. @discussion Wind noise removal is available when the AVCaptureDeviceInput multichannelAudioMode property is set to any value other than AVCaptureMultichannelAudioModeNone.

func (*AVCaptureDeviceInput) IsWindNoiseRemovalSupported ¶

func (o *AVCaptureDeviceInput) IsWindNoiseRemovalSupported() bool

@property windNoiseRemovalSupported @abstract Returns whether or not the device supports wind noise removal during audio capture. @discussion YES if the device supports wind noise removal, NO otherwise.

func (*AVCaptureDeviceInput) MultichannelAudioMode ¶

func (o *AVCaptureDeviceInput) MultichannelAudioMode() AVCaptureMultichannelAudioMode

Indicates the multichannel audio mode to apply when recording audio. This property only takes effect when audio is being routed through the built-in microphone, and is ignored if an external microphone is in use. The default value is “AVCaptureMultichannelAudioModeNone“, in which case the default single channel audio recording is used. In an “AVCaptureMultiCamSession“, when audio mode is set to any value other than “AVCaptureMultichannelAudioModeNone“, only one “sourceDevicePosition“ is allowed for audio ports.

func (*AVCaptureDeviceInput) SetActiveLockedVideoFrameDuration ¶

func (o *AVCaptureDeviceInput) SetActiveLockedVideoFrameDuration(activeLockedVideoFrameDuration coremedia.CMTime)

func (*AVCaptureDeviceInput) SetAudioZoomEnabled ¶

func (o *AVCaptureDeviceInput) SetAudioZoomEnabled(audioZoomEnabled bool)

func (*AVCaptureDeviceInput) SetCinematicVideoCaptureEnabled ¶

func (o *AVCaptureDeviceInput) SetCinematicVideoCaptureEnabled(cinematicVideoCaptureEnabled bool)

func (*AVCaptureDeviceInput) SetMultichannelAudioMode ¶

func (o *AVCaptureDeviceInput) SetMultichannelAudioMode(multichannelAudioMode AVCaptureMultichannelAudioMode)

func (*AVCaptureDeviceInput) SetSimulatedAperture ¶

func (o *AVCaptureDeviceInput) SetSimulatedAperture(simulatedAperture float32)

func (*AVCaptureDeviceInput) SetWindNoiseRemovalEnabled ¶

func (o *AVCaptureDeviceInput) SetWindNoiseRemovalEnabled(windNoiseRemovalEnabled bool)

func (*AVCaptureDeviceInput) SimulatedAperture ¶

func (o *AVCaptureDeviceInput) SimulatedAperture() float32

Shallow depth of field simulated aperture. When capturing a Cinematic Video, use this property to control the amount of blur in the simulated depth of field effect. This property only takes effect when “cinematicVideoCaptureEnabled“ is set to `true`. - Important: Setting this property to a value less than the “AVCaptureDevice/activeFormat/minSimulatedAperture“ or greater than the “AVCaptureDevice/activeFormat/maxSimulatedAperture“ throws an `NSRangeException`. you may only set this property if “AVCaptureDevice/activeFormat/minSimulatedAperture“ returns a non-zero value, otherwise an `NSInvalidArgumentException` is thrown. You must set this property before starting a Cinematic Video capture. If you attempt to set it while a recording is in progress, an `NSInvalidArgumentException` is thrown. This property is initialized to the associated “AVCaptureDevice/activeFormat/defaultSimulatedAperture“. This property is key-value observable.

func (*AVCaptureDeviceInput) UnfollowExternalSyncDevice ¶

func (o *AVCaptureDeviceInput) UnfollowExternalSyncDevice()

Discontinues external sync. This method stops your input from syncing to the external sync device you specified in “followExternalSyncDevice:videoFrameDuration:delegate:“.

type AVCaptureDeviceInputSource ¶

type AVCaptureDeviceInputSource struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedeviceinputsource

func AVCaptureDeviceInputSourceFromID ¶

func AVCaptureDeviceInputSourceFromID(id objc.ID) *AVCaptureDeviceInputSource

func (*AVCaptureDeviceInputSource) InputSourceID ¶

func (o *AVCaptureDeviceInputSource) InputSourceID() *foundation.NSString

@property inputSourceID @abstract An ID unique among the inputSources exposed by a given AVCaptureDevice. @discussion An AVCaptureDevice's inputSources array must contain AVCaptureInputSource objects with unique inputSourceIDs.

func (*AVCaptureDeviceInputSource) LocalizedName ¶

func (o *AVCaptureDeviceInputSource) LocalizedName() *foundation.NSString

@property localizedName @abstract A localized human-readable name for the receiver. @discussion This property can be used for displaying the name of the capture device input source in a user interface.

type AVCaptureDevicePosition ¶

type AVCaptureDevicePosition int64
const (
	AVCaptureDevicePositionUnspecified AVCaptureDevicePosition = 0
	AVCaptureDevicePositionBack        AVCaptureDevicePosition = 1
	AVCaptureDevicePositionFront       AVCaptureDevicePosition = 2
)

func (AVCaptureDevicePosition) String ¶

func (e AVCaptureDevicePosition) String() string

type AVCaptureDeviceRotationCoordinator ¶

type AVCaptureDeviceRotationCoordinator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturedevicerotationcoordinator

func AVCaptureDeviceRotationCoordinatorFromID ¶

func AVCaptureDeviceRotationCoordinatorFromID(id objc.ID) *AVCaptureDeviceRotationCoordinator

func (*AVCaptureDeviceRotationCoordinator) Device ¶

@property device @abstract The the device for which the coordinator provides video rotation angles. @discussion The value of this property is the AVCaptureDevice instance that was used to create the coordinator. The coordinator holds a weak reference to the device.

func (*AVCaptureDeviceRotationCoordinator) InitWithDevicePreviewLayer ¶

func (o *AVCaptureDeviceRotationCoordinator) InitWithDevicePreviewLayer(device *AVCaptureDevice, previewLayer *quartzcore.CALayer) *AVCaptureDeviceRotationCoordinator

@method initWithDevice:previewLayer: @abstract Returns an AVCaptureDeviceRotationCoordinator instance that provides updates to the amount of rotation that should be applied for horizon-level preview and capture relative to gravity. @param device The device for which to monitor rotation. @param previewLayer A layer displaying the camera's video preview. If nil, the coordinator will return 0 degrees of rotation for horizon-level preview. @result An AVCaptureDeviceRotationCoordinator from which rotation angles for preview and capture can be obtained. @discussion An AVCaptureDeviceRotationCoordinator is only applicable to video devices. The given device and layer determine the amount of rotation that should be applied for horizon-level preview and capture.

func (*AVCaptureDeviceRotationCoordinator) PreviewLayer ¶

@property previewLayer @abstract The CALayer for which the coordinator calculates video rotation angles for horizon-level preview. @discussion The value of this property is the CALayer instance that was used to create the coordinator. Clients may specify an AVCaptureVideoPreviewLayer or other CALayer instance that displays a camera's video preview. The coordinator holds a weak reference to the layer. The coordinator will return 0 degrees of rotation from -videoRotationAngleForHorizonLevelPreview if a layer was not specified at initialization, the layer is not in a view hierarchy, or the layer has been deallocated.

func (*AVCaptureDeviceRotationCoordinator) VideoRotationAngleForHorizonLevelCapture ¶

func (o *AVCaptureDeviceRotationCoordinator) VideoRotationAngleForHorizonLevelCapture() float64

@property videoRotationAngleForHorizonLevelCapture @abstract Returns a video rotation angle in degrees for horizon-level capture from this camera. @discussion The video rotation angle represents by how much the photos or movies captured from the camera should be rotated to be horizon-level relative to gravity. A video rotation angle of 0 degrees means that the output will be in the camera's unrotated, native sensor orientation. The video rotation angle for capture may differ between cameras. For example when an iOS device is held in portrait orientation, photos and movies captured from built-in cameras may need to be rotated by 90 degrees while the photos and movies from an external camera should not be rotated. External cameras return 0 degrees of rotation even if they physically rotate when their position in physical space is unknown. The video rotation angle returned from this property is distinct from the angle returned by -videoRotationAngleForHorizonLevelPreview because in certain combinations of device and interface orientations, the video rotation angle needed for horizon-level preview may not match the amount of rotation needed for horizon-level capture. This property is key-value observable and delivers updates on the main queue.

func (*AVCaptureDeviceRotationCoordinator) VideoRotationAngleForHorizonLevelPreview ¶

func (o *AVCaptureDeviceRotationCoordinator) VideoRotationAngleForHorizonLevelPreview() float64

@property videoRotationAngleForHorizonLevelPreview @abstract Returns a video rotation angle in degrees for displaying the camera's video preview in the given CALayer. @discussion The video rotation angle represents by how much the camera's video preview should be rotated for display in the CALayer to be horizon-level relative to gravity. An angle of 0 degrees means that video will be output in the camera's unrotated, native sensor orientation. The video rotation angle for preview may differ between cameras at different positions. For example when an iOS device is held in portrait orientation, the video preview for built-in cameras may need to be rotated by 90 degrees while the video preview for an external camera should not be rotated. External cameras return 0 degrees of rotation even if they physically rotate when their position in physical space is unknown. This property is key-value observable and delivers updates on the main queue.

type AVCaptureDeviceTransportControlsPlaybackMode ¶

type AVCaptureDeviceTransportControlsPlaybackMode int64
const (
	AVCaptureDeviceTransportControlsNotPlayingMode AVCaptureDeviceTransportControlsPlaybackMode = 0
	AVCaptureDeviceTransportControlsPlayingMode    AVCaptureDeviceTransportControlsPlaybackMode = 1
)

func (AVCaptureDeviceTransportControlsPlaybackMode) String ¶

type AVCaptureExposureMode ¶

type AVCaptureExposureMode int64
const (
	AVCaptureExposureModeLocked                 AVCaptureExposureMode = 0
	AVCaptureExposureModeAutoExpose             AVCaptureExposureMode = 1
	AVCaptureExposureModeContinuousAutoExposure AVCaptureExposureMode = 2
	AVCaptureExposureModeCustom                 AVCaptureExposureMode = 3
)

func (AVCaptureExposureMode) String ¶

func (e AVCaptureExposureMode) String() string

type AVCaptureExternalDisplayConfiguration ¶

type AVCaptureExternalDisplayConfiguration struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureexternaldisplayconfiguration

func AVCaptureExternalDisplayConfigurationFromID ¶

func AVCaptureExternalDisplayConfigurationFromID(id objc.ID) *AVCaptureExternalDisplayConfiguration

func (*AVCaptureExternalDisplayConfiguration) BypassColorSpaceConversion ¶

func (o *AVCaptureExternalDisplayConfiguration) BypassColorSpaceConversion() bool

A property indicating whether the color space of the configurator's preview layer should be preserved on the output display by avoiding color space conversions. Set “bypassColorSpaceConversion“ to `true` if you would like the configurator's “AVCaptureVideoPreviewLayer“ color space preserved on the output display. This is accomplished by setting the working color space to match the color space of the external display. The color properties of the “CALayer“ remain untouched. The default value is `false`.

func (*AVCaptureExternalDisplayConfiguration) PreferredResolution ¶

Your preferred external display resolution. Use “preferredResolution“ to set your desired resolution of the external display. When left at the default value of { 0, 0 }, the native resolution of the external display is used.

func (*AVCaptureExternalDisplayConfiguration) SetBypassColorSpaceConversion ¶

func (o *AVCaptureExternalDisplayConfiguration) SetBypassColorSpaceConversion(bypassColorSpaceConversion bool)

func (*AVCaptureExternalDisplayConfiguration) SetPreferredResolution ¶

func (o *AVCaptureExternalDisplayConfiguration) SetPreferredResolution(preferredResolution coremedia.CMVideoDimensions)

func (*AVCaptureExternalDisplayConfiguration) SetShouldMatchFrameRate ¶

func (o *AVCaptureExternalDisplayConfiguration) SetShouldMatchFrameRate(shouldMatchFrameRate bool)

func (*AVCaptureExternalDisplayConfiguration) ShouldMatchFrameRate ¶

func (o *AVCaptureExternalDisplayConfiguration) ShouldMatchFrameRate() bool

A property indicating whether the frame rate of the external display should be configured to match the camera's frame rate. If you want to configure your “AVCaptureVideoPreviewLayer“ to match its source “AVCaptureDevice/activeVideoMinFrameDuration“, set “shouldMatchFrameRate“ to `true`. The default value is `false`.

type AVCaptureExternalDisplayConfigurator ¶

type AVCaptureExternalDisplayConfigurator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureexternaldisplayconfigurator

func AVCaptureExternalDisplayConfiguratorFromID ¶

func AVCaptureExternalDisplayConfiguratorFromID(id objc.ID) *AVCaptureExternalDisplayConfigurator

func (*AVCaptureExternalDisplayConfigurator) ActiveExternalDisplayFrameRate ¶

func (o *AVCaptureExternalDisplayConfigurator) ActiveExternalDisplayFrameRate() float64

The currently configured frame rate on the external display that's displaying the preview layer. Observe this property to determine if the configured frame rate matches the max frame rate (“AVCaptureDevice/activeVideoMinFrameDuration“) of the device. When the “active“ property becomes `false`, this property changes to 0.

func (*AVCaptureExternalDisplayConfigurator) Device ¶

The device for which the coordinator configures the preview layer. The value of this property is the “AVCaptureDevice“ instance you provided when instantiating the configurator. “AVCaptureExternalDisplayConfigurator“ holds a weak reference to the device. If the device is released, this property returns `nil`.

func (*AVCaptureExternalDisplayConfigurator) InitWithDevicePreviewLayerConfiguration ¶

func (o *AVCaptureExternalDisplayConfigurator) InitWithDevicePreviewLayerConfiguration(device *AVCaptureDevice, previewLayer *quartzcore.CALayer, configuration *AVCaptureExternalDisplayConfiguration) *AVCaptureExternalDisplayConfigurator

An external display configurator instance that attempts to synchronize the preview layer configuration with the device capture configuration. - Parameter device: The device for which to monitor the configuration. - Parameter previewLayer: The layer that is being used on an external display for displaying the camera preview. - Parameter configuration: A configuration specifying which aspects of the camera's active format to monitor and configure on the external display. - Returns: an “AVCaptureExternalDisplayConfigurator“ instance. An “AVCaptureExternalDisplayConfigurator“ is only applicable to external displays. It determines which properties to configure on the external display based on your provided configuration (see “AVCaptureExternalDisplayConfiguration“). The configurator observes changes to your camera”s configuration, and when changes are observed, it modifies the external display's properties to match. If multiple configurators are linked to the same external display ,the last one created becomes the active configurator for the external display (see “active“). - Important: An `NSInvalidArgumentException` is thrown if any of the “AVCaptureExternalDisplayConfiguration“ options are not supported.

func (*AVCaptureExternalDisplayConfigurator) IsActive ¶

This property tells you whether the configurator is actively configuring the external display. When this property returns `true`, the external display is successfully configured to match the device. If it returns`false`, the configurator is not making any configuration changes to the external display. If another “AVCaptureExternalDisplayConfigurator“ instance takes over the configuration of the external display, this property returns `false`.

func (*AVCaptureExternalDisplayConfigurator) PreviewLayer ¶

The layer for which the configurator adjusts display properties to match the device's state. The value of this property is the “CALayer“ instance that you provided when instantiating the configurator. You may specify either an “AVCaptureVideoPreviewLayer“ or another “CALayer“ instance that displays a camera's video preview. “AVCaptureExternalDisplayConfigurator“holds a weak reference to the layer. If the layer is released, this property returns `nil`.

func (*AVCaptureExternalDisplayConfigurator) Stop ¶

Forces the external display configurator to asynchronously stop configuring the external display. Call “stop“ to force the “AVCaptureExternalDisplayConfigurator“ to asynchronously stop configuring the external display. Once stopped, the “active“ property changes to `false` and the “activeExternalDisplayFrameRate“ becomes 0.

type AVCaptureFileOutput ¶

type AVCaptureFileOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturefileoutput

func AVCaptureFileOutputFromID ¶

func AVCaptureFileOutputFromID(id objc.ID) *AVCaptureFileOutput

func (*AVCaptureFileOutput) Delegate ¶

@property delegate @abstract The receiver's delegate. @discussion The value of this property is an object conforming to the AVCaptureFileOutputDelegate protocol that will be able to monitor and control recording along exact sample boundaries.

func (*AVCaptureFileOutput) IsRecording ¶

func (o *AVCaptureFileOutput) IsRecording() bool

@property recording @abstract Indicates whether the receiver is currently recording. @discussion The value of this property is YES when the receiver currently has a file to which it is writing new samples, NO otherwise.

func (*AVCaptureFileOutput) IsRecordingPaused ¶

func (o *AVCaptureFileOutput) IsRecordingPaused() bool

@property recordingPaused @abstract Indicates whether recording to the current output file is paused. @discussion This property indicates recording to the file returned by outputFileURL has been previously paused using the pauseRecording method. When a recording is paused, captured samples are not written to the output file, but new samples can be written to the same file in the future by calling resumeRecording.

func (*AVCaptureFileOutput) MaxRecordedDuration ¶

func (o *AVCaptureFileOutput) MaxRecordedDuration() coremedia.CMTime

@property maxRecordedDuration @abstract Specifies the maximum duration of the media that should be recorded by the receiver. @discussion This property specifies a hard limit on the duration of recorded files. Recording is stopped when the limit is reached and the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: delegate method is invoked with an appropriate error. The default value of this property is kCMTimeInvalid, which indicates no limit.

func (*AVCaptureFileOutput) MaxRecordedFileSize ¶

func (o *AVCaptureFileOutput) MaxRecordedFileSize() int64

@property maxRecordedFileSize @abstract Specifies the maximum size, in bytes, of the data that should be recorded by the receiver. @discussion This property specifies a hard limit on the data size of recorded files. Recording is stopped when the limit is reached and the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: delegate method is invoked with an appropriate error. The default value of this property is 0, which indicates no limit.

func (*AVCaptureFileOutput) MinFreeDiskSpaceLimit ¶

func (o *AVCaptureFileOutput) MinFreeDiskSpaceLimit() int64

@property minFreeDiskSpaceLimit @abstract Specifies the minimum amount of free space, in bytes, required for recording to continue on a given volume. @discussion This property specifies a hard lower limit on the amount of free space that must remain on a target volume for recording to continue. Recording is stopped when the limit is reached and the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: delegate method is invoked with an appropriate error.

func (*AVCaptureFileOutput) OutputFileURL ¶

func (o *AVCaptureFileOutput) OutputFileURL() *foundation.NSURL

@property outputFileURL @abstract The file URL of the file to which the receiver is currently recording incoming buffers. @discussion The value of this property is an NSURL object containing the file URL of the file currently being written by the receiver. Returns nil if the receiver is not recording to any file.

func (*AVCaptureFileOutput) PauseRecording ¶

func (o *AVCaptureFileOutput) PauseRecording()

@method pauseRecording @abstract Pauses recording to the current output file. @discussion This method causes the receiver to stop writing captured samples to the current output file returned by outputFileURL, but leaves the file open so that samples can be written to it in the future, when resumeRecording is called. This allows clients to record multiple media segments that are not contiguous in time to a single file. On macOS, if this method is called within the captureOutput:didOutputSampleBuffer:fromConnection: delegate method, the last samples written to the current file are guaranteed to be those that were output immediately before those in the sample buffer passed to that method. A recording can be stopped as normal, even when it's paused. A format or device change will result in the recording being stopped, even when it's paused.

func (*AVCaptureFileOutput) RecordedDuration ¶

func (o *AVCaptureFileOutput) RecordedDuration() coremedia.CMTime

@property recordedDuration @abstract Indicates the duration of the media recorded to the current output file. @discussion If recording is in progress, this property returns the total time recorded so far.

func (*AVCaptureFileOutput) RecordedFileSize ¶

func (o *AVCaptureFileOutput) RecordedFileSize() int64

@property recordedFileSize @abstract Indicates the size, in bytes, of the data recorded to the current output file. @discussion If a recording is in progress, this property returns the size in bytes of the data recorded so far.

func (*AVCaptureFileOutput) ResumeRecording ¶

func (o *AVCaptureFileOutput) ResumeRecording()

@method resumeRecording @abstract Resumes recording to the current output file after it was previously paused using pauseRecording. @discussion This method causes the receiver to resume writing captured samples to the current output file returned by outputFileURL, after recording was previously paused using pauseRecording. This allows clients to record multiple media segments that are not contiguous in time to a single file. On macOS, if this method is called within the captureOutput:didOutputSampleBuffer:fromConnection: delegate method, the first samples written to the current file are guaranteed to be those contained in the sample buffer passed to that method.

func (*AVCaptureFileOutput) SetDelegate ¶

func (o *AVCaptureFileOutput) SetDelegate(delegate AVCaptureFileOutputDelegate)

func (*AVCaptureFileOutput) SetMaxRecordedDuration ¶

func (o *AVCaptureFileOutput) SetMaxRecordedDuration(maxRecordedDuration coremedia.CMTime)

func (*AVCaptureFileOutput) SetMaxRecordedFileSize ¶

func (o *AVCaptureFileOutput) SetMaxRecordedFileSize(maxRecordedFileSize int64)

func (*AVCaptureFileOutput) SetMinFreeDiskSpaceLimit ¶

func (o *AVCaptureFileOutput) SetMinFreeDiskSpaceLimit(minFreeDiskSpaceLimit int64)

func (*AVCaptureFileOutput) StartRecordingToOutputFileURLRecordingDelegate ¶

func (o *AVCaptureFileOutput) StartRecordingToOutputFileURLRecordingDelegate(outputFileURL *foundation.NSURL, delegate AVCaptureFileOutputRecordingDelegate)

@method startRecordingToOutputFileURL:recordingDelegate: @abstract Tells the receiver to start recording to a new file, and specifies a delegate that will be notified when recording is finished. @param outputFileURL An NSURL object containing the URL of the output file. This method throws an NSInvalidArgumentException if the URL is not a valid file URL. @param delegate An object conforming to the AVCaptureFileOutputRecordingDelegate protocol. Clients must specify a delegate so that they can be notified when recording to the given URL is finished. @discussion The method sets the file URL to which the receiver is currently writing output media. If a file at the given URL already exists when capturing starts, recording to the new file will fail. Clients need not call stopRecording before calling this method while another recording is in progress. On macOS, if this method is invoked while an existing output file was already being recorded, no media samples will be discarded between the old file and the new file. When recording is stopped either by calling stopRecording, by changing files using this method, or because of an error, the remaining data that needs to be included to the file will be written in the background. Therefore, clients must specify a delegate that will be notified when all data has been written to the file using the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: method. The recording delegate can also optionally implement methods that inform it when data starts being written, when recording is paused and resumed, and when recording is about to be finished. On macOS, if this method is called within the captureOutput:didOutputSampleBuffer:fromConnection: delegate method, the first samples written to the new file are guaranteed to be those contained in the sample buffer passed to that method. Note: AVCaptureAudioFileOutput does not support -startRecordingToOutputFileURL:recordingDelegate:. Use -startRecordingToOutputFileURL:outputFileType:recordingDelegate: instead.

func (*AVCaptureFileOutput) StopRecording ¶

func (o *AVCaptureFileOutput) StopRecording()

@method stopRecording @abstract Tells the receiver to stop recording to the current file. @discussion Clients can call this method when they want to stop recording new samples to the current file, and do not want to continue recording to another file. Clients that want to switch from one file to another should not call this method. Instead they should simply call startRecordingToOutputFileURL:recordingDelegate: with the new file URL. When recording is stopped either by calling this method, by changing files using startRecordingToOutputFileURL:recordingDelegate:, or because of an error, the remaining data that needs to be included to the file will be written in the background. Therefore, before using the file, clients must wait until the delegate that was specified in startRecordingToOutputFileURL:recordingDelegate: is notified when all data has been written to the file using the captureOutput:didFinishRecordingToOutputFileAtURL:fromConnections:error: method. On macOS, if this method is called within the captureOutput:didOutputSampleBuffer:fromConnection: delegate method, the last samples written to the current file are guaranteed to be those that were output immediately before those in the sample buffer passed to that method.

type AVCaptureFileOutputDelegate ¶

type AVCaptureFileOutputDelegate interface {
	CaptureOutputShouldProvideSampleAccurateRecordingStart(output *AVCaptureOutput) bool
}

AVCaptureFileOutputDelegate wraps the ObjC protocol AVCaptureFileOutputDelegate.

type AVCaptureFileOutputRecordingDelegate ¶

type AVCaptureFileOutputRecordingDelegate interface {
	CaptureOutputDidFinishRecordingToOutputFileAtURLFromConnectionsError(output *AVCaptureFileOutput, outputFileURL *foundation.NSURL, connections *foundation.NSArray[*AVCaptureConnection], error_ unsafe.Pointer)
}

AVCaptureFileOutputRecordingDelegate wraps the ObjC protocol AVCaptureFileOutputRecordingDelegate.

type AVCaptureFlashMode ¶

type AVCaptureFlashMode int64
const (
	AVCaptureFlashModeOff  AVCaptureFlashMode = 0
	AVCaptureFlashModeOn   AVCaptureFlashMode = 1
	AVCaptureFlashModeAuto AVCaptureFlashMode = 2
)

func (AVCaptureFlashMode) String ¶

func (e AVCaptureFlashMode) String() string

type AVCaptureFocusMode ¶

type AVCaptureFocusMode int64
const (
	AVCaptureFocusModeLocked              AVCaptureFocusMode = 0
	AVCaptureFocusModeAutoFocus           AVCaptureFocusMode = 1
	AVCaptureFocusModeContinuousAutoFocus AVCaptureFocusMode = 2
)

func (AVCaptureFocusMode) String ¶

func (e AVCaptureFocusMode) String() string

type AVCaptureIndexPicker ¶

type AVCaptureIndexPicker struct {
	AVCaptureControl
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureindexpicker

func AVCaptureIndexPickerFromID ¶

func AVCaptureIndexPickerFromID(id objc.ID) *AVCaptureIndexPicker

func (*AVCaptureIndexPicker) AccessibilityIdentifier ¶

func (o *AVCaptureIndexPicker) AccessibilityIdentifier() *foundation.NSString

@property accessibilityIdentifier @abstract A string that identifies the picker.

func (*AVCaptureIndexPicker) InitWithLocalizedTitleSymbolNameLocalizedIndexTitles ¶

func (o *AVCaptureIndexPicker) InitWithLocalizedTitleSymbolNameLocalizedIndexTitles(localizedTitle *foundation.NSString, symbolName *foundation.NSString, localizedIndexTitles *foundation.NSArray[*foundation.NSString]) *AVCaptureIndexPicker

@method initWithLocalizedTitle:symbolName:localizedIndexTitles: @abstract Initializes an `AVCaptureIndexPicker` to pick between `localizedIndexTitles.count` values. @param localizedTitle A localized string that describes the picker's `action`. @param symbolName The name of a symbol to represent the picker. @param localizedIndexTitles The titles to use for each index. `localizedIndexTitles` must be greater than 0, otherwise an `NSInvalidArgumentException` is thrown. @result An `AVCaptureIndexPicker` instance that picks between `localizedIndexTitles.count` values. @discussion Suitable when you already have an array containing a title for each picked value.

func (*AVCaptureIndexPicker) InitWithLocalizedTitleSymbolNameNumberOfIndexes ¶

func (o *AVCaptureIndexPicker) InitWithLocalizedTitleSymbolNameNumberOfIndexes(localizedTitle *foundation.NSString, symbolName *foundation.NSString, numberOfIndexes int) *AVCaptureIndexPicker

@method initWithLocalizedTitle:symbolName:numberOfIndexes: @abstract Initializes an `AVCaptureIndexPicker` to pick between `numberOfIndexes` values. @param localizedTitle A localized string that describes the picker's `action`. @param symbolName The name of a symbol to represent the picker. @param numberOfIndexes The number of indexes to pick between. `numberOfIndexes` must be greater than 0, otherwise an `NSInvalidArgumentException` is thrown. @result An `AVCaptureIndexPicker` instance that picks between `numberOfIndexes` values. @discussion Suitable when your picked values don't need titles.

func (*AVCaptureIndexPicker) InitWithLocalizedTitleSymbolNameNumberOfIndexesLocalizedTitleTransform ¶

func (o *AVCaptureIndexPicker) InitWithLocalizedTitleSymbolNameNumberOfIndexesLocalizedTitleTransform(localizedTitle *foundation.NSString, symbolName *foundation.NSString, numberOfIndexes int, localizedTitleTransform objc.Block) *AVCaptureIndexPicker

@method initWithLocalizedTitle:symbolName:numberOfIndexes:localizedTitleTransform: @abstract Initializes an `AVCaptureIndexPicker` to pick between `numberOfIndexes` values. @param localizedTitle A localized string that describes the picker's `action`. @param symbolName The name of a symbol to represent the picker. @param numberOfIndexes The number of indexes to pick between. `numberOfIndexes` must be greater than 0, otherwise an `NSInvalidArgumentException` is thrown. @param localizedTitleTransform A transformation from index to localized title. @result An `AVCaptureIndexPicker` instance that picks between `numberOfIndexes` values with a transformation from index to localized title. @discussion Suitable when you want to provide a title for each picked value lazily.

func (*AVCaptureIndexPicker) LocalizedIndexTitles ¶

func (o *AVCaptureIndexPicker) LocalizedIndexTitles() *foundation.NSArray[*foundation.NSString]

@property localizedIndexTitles @abstract The titles used for each index.

func (*AVCaptureIndexPicker) LocalizedTitle ¶

func (o *AVCaptureIndexPicker) LocalizedTitle() *foundation.NSString

@property localizedTitle @abstract A localized string that describes the picker's `action`.

func (*AVCaptureIndexPicker) NumberOfIndexes ¶

func (o *AVCaptureIndexPicker) NumberOfIndexes() int

@property numberOfIndexes @abstract The number of indexes to pick between.

func (*AVCaptureIndexPicker) SelectedIndex ¶

func (o *AVCaptureIndexPicker) SelectedIndex() int

@property selectedIndex @abstract The currently selected index. @discussion Because the camera system may be independent from the main thread or `@MainActor`, `selectedIndex` must be changed on `actionQueue` – the queue provided to `setActionQueue:action:`. The default value is 0. An index may only be set if it is greater than 0 or less than `numberOfIndexes`, otherwise an `NSInvalidArgumentException` is thrown.

func (*AVCaptureIndexPicker) SetAccessibilityIdentifier ¶

func (o *AVCaptureIndexPicker) SetAccessibilityIdentifier(accessibilityIdentifier *foundation.NSString)

func (*AVCaptureIndexPicker) SetActionQueueAction ¶

func (o *AVCaptureIndexPicker) SetActionQueueAction(actionQueue *foundation.NSObject, action func(int))

@method setActionQueue:action: @abstract Configures the picker's `action` which is called on `actionQueue` whenever the index of the picker is changed. @param actionQueue A queue for the `action` to be called. @param action An action called on `actionQueue` whenever the selected index of the picker is changed. @discussion Because the camera system may be independent from the main thread or `@MainActor`, `action` is always called on an internal `DispatchSerialQueue` targeted at `actionQueue`. If `action` modifies a property of the camera system, `actionQueue` must represent the same exclusive execution context as the camera system (see `isSameExclusiveExecutionContext`).

func (*AVCaptureIndexPicker) SetSelectedIndex ¶

func (o *AVCaptureIndexPicker) SetSelectedIndex(selectedIndex int)

func (*AVCaptureIndexPicker) SymbolName ¶

func (o *AVCaptureIndexPicker) SymbolName() *foundation.NSString

@property symbolName @abstract The name of a symbol to represent the picker.

type AVCaptureInput ¶

type AVCaptureInput struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureinput

func AVCaptureInputFromID ¶

func AVCaptureInputFromID(id objc.ID) *AVCaptureInput

func (*AVCaptureInput) Ports ¶

type AVCaptureInputPort ¶

type AVCaptureInputPort struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureinputport

func AVCaptureInputPortFromID ¶

func AVCaptureInputPortFromID(id objc.ID) *AVCaptureInputPort

func (*AVCaptureInputPort) Clock ¶

func (o *AVCaptureInputPort) Clock() unsafe.Pointer

@property clock @abstract Provides access to the "native" clock used by the input port. @discussion The clock is read-only.

func (*AVCaptureInputPort) FormatDescription ¶

func (o *AVCaptureInputPort) FormatDescription() unsafe.Pointer

@property formatDescription @abstract The format of the data provided by the receiver. @discussion The value of this property is a CMFormatDescription that describes the format of the media data currently provided by the receiver. Clients can be notified of changes to the format by observing the AVCaptureInputPortFormatDescriptionDidChangeNotification.

func (*AVCaptureInputPort) Input ¶

func (o *AVCaptureInputPort) Input() *AVCaptureInput

@property input @abstract The input that owns the receiver. @discussion The value of this property is an AVCaptureInput instance that owns the receiver.

func (*AVCaptureInputPort) IsEnabled ¶

func (o *AVCaptureInputPort) IsEnabled() bool

@property enabled @abstract Whether the receiver should provide data. @discussion The value of this property is a BOOL that determines whether the receiver should provide data to outputs when a session is running. Clients can set this property to fine tune which media streams from a given input will be used during capture. The default value is YES.

func (*AVCaptureInputPort) MediaType ¶

func (o *AVCaptureInputPort) MediaType() *foundation.NSString

@property mediaType @abstract The media type of the data provided by the receiver. @discussion The value of this property is a constant describing the type of media, such as AVMediaTypeVideo or AVMediaTypeAudio, provided by the receiver. Media type constants are defined in AVMediaFormat.h.

func (*AVCaptureInputPort) SetEnabled ¶

func (o *AVCaptureInputPort) SetEnabled(enabled bool)

type AVCaptureMetadataOutput ¶

type AVCaptureMetadataOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturemetadataoutput

func AVCaptureMetadataOutputFromID ¶

func AVCaptureMetadataOutputFromID(id objc.ID) *AVCaptureMetadataOutput

func AVCaptureMetadataOutputNew ¶

func AVCaptureMetadataOutputNew() *AVCaptureMetadataOutput

func (*AVCaptureMetadataOutput) AvailableMetadataObjectTypes ¶

func (o *AVCaptureMetadataOutput) AvailableMetadataObjectTypes() *foundation.NSArray[*foundation.NSString]

@property availableMetadataObjectTypes @abstract Indicates the receiver's supported metadata object types. @discussion The value of this property is an NSArray of NSStrings corresponding to AVMetadataObjectType strings defined in AVMetadataObject.h -- one for each metadata object type supported by the receiver. Available metadata object types are dependent on the capabilities of the AVCaptureInputPort to which this receiver's AVCaptureConnection is connected. Clients may specify the types of objects they would like to process by calling setMetadataObjectTypes:. This property is key-value observable.

func (*AVCaptureMetadataOutput) Init ¶

func (*AVCaptureMetadataOutput) MetadataObjectTypes ¶

func (o *AVCaptureMetadataOutput) MetadataObjectTypes() *foundation.NSArray[*foundation.NSString]

@property metadataObjectTypes @abstract Specifies the types of metadata objects that the receiver should present to the client. @discussion AVCaptureMetadataOutput may detect and emit multiple metadata object types. For apps linked before iOS 7.0, the receiver defaults to capturing face metadata objects if supported (see -availableMetadataObjectTypes). For apps linked on or after iOS 7.0, the receiver captures no metadata objects by default. -setMetadataObjectTypes: throws an NSInvalidArgumentException if any elements in the array are not present in the -availableMetadataObjectTypes array. If you've set your AVCaptureMetadataOutput's connected input's `cinematicVideoCaptureEnabled` property to YES, you must set your `metadataObjectTypes` property to `requiredMetadataObjectTypesForCinematicVideoCapture` or an NSInvalidArgumentException is thrown.

func (*AVCaptureMetadataOutput) MetadataObjectsCallbackQueue ¶

func (o *AVCaptureMetadataOutput) MetadataObjectsCallbackQueue() *foundation.NSObject

@property metadataObjectsCallbackQueue @abstract The dispatch queue on which all metadata object delegate methods will be called. @discussion The value of this property is a dispatch_queue_t. The queue is set using the setMetadataObjectsDelegate:queue: method.

func (*AVCaptureMetadataOutput) MetadataObjectsDelegate ¶

@property metadataObjectsDelegate @abstract The receiver's delegate. @discussion The value of this property is an object conforming to the AVCaptureMetadataOutputObjectsDelegate protocol that will receive metadata objects after they are captured. The delegate is set using the setMetadataObjectsDelegate:queue: method.

func (*AVCaptureMetadataOutput) RectOfInterest ¶

func (o *AVCaptureMetadataOutput) RectOfInterest() corefoundation.CGRect

@property rectOfInterest @abstract Specifies a rectangle of interest for limiting the search area for visual metadata. @discussion The value of this property is a CGRect that determines the receiver's rectangle of interest for each frame of video. The rectangle's origin is top left and is relative to the coordinate space of the device providing the metadata. Specifying a rectOfInterest may improve detection performance for certain types of metadata. The default value of this property is the value CGRectMake(0, 0, 1, 1). Metadata objects whose bounds do not intersect with the rectOfInterest will not be returned. As of iOS 13, this property can be set without requiring a lengthy rebuild of the session in which video preview is disrupted.

func (*AVCaptureMetadataOutput) RequiredMetadataObjectTypesForCinematicVideoCapture ¶

func (o *AVCaptureMetadataOutput) RequiredMetadataObjectTypesForCinematicVideoCapture() *foundation.NSArray[*foundation.NSString]

The required metadata object types when Cinematic Video capture is enabled. Since the Cinematic Video algorithm requires a particular set of metadata objects to function optimally, you must set your “metadataObjectTypes“ property to this property's returned value if you've set “AVCaptureDeviceInput/cinematicVideoCaptureEnabled“ to `true` on the connected device input, otherwise an `NSInvalidArgumentException` is thrown.

func (*AVCaptureMetadataOutput) SetMetadataObjectTypes ¶

func (o *AVCaptureMetadataOutput) SetMetadataObjectTypes(metadataObjectTypes *foundation.NSArray[*foundation.NSString])

func (*AVCaptureMetadataOutput) SetMetadataObjectsDelegateQueue ¶

func (o *AVCaptureMetadataOutput) SetMetadataObjectsDelegateQueue(objectsDelegate AVCaptureMetadataOutputObjectsDelegate, objectsCallbackQueue *foundation.NSObject)

@method setMetadataObjectsDelegate:queue: @abstract Sets the receiver's delegate that will accept metadata objects and dispatch queue on which the delegate will be called. @param objectsDelegate An object conforming to the AVCaptureMetadataOutputObjectsDelegate protocol that will receive metadata objects after they are captured. @param objectsCallbackQueue A dispatch queue on which all delegate methods will be called. @discussion When new metadata objects are captured in the receiver's connection, they will be vended to the delegate using the captureOutput:didOutputMetadataObjects:fromConnection: delegate method. All delegate methods will be called on the specified dispatch queue. Clients that need to minimize the chances of metadata being dropped should specify a queue on which a sufficiently small amount of processing is performed along with receiving metadata objects. A serial dispatch queue must be used to guarantee that metadata objects will be delivered in order. The objectsCallbackQueue parameter may not be NULL, except when setting the objectsDelegate to nil otherwise -setMetadataObjectsDelegate:queue: throws an NSInvalidArgumentException.

func (*AVCaptureMetadataOutput) SetRectOfInterest ¶

func (o *AVCaptureMetadataOutput) SetRectOfInterest(rectOfInterest corefoundation.CGRect)

type AVCaptureMetadataOutputObjectsDelegate ¶

type AVCaptureMetadataOutputObjectsDelegate interface {
}

AVCaptureMetadataOutputObjectsDelegate wraps the ObjC protocol AVCaptureMetadataOutputObjectsDelegate.

type AVCaptureMicrophoneMode ¶

type AVCaptureMicrophoneMode int64
const (
	AVCaptureMicrophoneModeStandard       AVCaptureMicrophoneMode = 0
	AVCaptureMicrophoneModeWideSpectrum   AVCaptureMicrophoneMode = 1
	AVCaptureMicrophoneModeVoiceIsolation AVCaptureMicrophoneMode = 2
)

func AVCaptureDeviceActiveMicrophoneMode ¶

func AVCaptureDeviceActiveMicrophoneMode() AVCaptureMicrophoneMode

@property activeMicrophoneMode @abstract Indicates the currently active microphone mode. @discussion This readonly property returns the currently active microphone mode, which may differ from the preferredMicrophoneMode if the application's active audio route does not support the preferred microphone mode. This property is key-value observable.

func AVCaptureDevicePreferredMicrophoneMode ¶

func AVCaptureDevicePreferredMicrophoneMode() AVCaptureMicrophoneMode

@property preferredMicrophoneMode @abstract Indicates the microphone mode that has been selected by the user in Control Center. @discussion This readonly property returns the microphone mode selected by the user in Control Center. It is key-value observable.

func (AVCaptureMicrophoneMode) String ¶

func (e AVCaptureMicrophoneMode) String() string

type AVCaptureMovieFileOutput ¶

type AVCaptureMovieFileOutput struct {
	AVCaptureFileOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturemoviefileoutput

func AVCaptureMovieFileOutputFromID ¶

func AVCaptureMovieFileOutputFromID(id objc.ID) *AVCaptureMovieFileOutput

func AVCaptureMovieFileOutputNew ¶

func AVCaptureMovieFileOutputNew() *AVCaptureMovieFileOutput

func (*AVCaptureMovieFileOutput) Init ¶

func (*AVCaptureMovieFileOutput) IsPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled ¶

func (o *AVCaptureMovieFileOutput) IsPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled() bool

@property primaryConstituentDeviceSwitchingBehaviorForRecordingEnabled @abstract Enable or disable a constituent device selection behavior when recording. @discussion This property enables a camera selection behavior to be applied when recording a movie. Once recording starts, the specified behavior and conditions take effect. Once recording stops the camera selection will change back to the primaryConstituentDeviceSwitchingBehavior specified by the AVCaptureDevice. By default, this property is set to YES when connected to an AVCaptureDevice that supports constituent device switching.

func (*AVCaptureMovieFileOutput) IsSpatialVideoCaptureEnabled ¶

func (o *AVCaptureMovieFileOutput) IsSpatialVideoCaptureEnabled() bool

@property spatialVideoCaptureEnabled @abstract Enable or disable capturing spatial video to a file. @discussion This property enables capturing spatial video to a file. By default, this property is set to NO. Check spatialVideoCaptureSupported before setting this property, as setting to YES will throw an exception if the feature is not supported. On iOS, enabling spatial video will overwrite the connected AVCaptureDevice's `videoZoomFactor`, `minAvailableVideoZoomFactor`, and `maxAvailableVideoZoomFactor` to the field of view of the narrower camera in the pair. When spatialVideoCaptureEnabled is true, setting -[AVCaptureDeviceInput activeVideoMinFrameDuration] or -[AVCaptureDeviceInput activeVideoMaxFrameDuration] throws an NSInvalidArgumentException. Enabling this property throws an NSInvalidArgumentException if -[AVCaptureDevice isVideoFrameDurationLocked] or -[AVCaptureDevice isFollowingExternalSyncDevice] is true.

func (*AVCaptureMovieFileOutput) IsSpatialVideoCaptureSupported ¶

func (o *AVCaptureMovieFileOutput) IsSpatialVideoCaptureSupported() bool

@property spatialVideoCaptureSupported @abstract Returns whether or not capturing spatial video to a file is supported. Note that in order to be supported, two conditions must be met. (1) The source AVCaptureDevice's activeFormat.spatialVideoCaptureSupported property must return YES. (2) The video AVCaptureConnection's activeVideoStabilizationMode property must return AVCaptureVideoStabilizationModeCinematic, AVCaptureVideoStabilizationModeCinematicExtended, or AVCaptureVideoStabilizationModeCinematicExtendedEnhanced.

func (*AVCaptureMovieFileOutput) Metadata ¶

@property metadata @abstract A collection of metadata to be written to the receiver's output files. @discussion The value of this property is an array of AVMetadataItem objects representing the collection of top-level metadata to be written in each output file.

func (*AVCaptureMovieFileOutput) MovieFragmentInterval ¶

func (o *AVCaptureMovieFileOutput) MovieFragmentInterval() coremedia.CMTime

@property movieFragmentInterval @abstract Specifies the frequency with which movie fragments should be written. @discussion When movie fragments are used, a partially written QuickTime movie file whose writing is unexpectedly interrupted can be successfully opened and played up to multiples of the specified time interval. A value of kCMTimeInvalid indicates that movie fragments should not be used, but that only a movie atom describing all of the media in the file should be written. The default value of this property is ten seconds. Changing the value of this property will not affect the movie fragment interval of the file currently being written, if there is one. For best writing performance on external storage devices, set the movieFragmentInterval to 10 seconds or greater. If the size of a movie fragment is greater than or equal to 2GB, an interval is added at 2GB mark.

func (*AVCaptureMovieFileOutput) OutputSettingsForConnection ¶

func (o *AVCaptureMovieFileOutput) OutputSettingsForConnection(connection *AVCaptureConnection) *foundation.NSDictionary[*foundation.NSString, objc.ID]

@method outputSettingsForConnection: @abstract Returns the options the receiver uses to encode media from the given connection as it is being recorded. @param connection The connection delivering the media to be encoded. @result An NSDictionary of output settings. @discussion See AVAudioSettings.h for audio connections or AVVideoSettings.h for video connections for more information on the structure of an output settings dictionary. If the returned value is an empty dictionary (i.e. [NSDictionary dictionary], the format of the media from the connection will not be changed before being written to the file. If -setOutputSettings:forConnection: was called with a nil dictionary, this method returns a non-nil dictionary reflecting the settings used by the AVCaptureSession's current sessionPreset.

func (*AVCaptureMovieFileOutput) PrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionsForRecording ¶

func (o *AVCaptureMovieFileOutput) PrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionsForRecording() AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions

@property primaryConstituentDeviceRestrictedSwitchingBehaviorConditionsForRecording @abstract The primaryConstituentDeviceRestrictedSwitchingBehaviorConditions as set by -[AVCaptureMovieFileOutput setPrimaryConstituentDeviceSwitchingBehaviorForRecording:restrictedSwitchingBehaviorConditions:]. @discussion By default, this property is set to AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorCondition{VideoZoomChanged | FocusModeChanged | ExposureModeChanged}. This property is key-value observable.

func (*AVCaptureMovieFileOutput) PrimaryConstituentDeviceSwitchingBehaviorForRecording ¶

func (o *AVCaptureMovieFileOutput) PrimaryConstituentDeviceSwitchingBehaviorForRecording() AVCapturePrimaryConstituentDeviceSwitchingBehavior

@property primaryConstituentDeviceSwitchingBehaviorForRecording @abstract The primaryConstituentDeviceSwitchingBehavior as set by -[AVCaptureMovieFileOutput setPrimaryConstituentDeviceSwitchingBehaviorForRecording:restrictedSwitchingBehaviorConditions:]. @discussion By default, this property is set to AVCapturePrimaryConstituentDeviceSwitchingBehaviorRestricted. This property is key-value observable.

func (*AVCaptureMovieFileOutput) SetMetadata ¶

func (o *AVCaptureMovieFileOutput) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVCaptureMovieFileOutput) SetMovieFragmentInterval ¶

func (o *AVCaptureMovieFileOutput) SetMovieFragmentInterval(movieFragmentInterval coremedia.CMTime)

func (*AVCaptureMovieFileOutput) SetOutputSettingsForConnection ¶

func (o *AVCaptureMovieFileOutput) SetOutputSettingsForConnection(outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID], connection *AVCaptureConnection)

@method setOutputSettings:forConnection: @abstract Sets the options the receiver uses to encode media from the given connection as it is being recorded. @param outputSettings An NSDictionary of output settings. @param connection The connection delivering the media to be encoded. @discussion See AVAudioSettings.h for audio connections or AVVideoSettings.h for video connections for more information on how to construct an output settings dictionary. A value of an empty dictionary (i.e. +[NSDictionary dictionary]), means that the format of the media from the connection should not be changed before being written to the file. A value of nil means that the output format will be determined by the session preset. In this case, -outputSettingsForConnection: will return a non-nil dictionary reflecting the settings used by the AVCaptureSession's current sessionPreset. On iOS, your outputSettings dictionary may only contain keys listed in - supportedOutputSettingsKeysForConnection:. If you specify any other key, an NSInvalidArgumentException will be thrown. Further restrictions may be imposed on the AVVideoCodecTypeKey. Its value should be present in the -availableVideoCodecTypes array. If AVVideoCompressionPropertiesKey is specified, you must also specify a valid value for AVVideoCodecKey. On iOS versions prior to 12.0, the only settable key for video connections is AVVideoCodecTypeKey. On iOS 12.0 and later, video connections gain support for AVVideoCompressionPropertiesKey. On iOS, -outputSettingsForConnection: always provides a fully populated dictionary. If you call -outputSettingsForConnection: with the intent of overriding a few of the values, you must take care to exclude keys that are not supported before calling -setOutputSettings:forConnection:. When providing an AVVideoCompressionPropertiesKey sub dictionary, you may specify a sparse dictionary. AVCaptureMovieFileOutput will always fill in missing keys with default values for the current AVCaptureSession configuration.

func (*AVCaptureMovieFileOutput) SetPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled ¶

func (o *AVCaptureMovieFileOutput) SetPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled(primaryConstituentDeviceSwitchingBehaviorForRecordingEnabled bool)

func (*AVCaptureMovieFileOutput) SetPrimaryConstituentDeviceSwitchingBehaviorForRecordingRestrictedSwitchingBehaviorConditions ¶

func (o *AVCaptureMovieFileOutput) SetPrimaryConstituentDeviceSwitchingBehaviorForRecordingRestrictedSwitchingBehaviorConditions(switchingBehavior AVCapturePrimaryConstituentDeviceSwitchingBehavior, restrictedSwitchingBehaviorConditions AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions)

@method setPrimaryConstituentDeviceSwitchingBehaviorForRecording:restrictedSwitchingBehaviorConditions: @abstract When primaryConstituentDeviceSwitchingBehaviorForRecordingEnabled is set to YES, this method controls the switching behavior and conditions, while a movie file is being recorded. @discussion This controls the camera selection behavior used while recording a movie, when enabled through primaryConstituentDeviceSwitchingBehaviorForRecordingEnabled. Setting the switching behavior to anything other than AVCapturePrimaryConstituentDeviceSwitchingBehaviorUnsupported when connected to an AVCaptureDevice that does not support constituent device selection throws an NSInvalidArgumentException. Setting restrictedSwitchingBehaviorConditions to something other than AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionNone while setting switchingBehavior to something other than AVCapturePrimaryConstituentDeviceSwitchingBehaviorRestricted throws an NSInvalidArgumentException exception.

func (*AVCaptureMovieFileOutput) SetSpatialVideoCaptureEnabled ¶

func (o *AVCaptureMovieFileOutput) SetSpatialVideoCaptureEnabled(spatialVideoCaptureEnabled bool)

type AVCaptureMultichannelAudioMode ¶

type AVCaptureMultichannelAudioMode int64
const (
	AVCaptureMultichannelAudioModeNone                 AVCaptureMultichannelAudioMode = 0
	AVCaptureMultichannelAudioModeStereo               AVCaptureMultichannelAudioMode = 1
	AVCaptureMultichannelAudioModeFirstOrderAmbisonics AVCaptureMultichannelAudioMode = 2
)

func (AVCaptureMultichannelAudioMode) String ¶

type AVCaptureOutput ¶

type AVCaptureOutput struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureoutput

func AVCaptureOutputFromID ¶

func AVCaptureOutputFromID(id objc.ID) *AVCaptureOutput

func (*AVCaptureOutput) ConnectionWithMediaType ¶

func (o *AVCaptureOutput) ConnectionWithMediaType(mediaType *foundation.NSString) *AVCaptureConnection

@method connectionWithMediaType: @abstract Returns the first connection in the connections array with an inputPort of the specified mediaType. @param mediaType An AVMediaType constant from AVMediaFormat.h, e.g. AVMediaTypeVideo. @discussion This convenience method returns the first AVCaptureConnection in the receiver's connections array that has an AVCaptureInputPort of the specified mediaType. If no connection with the specified mediaType is found, nil is returned.

func (*AVCaptureOutput) Connections ¶

@property connections @abstract The connections that describe the flow of media data to the receiver from AVCaptureInputs. @discussion The value of this property is an NSArray of AVCaptureConnection objects, each describing the mapping between the receiver and the AVCaptureInputPorts of one or more AVCaptureInputs.

func (*AVCaptureOutput) IsDeferredStartEnabled ¶

func (o *AVCaptureOutput) IsDeferredStartEnabled() bool

A `BOOL` value that indicates whether to defer starting this capture output. When this value is `true`, the session does not prepare the output's resources until some time after “AVCaptureSession/startRunning“ returns. You can start the visual parts of your user interface (e.g. preview) prior to other parts (e.g. photo/movie capture, metadata output, etc..) to improve startup performance. Set this value to `false` for outputs that your app needs for startup, and `true` for the ones it does not need to start immediately. For example, an “AVCaptureVideoDataOutput“ that you intend to use for displaying preview should set this value to `false`, so that the frames are available as soon as possible. By default, for apps that are linked on or after iOS 26, this property value is `true` for “AVCapturePhotoOutput“ and “AVCaptureFileOutput“ subclasses if supported, and `false` otherwise. When set to `true` for “AVCapturePhotoOutput“, if you want to support multiple capture requests before running deferred start, set “AVCapturePhotoOutput/responsiveCaptureEnabled“ to `true` on that output. If “deferredStartSupported“ is `false`, setting this property value to `true` results in the system throwing an `NSInvalidArgumentException`. - Note: Set this value before calling “AVCaptureSession/commitConfiguration“ as it requires a lengthy reconfiguration of the capture render pipeline.

func (*AVCaptureOutput) IsDeferredStartSupported ¶

func (o *AVCaptureOutput) IsDeferredStartSupported() bool

A `BOOL` value that indicates whether the output supports deferred start. You can only set the “deferredStartEnabled“ property value to `true` if the output supports deferred start.

func (*AVCaptureOutput) MetadataOutputRectOfInterestForRect ¶

func (o *AVCaptureOutput) MetadataOutputRectOfInterestForRect(rectInOutputCoordinates corefoundation.CGRect) corefoundation.CGRect

@method metadataOutputRectOfInterestForRect: @abstract Converts a rectangle in the receiver's coordinate space to a rectangle of interest in the coordinate space of an AVCaptureMetadataOutput whose capture device is providing input to the receiver. @param rectInOutputCoordinates A CGRect in the receiver's coordinates. @result A CGRect in the coordinate space of the metadata output whose capture device is providing input to the receiver. @discussion AVCaptureMetadataOutput rectOfInterest is expressed as a CGRect where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This convenience method converts a rectangle in the coordinate space of the receiver to a rectangle of interest in the coordinate space of an AVCaptureMetadataOutput whose AVCaptureDevice is providing input to the receiver. The conversion takes orientation, mirroring, and scaling into consideration. See -transformedMetadataObjectForMetadataObject:connection: for a full discussion of how orientation and mirroring are applied to sample buffers passing through the output.

func (*AVCaptureOutput) RectForMetadataOutputRectOfInterest ¶

func (o *AVCaptureOutput) RectForMetadataOutputRectOfInterest(rectInMetadataOutputCoordinates corefoundation.CGRect) corefoundation.CGRect

@method rectForMetadataOutputRectOfInterest: @abstract Converts a rectangle of interest in the coordinate space of an AVCaptureMetadataOutput whose capture device is providing input to the receiver to a rectangle in the receiver's coordinates. @param rectInMetadataOutputCoordinates A CGRect in the coordinate space of the metadata output whose capture device is providing input to the receiver. @result A CGRect in the receiver's coordinates. @discussion AVCaptureMetadataOutput rectOfInterest is expressed as a CGRect where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This convenience method converts a rectangle in the coordinate space of an AVCaptureMetadataOutput whose AVCaptureDevice is providing input to the coordinate space of the receiver. The conversion takes orientation, mirroring, and scaling into consideration. See -transformedMetadataObjectForMetadataObject:connection: for a full discussion of how orientation and mirroring are applied to sample buffers passing through the output.

func (*AVCaptureOutput) SetDeferredStartEnabled ¶

func (o *AVCaptureOutput) SetDeferredStartEnabled(deferredStartEnabled bool)

func (*AVCaptureOutput) TransformedMetadataObjectForMetadataObjectConnection ¶

func (o *AVCaptureOutput) TransformedMetadataObjectForMetadataObjectConnection(metadataObject *AVMetadataObject, connection *AVCaptureConnection) *AVMetadataObject

@method transformedMetadataObjectForMetadataObject:connection: @abstract Converts an AVMetadataObject's visual properties to the receiver's coordinates. @param metadataObject An AVMetadataObject originating from the same AVCaptureInput as the receiver. @param connection The receiver's connection whose AVCaptureInput matches that of the metadata object to be converted. @result An AVMetadataObject whose properties are in output coordinates. @discussion AVMetadataObject bounds may be expressed as a rect where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. Face metadata objects likewise express yaw and roll angles with respect to an unrotated picture. -transformedMetadataObjectForMetadataObject:connection: converts the visual properties in the coordinate space of the supplied AVMetadataObject to the coordinate space of the receiver. The conversion takes orientation, mirroring, and scaling into consideration. If the provided metadata object originates from an input source other than the preview layer's, nil will be returned. If an AVCaptureVideoDataOutput instance's connection's videoOrientation or videoMirrored properties are set to non-default values, the output applies the desired mirroring and orientation by physically rotating and or flipping sample buffers as they pass through it. AVCaptureStillImageOutput, on the other hand, does not physically rotate its buffers. It attaches an appropriate kCGImagePropertyOrientation number to captured still image buffers (see ImageIO/CGImageProperties.h) indicating how the image should be displayed on playback. Likewise, AVCaptureMovieFileOutput does not physically apply orientation/mirroring to its sample buffers -- it uses a QuickTime track matrix to indicate how the buffers should be rotated and/or flipped on playback. transformedMetadataObjectForMetadataObject:connection: alters the visual properties of the provided metadata object to match the physical rotation / mirroring of the sample buffers provided by the receiver through the indicated connection. I.e., for video data output, adjusted metadata object coordinates are rotated/mirrored. For still image and movie file output, they are not.

type AVCaptureOutputDataDroppedReason ¶

type AVCaptureOutputDataDroppedReason int64
const (
	AVCaptureOutputDataDroppedReasonNone          AVCaptureOutputDataDroppedReason = 0
	AVCaptureOutputDataDroppedReasonLateData      AVCaptureOutputDataDroppedReason = 1
	AVCaptureOutputDataDroppedReasonOutOfBuffers  AVCaptureOutputDataDroppedReason = 2
	AVCaptureOutputDataDroppedReasonDiscontinuity AVCaptureOutputDataDroppedReason = 3
)

func (AVCaptureOutputDataDroppedReason) String ¶

type AVCapturePhoto ¶

type AVCapturePhoto struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturephoto

func AVCapturePhotoFromID ¶

func AVCapturePhotoFromID(id objc.ID) *AVCapturePhoto

func (*AVCapturePhoto) CGImageRepresentation ¶

func (o *AVCapturePhoto) CGImageRepresentation() unsafe.Pointer

@method CGImageRepresentation @abstract Utility method that converts the AVCapturePhoto's primary photo to a CGImage. @result A CGImageRef, or nil if the conversion process fails. @discussion Each time you access this method, AVCapturePhoto generates a new CGImageRef. When backed by a compressed container (such as HEIC), the CGImageRepresentation is decoded lazily as needed. When backed by an uncompressed format such as BGRA, it is copied into a separate backing buffer whose lifetime is not tied to that of the AVCapturePhoto. For a 12 megapixel image, a BGRA CGImage represents ~48 megabytes per call. If you only intend to use the CGImage for on-screen rendering, use the previewCGImageRepresentation instead. Note that the physical rotation of the CGImageRef matches that of the main image. Exif orientation has not been applied. If you wish to apply rotation when working with UIImage, you can do so by querying the photo's metadata[kCGImagePropertyOrientation] value, and passing it as the orientation parameter to +[UIImage imageWithCGImage:scale:orientation:]. RAW images always return a CGImageRepresentation of nil. If you wish to make a CGImageRef from a RAW image, use CIRAWFilter in the CoreImage framework.

func (*AVCapturePhoto) ConstantColorCenterWeightedMeanConfidenceLevel ¶

func (o *AVCapturePhoto) ConstantColorCenterWeightedMeanConfidenceLevel() float32

@property constantColorCenterWeightedMeanConfidenceLevel @abstract Returns a score summarizing the overall confidence level of a constant color photo -- 1.0 means full confidence, 0.0 means zero confidence. @discussion Default is 0.0. In most use cases (document scanning for example), the central region of the photo is considered more important than the peripherals, therefore the confidence level of the central pixels are weighted more heavily than pixels on the edges of the photo. Use constantColorConfidenceMap for more use case specific analyses of the confidence level.

func (*AVCapturePhoto) ConstantColorConfidenceMap ¶

func (o *AVCapturePhoto) ConstantColorConfidenceMap() unsafe.Pointer

@property constantColorConfidenceMap @abstract Returns a pixel buffer with the same aspect ratio as the constant color photo, where each pixel value (unsigned 8-bit integer) indicates how fully the constant color effect has been achieved in the corresponding region of the constant color photo -- 255 means full confidence, 0 means zero confidence. @discussion NULL is returned for any non constant color photos.

func (*AVCapturePhoto) FileDataRepresentation ¶

func (o *AVCapturePhoto) FileDataRepresentation() *foundation.NSData

@method fileDataRepresentation @abstract Flattens the AVCapturePhoto to an NSData using the file container format (processedFileType or rawFileType) specified in the AVCapturePhotoSettings (e.g. JFIF, HEIF, DNG, DICOM). @result An NSData containing bits in the file container's format, or nil if the flattening process fails.

func (*AVCapturePhoto) IsConstantColorFallbackPhoto ¶

func (o *AVCapturePhoto) IsConstantColorFallbackPhoto() bool

@property constantColorFallbackPhoto @abstract Indicates whether this photo is a fallback photo for a constant color capture.

func (*AVCapturePhoto) PhotoCount ¶

func (o *AVCapturePhoto) PhotoCount() int

@property photoCount @abstract This photo's index (1-based) in the total expected photo count. @discussion The resolvedSettings.expectedPhotoCount property indicates the total number of images that will be returned for a given capture request. This property indicates this photo's index (1-based). When you receive a -captureOutput:didFinishProcessingPhoto:error: callback with a photo whose photoCount matches resolvedSettings.expectedPhotoCount, you know you've received the last one for the given capture request.

func (*AVCapturePhoto) PixelBuffer ¶

func (o *AVCapturePhoto) PixelBuffer() unsafe.Pointer

@property pixelBuffer @abstract For uncompressed or RAW captures, this property offers access to the pixel data. @discussion Uncompressed captures, such as '420f' or 'BGRA', Bayer RAW captures, such as 'bgg4', or Apple ProRAW captures, such as 'l64r', present pixel data as a CVPixelBuffer. See AVCapturePhotoOutput's -appleProRAWEnabled for a discussion on the differences between Bayer RAW and Apple ProRAW. This property is analogous to CMSampleBufferGetImageBuffer(). The pixel buffer contains only the minimal attachments required for correct display. Compressed captures, such as 'jpeg', return nil.

func (*AVCapturePhoto) ResolvedSettings ¶

func (o *AVCapturePhoto) ResolvedSettings() *AVCaptureResolvedPhotoSettings

@property resolvedSettings @abstract The AVCaptureResolvedPhotoSettings associated with all photo results for a given -[AVCapturePhotoOutput capturePhotoWithSettings:delegate:] request. @discussion Even in the event of an error, the resolved settings are always non nil.

func (*AVCapturePhoto) Timestamp ¶

func (o *AVCapturePhoto) Timestamp() coremedia.CMTime

@property timestamp @abstract The time at which this image was captured, synchronized to the synchronizationClock of the AVCaptureSession @discussion The timestamp property indicates the time the image was captured, and is analogous to CMSampleBufferGetPresentationTimeStamp(). If an error was provided in the -captureOutput:didFinishingProcessingPhoto:error: callback, timestamp returns kCMTimeInvalid.

type AVCapturePhotoCaptureDelegate ¶

type AVCapturePhotoCaptureDelegate interface {
}

AVCapturePhotoCaptureDelegate wraps the ObjC protocol AVCapturePhotoCaptureDelegate.

type AVCapturePhotoOutput ¶

type AVCapturePhotoOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturephotooutput

func AVCapturePhotoOutputFromID ¶

func AVCapturePhotoOutputFromID(id objc.ID) *AVCapturePhotoOutput

func AVCapturePhotoOutputNew ¶

func AVCapturePhotoOutputNew() *AVCapturePhotoOutput

func (*AVCapturePhotoOutput) AvailablePhotoCodecTypes ¶

func (o *AVCapturePhotoOutput) AvailablePhotoCodecTypes() *foundation.NSArray[*foundation.NSString]

@property availablePhotoCodecTypes @abstract An array of AVVideoCodecKey values that are currently supported by the receiver. @discussion If you wish to capture a photo in a compressed format, such as JPEG, you must ensure that the format you want is present in the receiver's availablePhotoCodecTypes array. If you've not yet added your receiver to an AVCaptureSession with a video source, no codec types are available. This property is key-value observable.

func (*AVCapturePhotoOutput) AvailablePhotoFileTypes ¶

func (o *AVCapturePhotoOutput) AvailablePhotoFileTypes() *foundation.NSArray[*foundation.NSString]

@property availablePhotoFileTypes @abstract An array of AVFileType values that are currently supported by the receiver. @discussion If you wish to capture a photo that is formatted for a particular file container, such as HEIF or DICOM, you must ensure that the fileType you desire is present in the receiver's availablePhotoFileTypes array. If you've not yet added your receiver to an AVCaptureSession with a video source, no file types are available. This property is key-value observable.

func (*AVCapturePhotoOutput) AvailablePhotoPixelFormatTypes ¶

func (o *AVCapturePhotoOutput) AvailablePhotoPixelFormatTypes() *foundation.NSArray[*foundation.NSNumber]

@property availablePhotoPixelFormatTypes @abstract An array of kCVPixelBufferPixelFormatTypeKey values that are currently supported by the receiver. @discussion If you wish to capture a photo in an uncompressed format, such as 420f, 420v, or BGRA, you must ensure that the format you want is present in the receiver's availablePhotoPixelFormatTypes array. If you've not yet added your receiver to an AVCaptureSession with a video source, no pixel format types are available. This property is key-value observable.

func (*AVCapturePhotoOutput) CapturePhotoWithSettingsDelegate ¶

func (o *AVCapturePhotoOutput) CapturePhotoWithSettingsDelegate(settings *AVCapturePhotoSettings, delegate AVCapturePhotoCaptureDelegate)

@method capturePhotoWithSettings:delegate: @abstract Method for initiating a photo capture request with progress monitoring through the supplied delegate. @param settings An AVCapturePhotoSettings object you have configured. May not be nil. @param delegate An object conforming to the AVCapturePhotoCaptureDelegate protocol. This object's delegate methods are called back as the photo advances from capture to processing to finished delivery. May not be nil. @discussion This method initiates a photo capture. The receiver copies your provided settings to prevent unintentional mutation. It is illegal to re-use settings. The receiver throws an NSInvalidArgumentException if your settings.uniqueID matches that of any previously used settings. This method is used to initiate all flavors of photo capture: single photo, RAW capture with or without a processed image (such as a JPEG), bracketed capture, and Live Photo. Clients need not wait for a capture photo request to complete before issuing another request. This is true for single photo captures as well as Live Photos, where movie complements of adjacent photo captures are allowed to overlap. This method validates your settings and enforces the following rules in order to ensure deterministic behavior. If any of these rules are violated, a NSInvalidArgumentException is thrown. RAW rules: See +isBayerRAWPixelFormat: and +isAppleProRAWPixelFormat: on the difference between Bayer RAW and Apple ProRAW pixel formats. Common RAW rules: - If rawPhotoPixelFormatType is non-zero, it must be present in the receiver's -availableRawPhotoPixelFormatTypes array. - If rawPhotoPixelFormatType is non-zero, your delegate must respond to -captureOutput:didFinishProcessingRawPhotoSampleBuffer:previewPhotoSampleBuffer:resolvedSettings:bracketSettings:error:. - If rawPhotoPixelFormatType is non-zero, highResolutionPhotoEnabled may be YES or NO, but the setting only applies to the processed image, if you've specified one. - If rawPhotoPixelFormatType is non-zero, constantColorEnabled must be set to NO. - If rawFileType is specified, it must be present in -availableRawPhotoFileTypes and must support the rawPhotoPixelFormatType specified using -supportedRawPhotoPixelFormatTypesForFileType:. Bayer RAW rules (isBayerRAWPixelFormat: returns yes for rawPhotoPixelFormatType): - photoQualityPrioritization must be set to AVCapturePhotoQualityPrioritizationSpeed (deprecated autoStillImageStabilizationEnabled must be set to NO). - the videoZoomFactor of the source device and the videoScaleAndCropFactor of the photo output's video connection must both be 1.0. Ensure no zoom is applied before requesting a RAW capture, and don't change the zoom during RAW capture. Apple ProRAW rules (isAppleProRAWPixelFormat: returns yes for rawPhotoPixelFormatType): - livePhotoMovieFileURL must be nil in AVCapturePhotoSettings settings - autoContentAwareDistortionCorrectionEnabled will automatically be disabled in AVCapturePhotoSettings - autoRedEyeReductionEnabled will automatically be disabled in AVCapturePhotoSettings - portraitEffectsMatteDeliveryEnabled will automatically be disabled in AVCapturePhotoSettings - enabledSemanticSegmentationMatteTypes will automatically be cleared in AVCapturePhotoSettings Processed Format rules: - If format is non-nil, a kCVPixelBufferPixelFormatTypeKey or AVVideoCodecKey must be present. You cannot specify both. - If format has a kCVPixelBufferPixelFormatTypeKey, its value must be present in the receiver's -availablePhotoPixelFormatTypes array. - If format has an AVVideoCodecKey, its value must be present in the receiver's -availablePhotoCodecTypes array. - If format is non-nil, your delegate must respond to -captureOutput:didFinishProcessingPhotoSampleBuffer:previewPhotoSampleBuffer:resolvedSettings:bracketSettings:error:. - If processedFileType is specified, it must be present in -availablePhotoFileTypes and must support the format's specified kCVPixelBufferPixelFormatTypeKey (using -supportedPhotoPixelFormatTypesForFileType:) or AVVideoCodecKey (using -supportedPhotoCodecTypesForFileType:). - The photoQualityPrioritization you specify may not be a greater number than the photo output's maxPhotoQualityPrioritization. You must set your AVCapturePhotoOutput maxPhotoQualityPrioritization up front. Flash rules: - The specified flashMode must be present in the receiver's -supportedFlashModes array. Live Photo rules: - The receiver's livePhotoCaptureEnabled must be YES if settings.livePhotoMovieURL is non-nil. - If settings.livePhotoMovieURL is non-nil, the receiver's livePhotoCaptureSuspended property must be set to NO. - If settings.livePhotoMovieURL is non-nil, it must be a file URL that's accessible to your app's sandbox. - If settings.livePhotoMovieURL is non-nil, your delegate must respond to -captureOutput:didFinishProcessingLivePhotoToMovieFileAtURL:duration:photoDisplayTime:resolvedSettings:error:. Bracketed capture rules: - bracketedSettings.count must be <= the receiver's maxBracketedCapturePhotoCount property. - For manual exposure brackets, ISO value must be within the source device activeFormat's minISO and maxISO values. - For manual exposure brackets, exposureDuration value must be within the source device activeFormat's minExposureDuration and maxExposureDuration values. - For auto exposure brackets, exposureTargetBias value must be within the source device's minExposureTargetBias and maxExposureTargetBias values. Deferred Photo Delivery rules: - If the receiver's autoDeferredPhotoDeliveryEnabled is YES, your delegate must respond to -captureOutput:didFinishCapturingDeferredPhotoProxy:error:. - The maxPhotoDimensions setting for 24MP (5712, 4284), when supported, is only serviced as 24MP via deferred photo delivery. Color space rules: - Photo capture is not supported when AVCaptureDevice has selected AVCaptureColorSpace_AppleLog or AVCaptureColorSpace_AppleLog2 as color space.

func (*AVCapturePhotoOutput) CaptureReadiness ¶

@property captureReadiness @abstract A value specifying whether the photo output is ready to respond to new capture requests in a timely manner. @discussion This property can be key-value observed to enable and disable shutter button UI depending on whether the output is ready to capture, which is especially important when the responsiveCaptureEnabled property is YES. When interacting with AVCapturePhotoOutput on a background queue AVCapturePhotoOutputReadinessCoordinator should instead be used to observe readiness changes and perform UI updates. Capturing only when the output is ready limits the number of requests inflight to minimize shutter lag while maintaining the fastest shot to shot time. When the property returns a value other than Ready the output is not ready to capture and the shutter button should be disabled to prevent the user from initiating new requests. The output continues to accept requests when the captureReadiness property returns a value other than Ready, but the request may not be serviced for a longer period. The visual presentation of the shutter button can be customized based on the readiness value. When the user rapidly taps the shutter button the property may transition to NotReadyMomentarily for a brief period. Although the shutter button should be disabled during this period it is short lived enough that dimming or changing the appearance of the shutter is not recommended as it would be visually distracting to the user. Longer running capture types like flash or captures with AVCapturePhotoQualityPrioritizationQuality may prevent the output from capturing for an extended period, indicated by NotReadyWaitingForCapture or NotReadyWaitingForProcessing, which is appropriate to show by dimming or disabling the shutter button. For NotReadyWaitingForProcessing it is also appropriate to show a spinner or other indication that the shutter is busy.

func (*AVCapturePhotoOutput) Init ¶

func (*AVCapturePhotoOutput) IsConstantColorEnabled ¶

func (o *AVCapturePhotoOutput) IsConstantColorEnabled() bool

@property constantColorEnabled @abstract A BOOL value specifying whether the photo render pipeline is set up to perform constant color captures. @discussion Default is NO. Set to YES to enable support for taking constant color photos. This property may only be set to YES if constantColorSupported is YES. Enabling constant color requires a lengthy reconfiguration of the capture render pipeline, so if you intend to capture constant color photos, you should set this property to YES before calling -[AVCaptureSession startRunning] or within -[AVCaptureSession beginConfiguration] and -[AVCaptureSession commitConfiguration] while running.

func (*AVCapturePhotoOutput) IsConstantColorSupported ¶

func (o *AVCapturePhotoOutput) IsConstantColorSupported() bool

@property constantColorSupported @abstract A BOOL value specifying whether constant color capture is supported. @discussion An object's color in a photograph is affected by the light sources illuminating the scene, so the color of the same object photographed in warm light might look markedly different than in colder light. In some use cases, such ambient light induced color variation is undesirable, and the user may prefer an estimate of what these materials would look like under a standard light such as daylight (D65), regardless of the lighting conditions at the time the photograph was taken. Some devices are capable of producing such constant color photos. Constant color captures require the flash to be fired and may require pre-flash sequence to determine the correct focus and exposure, therefore it might take several seconds to acquire a constant color photo. Due to this flash requirement, a constant color capture can only be taken with AVCaptureFlashModeAuto or AVCaptureFlashModeOn as the flash mode, otherwise an exception is thrown. Constant color can only be achieved when the flash has a discernible effect on the scene so it may not perform well in bright conditions such as direct sunlight. Use the constantColorConfidenceMap property to examine the confidence level, and therefore the usefulness, of each region of a constant color photo. Constant color should not be used in conjunction with locked or manual white balance. This property returns YES if the session's current configuration allows photos to be captured with constant color. When switching cameras or formats this property may change. When this property changes from YES to NO, constantColorEnabled also reverts to NO. If you've previously opted in for constant color and then change configurations, you may need to set constantColorEnabled = YES again. This property is key-value observable.

func (*AVCapturePhotoOutput) IsFastCapturePrioritizationEnabled ¶

func (o *AVCapturePhotoOutput) IsFastCapturePrioritizationEnabled() bool

@property fastCapturePrioritizationEnabled @abstract Specifies whether fast capture prioritization is enabled. @discussion This property defaults to NO. This property may only be set to YES if fastCapturePrioritizationSupported is YES, otherwise an NSInvalidArgumentException is thrown. By setting this property to YES, the photo output prepares itself to automatically reduce capture quality from the selected AVCapturePhotoQualityPrioritization when needed to keep up with rapid capture requests. In many cases the slightly reduced quality is preferable to missing the moment entirely. If you intend to use fast capture prioritization, you should set this property to YES before calling -[AVCaptureSession startRunning] or within -[AVCaptureSession beginConfiguration] and -[AVCaptureSession commitConfiguration] while running.

func (*AVCapturePhotoOutput) IsFastCapturePrioritizationSupported ¶

func (o *AVCapturePhotoOutput) IsFastCapturePrioritizationSupported() bool

@property fastCapturePrioritizationSupported @abstract Specifies whether fast capture prioritization is supported. @discussion Fast capture prioritization allows capture quality to be automatically reduced from the selected AVCapturePhotoQualityPrioritization to ensure the photo output can keep up when captures are requested in rapid succession. Fast capture prioritization is only supported for certain AVCaptureSession sessionPresets and AVCaptureDevice activeFormats and only when responsiveCaptureEnabled is YES. When switching cameras or formats this property may change. When this property changes from YES to NO, fastCapturePrioritizationEnabled also reverts to NO. If you've previously opted in for fast capture prioritization and then change configurations, you may need to set fastCapturePrioritizationEnabled = YES again.

func (*AVCapturePhotoOutput) IsHighResolutionCaptureEnabled ¶

func (o *AVCapturePhotoOutput) IsHighResolutionCaptureEnabled() bool

@property highResolutionCaptureEnabled @abstract Indicates whether the photo render pipeline should be configured to deliver high resolution still images. @discussion Some AVCaptureDeviceFormats support outputting higher resolution stills than their streaming resolution (See AVCaptureDeviceFormat.highResolutionStillImageDimensions). Under some conditions, AVCaptureSession needs to set up the photo render pipeline differently to support high resolution still image capture. If you intend to take high resolution still images at all, you should set this property to YES before calling -[AVCaptureSession startRunning]. Once you've opted in for high resolution capture, you are free to issue photo capture requests with or without highResolutionCaptureEnabled in the AVCapturePhotoSettings. If you have not set this property to YES and call capturePhotoWithSettings:delegate: with settings.highResolutionCaptureEnabled set to YES, an NSInvalidArgumentException will be thrown. Deprecated: Use maxPhotoDimensions instead.

func (*AVCapturePhotoOutput) IsResponsiveCaptureEnabled ¶

func (o *AVCapturePhotoOutput) IsResponsiveCaptureEnabled() bool

@property responsiveCaptureEnabled @abstract A BOOL value specifying whether the photo output is set up to support responsive capture. @discussion This property may only be set to YES if responsiveCaptureSupported is YES, otherwise an NSInvalidArgumentException is thrown. When responsiveCaptureEnabled is YES the captureReadiness property should be used to determine whether new capture requests can be serviced in a reasonable time and whether the shutter control should be available to the user. Responsive capture adds buffering between the capture and photo processing stages which allows a new capture to start before processing has completed for the previous capture, so be prepared to handle -captureOutput:willBeginCaptureForResolvedSettings: being called before the -captureOutput:didFinishProcessingPhoto: for the prior requests. Processed photos continue to be delivered in the order they were captured. To minimize camera shake from the user's tapping gesture it is recommended that -capturePhotoWithSettings:delegate: be called as early as possible when handling the touch down event. Enabling responsive capture allows the fast capture prioritization feature to be used, which further increases capture rates and reduces preview and recording disruptions. See the fastCapturePrioritizationEnabled property. When requesting uncompressed output using kCVPixelBufferPixelFormatTypeKey in AVCapturePhotoSetting.format the AVCapturePhoto's pixelBuffer is allocated from a pool with enough capacity for that request only, and overlap between capture and processing is disabled. The client must release the AVCapturePhoto and references to the pixelBuffer before capturing again and the pixelBuffer's IOSurface must also no longer be in use. Changing this property requires a lengthy reconfiguration of the capture render pipeline, so you should set this property to YES before calling -[AVCaptureSession startRunning] or within -[AVCaptureSession beginConfiguration] and -[AVCaptureSession commitConfiguration] while running.

func (*AVCapturePhotoOutput) IsResponsiveCaptureSupported ¶

func (o *AVCapturePhotoOutput) IsResponsiveCaptureSupported() bool

@property responsiveCaptureSupported @abstract A BOOL value specifying whether responsive capture is supported. @discussion Enabling responsive capture increases peak and sustained capture rates, and reduces shutter lag at the cost of additional memory usage by the photo output. This property returns YES if the session's current configuration allows responsive capture. When switching cameras or formats, enabling depth data delivery, or enabling zero shutter lag this property may change. Responsive capture is only supported when zero shutter lag is enabled. When this property changes from YES to NO, responsiveCaptureEnabled also reverts to NO. This property is key-value observable.

func (*AVCapturePhotoOutput) IsShutterSoundSuppressionSupported ¶

func (o *AVCapturePhotoOutput) IsShutterSoundSuppressionSupported() bool

@property shutterSoundSuppressionSupported @abstract Specifies whether suppressing the shutter sound is supported. @discussion On iOS, this property returns NO in jurisdictions where shutter sound production cannot be disabled. On all other platforms, it always returns NO.

func (*AVCapturePhotoOutput) IsZeroShutterLagEnabled ¶

func (o *AVCapturePhotoOutput) IsZeroShutterLagEnabled() bool

@property zeroShutterLagEnabled @abstract A BOOL value specifying whether the output is set up to support zero shutter lag. @discussion This property may only be set to YES if zeroShutterLagSupported is YES, otherwise an NSInvalidArgumentException is thrown. For apps linked on or after iOS 17 zero shutter lag is automatically enabled when supported. Enabling zero shutter lag reduces or eliminates shutter lag when using AVCapturePhotoQualityPrioritizationBalanced or Quality at the cost of additional memory usage by the photo output. The timestamp of the AVCapturePhoto may be slightly earlier than when -capturePhotoWithSettings:delegate: was called. To minimize camera shake from the user's tapping gesture it is recommended that -capturePhotoWithSettings:delegate: be called as early as possible when handling the touch down event. Zero shutter lag isn't available when using manual exposure or bracketed capture. Changing this property requires a lengthy reconfiguration of the capture render pipeline, so you should set this property to YES before calling -[AVCaptureSession startRunning] or within -[AVCaptureSession beginConfiguration] and -[AVCaptureSession commitConfiguration] while running.

func (*AVCapturePhotoOutput) IsZeroShutterLagSupported ¶

func (o *AVCapturePhotoOutput) IsZeroShutterLagSupported() bool

@property zeroShutterLagSupported @abstract A BOOL value specifying whether zero shutter lag is supported. @discussion This property returns YES if the session's current configuration allows zero shutter lag. When switching cameras or formats, setting depthDataDeliveryEnabled, or setting virtualDeviceConstituentPhotoDeliveryEnabled this property may change. When this property changes from YES to NO, zeroShutterLagEnabled also reverts to NO. This property is key-value observable.

func (*AVCapturePhotoOutput) MaxPhotoDimensions ¶

func (o *AVCapturePhotoOutput) MaxPhotoDimensions() coremedia.CMVideoDimensions

@property maxPhotoDimensions @abstract Indicates the maximum resolution of the requested photo. @discussion Set this property to enable requesting of images up to as large as the specified dimensions. Images returned by AVCapturePhotoOutput may be smaller than these dimensions but will never be larger. Once set, images can be requested with any valid maximum photo dimensions by setting AVCapturePhotoSettings.maxPhotoDimensions on a per photo basis. The dimensions set must match one of the dimensions returned by AVCaptureDeviceFormat.supportedMaxPhotoDimensions for the current active format. Changing this property may trigger a lengthy reconfiguration of the capture render pipeline so it is recommended that this is set before calling -[AVCaptureSession startRunning]. Note: When supported, the 24MP setting (5712, 4284) is only serviced as 24MP when opted-in to autoDeferredPhotoDeliveryEnabled.

func (*AVCapturePhotoOutput) MaxPhotoQualityPrioritization ¶

func (o *AVCapturePhotoOutput) MaxPhotoQualityPrioritization() AVCapturePhotoQualityPrioritization

@property maxPhotoQualityPrioritization @abstract Indicates the highest quality the receiver should be prepared to output on a capture-by-capture basis. @discussion Default value is AVCapturePhotoQualityPrioritizationBalanced when attached to an AVCaptureSession, and AVCapturePhotoQualityPrioritizationSpeed when attached to an AVCaptureMultiCamSession. The AVCapturePhotoOutput is capable of applying a variety of techniques to improve photo quality (reduce noise, preserve detail in low light, freeze motion, etc). Some techniques improve image quality at the expense of speed (shot-to-shot time). Before starting your session, you may set this property to indicate the highest quality prioritization you intend to request when calling -capturePhotoWithSettings:delegate:. When configuring an AVCapturePhotoSettings object, you may not exceed this quality prioritization level, but you may select a lower (speedier) prioritization level. Changing the maxPhotoQualityPrioritization while the session is running can result in a lengthy rebuild of the session in which video preview is disrupted. Setting the maxPhotoQualityPrioritization to .quality will turn on optical image stabilization if the -isHighPhotoQualitySupported of the source device's -activeFormat is true.

func (*AVCapturePhotoOutput) PreservesLivePhotoCaptureSuspendedOnSessionStop ¶

func (o *AVCapturePhotoOutput) PreservesLivePhotoCaptureSuspendedOnSessionStop() bool

@property preservesLivePhotoCaptureSuspendedOnSessionStop @abstract By default, Live Photo capture is resumed when the session stops. This property allows clients to opt out of this and preserve the value of livePhotoCaptureSuspended. @discussion Defaults to NO.

func (*AVCapturePhotoOutput) SetConstantColorEnabled ¶

func (o *AVCapturePhotoOutput) SetConstantColorEnabled(constantColorEnabled bool)

func (*AVCapturePhotoOutput) SetFastCapturePrioritizationEnabled ¶

func (o *AVCapturePhotoOutput) SetFastCapturePrioritizationEnabled(fastCapturePrioritizationEnabled bool)

func (*AVCapturePhotoOutput) SetFastCapturePrioritizationSupported ¶

func (o *AVCapturePhotoOutput) SetFastCapturePrioritizationSupported(fastCapturePrioritizationSupported bool)

func (*AVCapturePhotoOutput) SetHighResolutionCaptureEnabled deprecated

func (o *AVCapturePhotoOutput) SetHighResolutionCaptureEnabled(highResolutionCaptureEnabled bool)

Deprecated: Use maxPhotoDimensions instead.

func (*AVCapturePhotoOutput) SetMaxPhotoDimensions ¶

func (o *AVCapturePhotoOutput) SetMaxPhotoDimensions(maxPhotoDimensions coremedia.CMVideoDimensions)

func (*AVCapturePhotoOutput) SetMaxPhotoQualityPrioritization ¶

func (o *AVCapturePhotoOutput) SetMaxPhotoQualityPrioritization(maxPhotoQualityPrioritization AVCapturePhotoQualityPrioritization)

func (*AVCapturePhotoOutput) SetPreservesLivePhotoCaptureSuspendedOnSessionStop ¶

func (o *AVCapturePhotoOutput) SetPreservesLivePhotoCaptureSuspendedOnSessionStop(preservesLivePhotoCaptureSuspendedOnSessionStop bool)

func (*AVCapturePhotoOutput) SetResponsiveCaptureEnabled ¶

func (o *AVCapturePhotoOutput) SetResponsiveCaptureEnabled(responsiveCaptureEnabled bool)

func (*AVCapturePhotoOutput) SetZeroShutterLagEnabled ¶

func (o *AVCapturePhotoOutput) SetZeroShutterLagEnabled(zeroShutterLagEnabled bool)

func (*AVCapturePhotoOutput) SupportedFlashModes ¶

func (o *AVCapturePhotoOutput) SupportedFlashModes() *foundation.NSArray[*foundation.NSNumber]

@property supportedFlashModes @abstract An array of AVCaptureFlashMode constants for the current capture session configuration. @discussion This property supersedes AVCaptureDevice's isFlashModeSupported: It returns an array of AVCaptureFlashMode constants. To test whether a particular flash mode is supported, use NSArray's containsObject API: [photoOutput.supportedFlashModes containsObject:@(AVCaptureFlashModeAuto)]. This property is key-value observable.

func (*AVCapturePhotoOutput) SupportedPhotoCodecTypesForFileType ¶

func (o *AVCapturePhotoOutput) SupportedPhotoCodecTypesForFileType(fileType *foundation.NSString) *foundation.NSArray[*foundation.NSString]

@method supportedPhotoCodecTypesForFileType: @abstract An array of AVVideoCodecKey values that are currently supported by the receiver for a particular file container. @param fileType The AVFileType container type intended for storage of a photo. @result An array of AVVideoCodecKey values supported by the receiver for the file type in question. @discussion If you wish to capture a photo for storage in a particular file container, such as HEIF, you must ensure that the photo codec type you request is valid for that file type. If no codec types are supported for a given fileType, an empty array is returned. If you've not yet added your receiver to an AVCaptureSession with a video source, no codec types are supported.

func (*AVCapturePhotoOutput) SupportedPhotoPixelFormatTypesForFileType ¶

func (o *AVCapturePhotoOutput) SupportedPhotoPixelFormatTypesForFileType(fileType *foundation.NSString) *foundation.NSArray[*foundation.NSNumber]

@method supportedPhotoPixelFormatTypesForFileType: @abstract An array of pixel format type values that are currently supported by the receiver for a particular file container. @param fileType The AVFileType container type intended for storage of a photo. @result An array of CVPixelBufferPixelFormatTypeKey values supported by the receiver for the file type in question. @discussion If you wish to capture a photo for storage in a particular file container, such as TIFF, you must ensure that the photo pixel format type you request is valid for that file type. If no pixel format types are supported for a given fileType, an empty array is returned. If you've not yet added your receiver to an AVCaptureSession with a video source, no pixel format types are supported.

type AVCapturePhotoOutputCaptureReadiness ¶

type AVCapturePhotoOutputCaptureReadiness int64
const (
	AVCapturePhotoOutputCaptureReadinessSessionNotRunning            AVCapturePhotoOutputCaptureReadiness = 0
	AVCapturePhotoOutputCaptureReadinessReady                        AVCapturePhotoOutputCaptureReadiness = 1
	AVCapturePhotoOutputCaptureReadinessNotReadyMomentarily          AVCapturePhotoOutputCaptureReadiness = 2
	AVCapturePhotoOutputCaptureReadinessNotReadyWaitingForCapture    AVCapturePhotoOutputCaptureReadiness = 3
	AVCapturePhotoOutputCaptureReadinessNotReadyWaitingForProcessing AVCapturePhotoOutputCaptureReadiness = 4
)

func (AVCapturePhotoOutputCaptureReadiness) String ¶

type AVCapturePhotoOutputReadinessCoordinator ¶

type AVCapturePhotoOutputReadinessCoordinator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturephotooutputreadinesscoordinator

func AVCapturePhotoOutputReadinessCoordinatorFromID ¶

func AVCapturePhotoOutputReadinessCoordinatorFromID(id objc.ID) *AVCapturePhotoOutputReadinessCoordinator

func (*AVCapturePhotoOutputReadinessCoordinator) CaptureReadiness ¶

@property captureReadiness @abstract A value specifying whether the coordinator's photo output is ready to respond to new capture requests in a timely manner. @discussion The value incorporates the photo output's captureReadiness and any requests registered using -startTrackingCaptureRequestUsingPhotoSettings:. The value is updated before calling the -readinessCoordinator:captureReadinessDidChange: callback. See AVCapturePhotoOutput's captureReadiness documentation for a discussion of how to update shutter availability and appearance based on the captureReadiness value. This property is key-value observable and all change notifications are delivered on the main queue, allowing UI updates to be done directly in the callback.

func (*AVCapturePhotoOutputReadinessCoordinator) Delegate ¶

@property delegate @abstract The receiver's delegate, called on the main queue. @discussion The value of this property is an object conforming to the AVCapturePhotoOutputReadinessCoordinatorDelegate protocol that will receive a callback when the captureReadiness property changes. Callbacks are delivered on the main queue, allowing UI updates to be done directly in the callback. A callback with the initial value of captureReadiness is delivered when delegate is set.

func (*AVCapturePhotoOutputReadinessCoordinator) InitWithPhotoOutput ¶

func (*AVCapturePhotoOutputReadinessCoordinator) SetDelegate ¶

func (*AVCapturePhotoOutputReadinessCoordinator) StartTrackingCaptureRequestUsingPhotoSettings ¶

func (o *AVCapturePhotoOutputReadinessCoordinator) StartTrackingCaptureRequestUsingPhotoSettings(settings *AVCapturePhotoSettings)

@method startTrackingCaptureRequestUsingPhotoSettings: @abstract Track the capture request represented by the specified photo settings until it is enqueued to the photo output and update captureReadiness to include this request. @param settings The AVCapturePhotoSettings which will be passed to -[AVCapturePhotoOutput capturePhotoWithSettings:delegate] for this capture request. @discussion The captureReadiness property is updated to include the tracked request until the the photo output receives a settings object with the same or a newer uniqueID. It is recommended that the same photo settings be passed to -[AVCapturePhotoOutput capturePhotoWithSettings:delegate] to ensure the captureReadiness value is consistent once the capture begins. When called on the main queue the delegate callback is invoked synchronously before returning to ensure shutter availability is updated immediately and prevent queued touch events from initiating unwanted captures. The -startTrackingCaptureRequestUsingPhotoSettings: method can be called while in the SessionNotRunning state to allow the shutter button to be interactive while the session is being started on a background queue. An NSInvalidArgumentException is thrown if the photo settings are invalid.

func (*AVCapturePhotoOutputReadinessCoordinator) StopTrackingCaptureRequestUsingPhotoSettingsUniqueID ¶

func (o *AVCapturePhotoOutputReadinessCoordinator) StopTrackingCaptureRequestUsingPhotoSettingsUniqueID(settingsUniqueID int64)

@method stopTrackingCaptureRequestUsingPhotoSettingsUniqueID: @abstract Stop tracking the capture request represented by the specified photo settings uniqueID and update captureReadiness to no longer include this request. @param settingsUniqueID The AVCapturePhotoSettings.uniqueID of the settings passed to -startTrackingCaptureRequestUsingPhotoSettings:. @discussion Tracking automatically stops when -[AVCapturePhotoOutput capturePhotoWithSettings:delegate] is called with a photo settings objects with the same or a newer uniqueID, but in cases where an error or other condition prevents calling -capturePhotoWithSettings:delegate tracking should be explicitly stopped to ensure the captureReadiness value is up to date. When called on the main queue the delegate callback is invoked synchronously before returning to ensure shutter availability is updated immediately.

type AVCapturePhotoOutputReadinessCoordinatorDelegate ¶

type AVCapturePhotoOutputReadinessCoordinatorDelegate interface {
}

AVCapturePhotoOutputReadinessCoordinatorDelegate wraps the ObjC protocol AVCapturePhotoOutputReadinessCoordinatorDelegate.

type AVCapturePhotoQualityPrioritization ¶

type AVCapturePhotoQualityPrioritization int64
const (
	AVCapturePhotoQualityPrioritizationSpeed    AVCapturePhotoQualityPrioritization = 1
	AVCapturePhotoQualityPrioritizationBalanced AVCapturePhotoQualityPrioritization = 2
	AVCapturePhotoQualityPrioritizationQuality  AVCapturePhotoQualityPrioritization = 3
)

func (AVCapturePhotoQualityPrioritization) String ¶

type AVCapturePhotoSettings ¶

type AVCapturePhotoSettings struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturephotosettings

func AVCapturePhotoSettingsFromID ¶

func AVCapturePhotoSettingsFromID(id objc.ID) *AVCapturePhotoSettings

func AVCapturePhotoSettingsPhotoSettings ¶

func AVCapturePhotoSettingsPhotoSettings() *AVCapturePhotoSettings

@method photoSettings @abstract Creates a default instance of AVCapturePhotoSettings. @result An instance of AVCapturePhotoSettings. @discussion A default AVCapturePhotoSettings object has a format of AVVideoCodecTypeJPEG, a fileType of AVFileTypeJPEG, and photoQualityPrioritization set to AVCapturePhotoQualityPrioritizationBalanced.

func AVCapturePhotoSettingsPhotoSettingsFromPhotoSettings ¶

func AVCapturePhotoSettingsPhotoSettingsFromPhotoSettings(photoSettings *AVCapturePhotoSettings) *AVCapturePhotoSettings

@method photoSettingsFromPhotoSettings: @abstract Creates an instance of AVCapturePhotoSettings with a new uniqueID from an existing instance of AVCapturePhotoSettings. @param photoSettings An existing AVCapturePhotoSettings instance. @result An new instance of AVCapturePhotoSettings with new uniqueID. @discussion Use this factory method to create a clone of an existing photo settings instance, but with a new uniqueID that can safely be passed to AVCapturePhotoOutput -capturePhotoWithSettings:delegate:.

func AVCapturePhotoSettingsPhotoSettingsWithFormat ¶

func AVCapturePhotoSettingsPhotoSettingsWithFormat(format *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVCapturePhotoSettings

@method photoSettingsWithFormat: @abstract Creates an instance of AVCapturePhotoSettings with a user-specified output format. @param format A dictionary of Core Video pixel buffer attributes or AVVideoSettings, analogous to AVCaptureStillImageOutput's outputSettings property. @result An instance of AVCapturePhotoSettings. @discussion If you wish an uncompressed format, your dictionary must contain kCVPixelBufferPixelFormatTypeKey, and the format specified must be present in AVCapturePhotoOutput's -availablePhotoPixelFormatTypes array. kCVPixelBufferPixelFormatTypeKey is the only supported key when expressing uncompressed output. If you wish a compressed format, your dictionary must contain AVVideoCodecKey and the codec specified must be present in AVCapturePhotoOutput's -availablePhotoCodecTypes array. If you are specifying a compressed format, the AVVideoCompressionPropertiesKey is also supported, with a payload dictionary containing a single AVVideoQualityKey. Passing a nil format dictionary is analogous to calling +photoSettings.

func (*AVCapturePhotoSettings) FlashMode ¶

@property flashMode @abstract Specifies whether the flash should be on, off, or chosen automatically by AVCapturePhotoOutput. @discussion flashMode takes the place of the deprecated AVCaptureDevice -flashMode API. Setting AVCaptureDevice.flashMode has no effect on AVCapturePhotoOutput, which only pays attention to the flashMode specified in your AVCapturePhotoSettings. The default value is AVCaptureFlashModeOff. Flash modes are defined in AVCaptureDevice.h. If you specify a flashMode of AVCaptureFlashModeOn, it wins over autoStillImageStabilizationEnabled=YES. When the device becomes very hot, the flash becomes temporarily unavailable until the device cools down (see AVCaptureDevice's -flashAvailable). While the flash is unavailable, AVCapturePhotoOutput's -supportedFlashModes property still reports AVCaptureFlashModeOn and AVCaptureFlashModeAuto as being available, thus allowing you to specify a flashMode of AVCaptureModeOn. You should always check the AVCaptureResolvedPhotoSettings provided to you in the AVCapturePhotoCaptureDelegate callbacks, as the resolved flashEnabled property will tell you definitively if the flash is being used.

func (*AVCapturePhotoSettings) Format ¶

@property format @abstract A dictionary of Core Video pixel buffer attributes or AVVideoSettings, analogous to AVCaptureStillImageOutput's outputSettings property. @discussion The format dictionary you passed to one of the creation methods. May be nil if you've specified RAW-only capture.

func (*AVCapturePhotoSettings) IsConstantColorEnabled ¶

func (o *AVCapturePhotoSettings) IsConstantColorEnabled() bool

@property constantColorEnabled @abstract Specifies whether the photo will be captured with constant color. @discussion Default is NO. Set to YES if you wish to capture a constant color photo. Throws an exception if -[AVCapturePhotoOutput constantColorEnabled] is not set to YES.

func (*AVCapturePhotoSettings) IsConstantColorFallbackPhotoDeliveryEnabled ¶

func (o *AVCapturePhotoSettings) IsConstantColorFallbackPhotoDeliveryEnabled() bool

@property constantColorFallbackPhotoDeliveryEnabled @abstract Specifies whether a fallback photo is delivered when taking a constant color capture. @discussion Default is NO. Set to YES if you wish to receive a fallback photo that can be used in case the main constant color photo's confidence level is too low for your use case.

func (*AVCapturePhotoSettings) IsHighResolutionPhotoEnabled ¶

func (o *AVCapturePhotoSettings) IsHighResolutionPhotoEnabled() bool

@property highResolutionPhotoEnabled @abstract Specifies whether photos should be captured at the highest resolution supported by the source AVCaptureDevice's activeFormat. @discussion Default is NO. By default, AVCapturePhotoOutput emits images with the same dimensions as its source AVCaptureDevice's activeFormat.formatDescription. However, if you set this property to YES, the AVCapturePhotoOutput emits images at its source AVCaptureDevice's activeFormat.highResolutionStillImageDimensions. Note that if you enable video stabilization (see AVCaptureConnection's preferredVideoStabilizationMode) for any output, the high resolution photos emitted by AVCapturePhotoOutput may be smaller by 10 or more percent. You may inspect your AVCaptureResolvedPhotoSettings in the delegate callbacks to discover the exact dimensions of the capture photo(s). Starting in iOS 14.5 if you disable geometric distortion correction, the high resolution photo emitted by AVCapturePhotoOutput may be is smaller depending on the format. Deprecated: Use maxPhotoDimensions instead.

func (*AVCapturePhotoSettings) IsShutterSoundSuppressionEnabled ¶

func (o *AVCapturePhotoSettings) IsShutterSoundSuppressionEnabled() bool

@property shutterSoundSuppressionEnabled @abstract Specifies whether the built-in shutter sound should be suppressed when capturing a photo with these settings. @discussion Default is NO. Set to YES if you wish to suppress AVCapturePhotoOutput's built-in shutter sound for this request. AVCapturePhotoOutput throws an NSInvalidArgumentException in `-capturePhotoWithSettings:` if its `shutterSoundSuppressionSupported` property returns NO.

func (*AVCapturePhotoSettings) MaxPhotoDimensions ¶

func (o *AVCapturePhotoSettings) MaxPhotoDimensions() coremedia.CMVideoDimensions

@property maxPhotoDimensions @abstract Indicates the maximum resolution photo that will be captured. @discussion By setting this property you are requesting an image that may be up to as large as the specified dimensions, but no larger. The dimensions set must match one of the dimensions returned by AVCaptureDeviceFormat.supportedMaxPhotoDimensions for the currently configured format and be equal to or smaller than the value of AVCapturePhotoOutput.maxPhotoDimensions. This property defaults to the smallest dimensions returned by AVCaptureDeviceFormat.supportedMaxPhotoDimensions.

func (*AVCapturePhotoSettings) PhotoQualityPrioritization ¶

func (o *AVCapturePhotoSettings) PhotoQualityPrioritization() AVCapturePhotoQualityPrioritization

@property photoQualityPrioritization @abstract Indicates how photo quality should be prioritized against speed of photo delivery. @discussion Default value is AVCapturePhotoQualityPrioritizationBalanced. The AVCapturePhotoOutput is capable of applying a variety of techniques to improve photo quality (reduce noise, preserve detail in low light, freeze motion, etc), depending on the source device's activeFormat. Some of these techniques can take significant processing time before the photo is returned to your delegate callback. The photoQualityPrioritization property allows you to specify your preferred quality vs speed of delivery. By default, speed and quality are considered to be of equal importance. When you specify AVCapturePhotoQualityPrioritizationSpeed, you indicate that speed should be prioritized at the expense of quality. Likewise, when you choose AVCapturePhotoQualityPrioritizationQuality, you signal your willingness to prioritize the very best quality at the expense of speed, and your readiness to wait (perhaps significantly) longer for the photo to be returned to your delegate.

func (*AVCapturePhotoSettings) ProcessedFileType ¶

func (o *AVCapturePhotoSettings) ProcessedFileType() *foundation.NSString

@property processedFileType @abstract The file container for which the processed photo is formatted to be stored. @discussion The formatting of data within a photo buffer is often dependent on the file format intended for storage. For instance, a JPEG encoded photo buffer intended for storage in a JPEG (JPEG File Interchange Format) file differs from JPEG to be stored in HEIF. The HEIF-containerized JPEG buffer is tiled for readback efficiency and partitioned into the box structure dictated by the HEIF file format. Some codecs are only supported by AVCapturePhotoOutput if containerized. For instance, the AVVideoCodecTypeHEVC is only supported with AVFileTypeHEIF and AVFileTypeHEIC formatting. To discover which photo pixel format types and video codecs are supported for a given file type, you may query AVCapturePhotoOutput's -supportedPhotoPixelFormatTypesForFileType:, or -supportedPhotoCodecTypesForFileType: respectively.

func (*AVCapturePhotoSettings) SetConstantColorEnabled ¶

func (o *AVCapturePhotoSettings) SetConstantColorEnabled(constantColorEnabled bool)

func (*AVCapturePhotoSettings) SetConstantColorFallbackPhotoDeliveryEnabled ¶

func (o *AVCapturePhotoSettings) SetConstantColorFallbackPhotoDeliveryEnabled(constantColorFallbackPhotoDeliveryEnabled bool)

func (*AVCapturePhotoSettings) SetFlashMode ¶

func (o *AVCapturePhotoSettings) SetFlashMode(flashMode AVCaptureFlashMode)

func (*AVCapturePhotoSettings) SetHighResolutionPhotoEnabled deprecated

func (o *AVCapturePhotoSettings) SetHighResolutionPhotoEnabled(highResolutionPhotoEnabled bool)

Deprecated: Use maxPhotoDimensions instead.

func (*AVCapturePhotoSettings) SetMaxPhotoDimensions ¶

func (o *AVCapturePhotoSettings) SetMaxPhotoDimensions(maxPhotoDimensions coremedia.CMVideoDimensions)

func (*AVCapturePhotoSettings) SetPhotoQualityPrioritization ¶

func (o *AVCapturePhotoSettings) SetPhotoQualityPrioritization(photoQualityPrioritization AVCapturePhotoQualityPrioritization)

func (*AVCapturePhotoSettings) SetShutterSoundSuppressionEnabled ¶

func (o *AVCapturePhotoSettings) SetShutterSoundSuppressionEnabled(shutterSoundSuppressionEnabled bool)

func (*AVCapturePhotoSettings) UniqueID ¶

func (o *AVCapturePhotoSettings) UniqueID() int64

@property uniqueID @abstract A 64-bit number that uniquely identifies this instance. @discussion When you create an instance of AVCapturePhotoSettings, a uniqueID is generated automatically. This uniqueID is guaranteed to be unique for the life time of your process.

type AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions ¶

type AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions uint64
const (
	AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionNone                AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions = 0
	AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionVideoZoomChanged    AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions = 1
	AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionFocusModeChanged    AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions = 2
	AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditionExposureModeChanged AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions = 4
)

func (AVCapturePrimaryConstituentDeviceRestrictedSwitchingBehaviorConditions) String ¶

type AVCapturePrimaryConstituentDeviceSwitchingBehavior ¶

type AVCapturePrimaryConstituentDeviceSwitchingBehavior int64
const (
	AVCapturePrimaryConstituentDeviceSwitchingBehaviorUnsupported AVCapturePrimaryConstituentDeviceSwitchingBehavior = 0
	AVCapturePrimaryConstituentDeviceSwitchingBehaviorAuto        AVCapturePrimaryConstituentDeviceSwitchingBehavior = 1
	AVCapturePrimaryConstituentDeviceSwitchingBehaviorRestricted  AVCapturePrimaryConstituentDeviceSwitchingBehavior = 2
	AVCapturePrimaryConstituentDeviceSwitchingBehaviorLocked      AVCapturePrimaryConstituentDeviceSwitchingBehavior = 3
)

func (AVCapturePrimaryConstituentDeviceSwitchingBehavior) String ¶

type AVCaptureReactionEffectState ¶

type AVCaptureReactionEffectState struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturereactioneffectstate

func AVCaptureReactionEffectStateFromID ¶

func AVCaptureReactionEffectStateFromID(id objc.ID) *AVCaptureReactionEffectState

func (*AVCaptureReactionEffectState) EndTime ¶

@property endTime @abstract Provides the presentation time of the frame following the last frame where the effect is seen. @discussion Will be kCMTimeInvalid while the effect is in progress, but will be updated to a valid time when the reaction effect completes and the AVCaptureReactionEffectState is removed from -[AVCaptureDevice reactionEffectsInProgress]. (If using NSKeyValueObservingOptionOld, you can access completed effects with valid end times via NSKeyValueChangeOldKey.)

func (*AVCaptureReactionEffectState) ReactionType ¶

@property reactionType @abstract Indicates the reaction which is running. @discussion There may be multiple reactions of the same type at a given time. Some may come from gesture detection, some may come from calls to -[AVCaptureDevice performReactionEffect:]

func (*AVCaptureReactionEffectState) StartTime ¶

@property startTime @abstract Provides the presentation time of the first frame where the effect is being rendered.

type AVCaptureResolvedPhotoSettings ¶

type AVCaptureResolvedPhotoSettings struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureresolvedphotosettings

func AVCaptureResolvedPhotoSettingsFromID ¶

func AVCaptureResolvedPhotoSettingsFromID(id objc.ID) *AVCaptureResolvedPhotoSettings

func (*AVCaptureResolvedPhotoSettings) ExpectedPhotoCount ¶

func (o *AVCaptureResolvedPhotoSettings) ExpectedPhotoCount() uint

@property expectedPhotoCount @abstract Indicates the number of times your -captureOutput:didFinishProcessingPhoto:error: callback will be called. For instance, if you've requested an auto exposure bracket of 3 with JPEG and RAW, the expectedPhotoCount is 6.

func (*AVCaptureResolvedPhotoSettings) IsFastCapturePrioritizationEnabled ¶

func (o *AVCaptureResolvedPhotoSettings) IsFastCapturePrioritizationEnabled() bool

@property fastCapturePrioritizationEnabled @abstract Indicates whether fast capture prioritization will be employed when capturing the photo.

func (*AVCaptureResolvedPhotoSettings) PhotoDimensions ¶

@property photoDimensions @abstract The resolved dimensions of the photo buffer that will be delivered to the -captureOutput:didFinishProcessingPhotoSampleBuffer:previewPhotoSampleBuffer:resolvedSettings:bracketSettings:error: callback. @discussion If you request a RAW capture with no processed companion image, photoDimensions resolve to { 0, 0 }.

func (*AVCaptureResolvedPhotoSettings) UniqueID ¶

func (o *AVCaptureResolvedPhotoSettings) UniqueID() int64

@property uniqueID @abstract uniqueID matches that of the AVCapturePhotoSettings instance you passed to -capturePhotoWithSettings:delegate:.

type AVCaptureScreenInput ¶

type AVCaptureScreenInput struct {
	AVCaptureInput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturescreeninput

func AVCaptureScreenInputFromID ¶

func AVCaptureScreenInputFromID(id objc.ID) *AVCaptureScreenInput

func AVCaptureScreenInputNew ¶

func AVCaptureScreenInputNew() *AVCaptureScreenInput

func (*AVCaptureScreenInput) CapturesCursor ¶

func (o *AVCaptureScreenInput) CapturesCursor() bool

@property capturesCursor @abstract A property indicating whether the cursor should be rendered to the captured output. @discussion By default, AVCaptureScreenInput draws the cursor in its captured output. If this property is set to NO, the captured output contains only the windows on the screen. Cursor is omitted. Note that cursor position and mouse button state at the time of capture is preserved in CMSampleBuffers emitted from AVCaptureScreenInput. See the inline documentation for kCMIOSampleBufferAttachmentKey_MouseAndKeyboardModifiers in <CoreMediaIO/CMIOSampleBuffer.h>

func (*AVCaptureScreenInput) CapturesMouseClicks ¶

func (o *AVCaptureScreenInput) CapturesMouseClicks() bool

@property capturesMouseClicks @abstract A property indicating whether mouse clicks should be highlighted in the captured output. @discussion By default, AVCaptureScreenInput does not highlight mouse clicks in its captured output. If this property is set to YES, mouse clicks are highlighted (a circle is drawn around the mouse for the duration of the click) in the captured output.

func (*AVCaptureScreenInput) CropRect ¶

@property cropRect @abstract A property indicating the bounding rectangle of the screen area to be captured in points. @discussion By default, AVCaptureScreenInput captures the entire area of the displayID with which it is associated. To limit the capture rectangle to a subsection of the screen, set the cropRect property, which defines a smaller section of the screen in the screen's coordinate system. The origin (0,0) is the bottom-left corner of the screen.

func (*AVCaptureScreenInput) Init ¶

@method init @abstract Creates an AVCaptureScreenInput instance that provides media data from the main display. @discussion This method creates an instance of AVCaptureScreenInput using the main display whose id is returned from CGMainDisplayID().

func (*AVCaptureScreenInput) InitWithDisplayID ¶

func (o *AVCaptureScreenInput) InitWithDisplayID(displayID uint32) *AVCaptureScreenInput

@method initWithDisplayID: @abstract Creates an AVCaptureScreenInput instance that provides media data from the given display. @param displayID The id of the display from which to capture video. CGDirectDisplayID is defined in <CoreGraphics/CGDirectDisplay.h> @result An AVCaptureScreenInput instance that provides data from the given screen, or nil, if the screen could not be used for capture. @discussion This method creates an instance of AVCaptureScreenInput that can be used to capture data from a display in an AVCaptureSession. This method validates the displayID. If the display cannot be used because it is not available on the system, for example, this method returns nil.

func (*AVCaptureScreenInput) MinFrameDuration ¶

func (o *AVCaptureScreenInput) MinFrameDuration() coremedia.CMTime

@property minFrameDuration @abstract A property indicating the screen input's minimum frame duration. @discussion An AVCaptureScreenInput's minFrameDuration is the reciprocal of its maximum frame rate. This property may be used to request a maximum frame rate at which the input produces video frames. The requested rate may not be achievable due to overall bandwidth, so actual frame rates may be lower.

func (*AVCaptureScreenInput) RemovesDuplicateFrames ¶

func (o *AVCaptureScreenInput) RemovesDuplicateFrames() bool

@property removesDuplicateFrames @abstract A property indicating whether duplicate frames should be removed by the input. @discussion If this property is set to YES, AVCaptureScreenInput performs frame differencing and when it detects duplicate frames, it drops them. If set to NO, the captured output receives all frames from the input. Prior to 10.9 this value defaulted to YES. In 10.9 and later, it defaults to NO, as modern platforms support frame differencing in hardware-based encoders. As of 10.10, this property has been deprecated and is ignored. Clients wishing to re-create this functionality can use an AVCaptureVideoDataOutput and compare frame contents in their own code. If they wish to write a movie file, they can then pass the unique frames to an AVAssetWriterInput. Deprecated: No longer supported.

func (*AVCaptureScreenInput) ScaleFactor ¶

func (o *AVCaptureScreenInput) ScaleFactor() float64

@property scaleFactor @abstract A property indicating the factor by which video buffers captured from the screen are to be scaled. @discussion By default, AVCaptureScreenInput captures the video buffers from the display at a scale factor of 1.0 (no scaling). Set this property to scale the buffers by a given factor. For instance, a 320x240 capture area with a scaleFactor of 2.0f produces video buffers at 640x480.

func (*AVCaptureScreenInput) SetCapturesCursor ¶

func (o *AVCaptureScreenInput) SetCapturesCursor(capturesCursor bool)

func (*AVCaptureScreenInput) SetCapturesMouseClicks ¶

func (o *AVCaptureScreenInput) SetCapturesMouseClicks(capturesMouseClicks bool)

func (*AVCaptureScreenInput) SetCropRect ¶

func (o *AVCaptureScreenInput) SetCropRect(cropRect corefoundation.CGRect)

func (*AVCaptureScreenInput) SetMinFrameDuration ¶

func (o *AVCaptureScreenInput) SetMinFrameDuration(minFrameDuration coremedia.CMTime)

func (*AVCaptureScreenInput) SetRemovesDuplicateFrames deprecated

func (o *AVCaptureScreenInput) SetRemovesDuplicateFrames(removesDuplicateFrames bool)

Deprecated: No longer supported.

func (*AVCaptureScreenInput) SetScaleFactor ¶

func (o *AVCaptureScreenInput) SetScaleFactor(scaleFactor float64)

type AVCaptureSession ¶

type AVCaptureSession struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturesession

func AVCaptureSessionFromID ¶

func AVCaptureSessionFromID(id objc.ID) *AVCaptureSession

func (*AVCaptureSession) AddConnection ¶

func (o *AVCaptureSession) AddConnection(connection *AVCaptureConnection)

@method addConnection: @abstract Adds an AVCaptureConnection to the session. @param connection An AVCaptureConnection instance. @discussion An AVCaptureConnection instance can only be added to a session using -addConnection: if canAddConnection: returns YES, otherwise an NSInvalidArgumentException is thrown. When using -addInput: or -addOutput:, connections are formed automatically between all compatible inputs and outputs. Manually adding connections is only necessary when adding an input or output with no connections. -addConnection: may be called while the session is running.

func (*AVCaptureSession) AddControl ¶

func (o *AVCaptureSession) AddControl(control *AVCaptureControl)

@method addControl: @abstract Adds an `AVCaptureControl` instance to the session. @param control An `AVCaptureControl` instance. @discussion An `AVCaptureControl` instance can only be added to a session using `-addControl:` if `-canAddControl:` returns `YES`, otherwise an `NSInvalidArgumentException` is thrown. `-addControl:` may be called while the session is running. For an `AVCaptureControl` instance to become active, an `AVCaptureSessionControlsDelegate` must be set on the session.

func (*AVCaptureSession) AddInput ¶

func (o *AVCaptureSession) AddInput(input *AVCaptureInput)

@method addInput: @abstract Adds an AVCaptureInput to the session. @param input An AVCaptureInput instance. @discussion An AVCaptureInput instance can only be added to a session using -addInput: if -canAddInput: returns YES, otherwise an NSInvalidArgumentException is thrown. -addInput: may be called while the session is running.

func (*AVCaptureSession) AddInputWithNoConnections ¶

func (o *AVCaptureSession) AddInputWithNoConnections(input *AVCaptureInput)

@method addInputWithNoConnections: @abstract Adds an AVCaptureInput to the session without forming any connections. @param input An AVCaptureInput instance. @discussion An AVCaptureInput instance can only be added to a session using -addInputWithNoConnections: if -canAddInput: returns YES, otherwise an NSInvalidArgumentException is thrown. -addInputWithNoConnections: may be called while the session is running. The -addInput: method is the preferred method for adding an input to an AVCaptureSession. -addInputWithNoConnections: may be called if you need fine-grained control over which inputs are connected to which outputs.

func (*AVCaptureSession) AddOutput ¶

func (o *AVCaptureSession) AddOutput(output *AVCaptureOutput)

@method addOutput: @abstract Adds an AVCaptureOutput to the session. @param output An AVCaptureOutput instance. @discussion An AVCaptureOutput instance can only be added to a session using -addOutput: if -canAddOutput: returns YES, otherwise an NSInvalidArgumentException is thrown. -addOutput: may be called while the session is running.

func (*AVCaptureSession) AddOutputWithNoConnections ¶

func (o *AVCaptureSession) AddOutputWithNoConnections(output *AVCaptureOutput)

@method addOutputWithNoConnections: @abstract Adds an AVCaptureOutput to the session without forming any connections. @param output An AVCaptureOutput instance. @discussion An AVCaptureOutput instance can only be added to a session using -addOutputWithNoConnections: if -canAddOutput: returns YES, otherwise an NSInvalidArgumentException is thrown. -addOutputWithNoConnections: may be called while the session is running. The -addOutput: method is the preferred method for adding an output to an AVCaptureSession. -addOutputWithNoConnections: may be called if you need fine-grained control over which inputs are connected to which outputs.

func (*AVCaptureSession) AutomaticallyRunsDeferredStart ¶

func (o *AVCaptureSession) AutomaticallyRunsDeferredStart() bool

A `BOOL` value that indicates whether deferred start runs automatically. Deferred Start is a feature that allows you to control, on a per-output basis, whether output objects start when or after the session is started. The session defers starting an output when its “AVCaptureOutput/deferredStartEnabled“ property is set to `true`, and starts it after the session is started. When this value is `true`, “AVCaptureSession“ automatically runs deferred start. If only “AVCaptureVideoPreviewLayer“ objects have “AVCaptureVideoPreviewLayer/deferredStartEnabled“ set to `false`, the session runs deferred start a short time after displaying the first frame. If there are “AVCaptureOutput“ objects that have “AVCaptureOutput/deferredStartEnabled“ set to `false`, then the session waits until each output that provides streaming data to your app sends its first frame. If you set this value to `false`, call “runDeferredStartWhenNeeded“ to indicate when to run deferred start. By default, for apps that are linked on or after iOS 26, this value is `true`. - Note: If “manualDeferredStartSupported“ is `false`, setting this property value to `false` results in the session throwing an `NSInvalidArgumentException`. - Note: Set this value before committing the configuration.

func (*AVCaptureSession) BeginConfiguration ¶

func (o *AVCaptureSession) BeginConfiguration()

@method beginConfiguration @abstract When paired with commitConfiguration, allows a client to batch multiple configuration operations on a running session into atomic updates. @discussion -beginConfiguration / -commitConfiguration are AVCaptureSession's mechanism for batching multiple configuration operations on a running session into atomic updates. After calling [session beginConfiguration], clients may add or remove outputs, alter the sessionPreset, or configure individual AVCaptureInput or Output properties. All changes will be pended until the client calls [session commitConfiguration], at which time they will be applied together. -beginConfiguration / -commitConfiguration pairs may be nested, and will only be applied when the outermost commit is invoked. If you've called -beginConfiguration, you must call -commitConfiguration before invoking -startRunning or -stopRunning, otherwise an NSGenericException is thrown.

func (*AVCaptureSession) CanAddConnection ¶

func (o *AVCaptureSession) CanAddConnection(connection *AVCaptureConnection) bool

@method canAddConnection: @abstract Returns whether the proposed connection can be added to the receiver. @param connection An AVCaptureConnection instance. @discussion An AVCaptureConnection instance can only be added to a session using -addConnection: if -canAddConnection: returns YES, otherwise an NSInvalidArgumentException is thrown. When using -addInput: or -addOutput:, connections are formed automatically between all compatible inputs and outputs. Manually adding connections is only necessary when adding an input or output with no connections.

func (*AVCaptureSession) CanAddControl ¶

func (o *AVCaptureSession) CanAddControl(control *AVCaptureControl) bool

@method canAddControl: @abstract Returns whether the proposed control can be added to the session. @param control An `AVCaptureControl` instance. @result `YES` if the proposed control can be added to the session, `NO` otherwise. @discussion An `AVCaptureControl` instance can only be added to a session using `-addControl:` if `-canAddControl:` returns `YES`. For example, some platforms do not support controls. Instances of `AVCaptureSlider`, `AVCaptureToggle` and `AVCaptureIndexPicker` must have an action and an action queue set before being added to a session.

func (*AVCaptureSession) CanAddInput ¶

func (o *AVCaptureSession) CanAddInput(input *AVCaptureInput) bool

@method canAddInput: @abstract Returns whether the proposed input can be added to the receiver. @param input An AVCaptureInput instance. @result YES if the proposed input can be added to the receiver, NO otherwise. @discussion An AVCaptureInput instance can only be added to a session using -addInput: if -canAddInput: returns YES, otherwise an NSInvalidArgumentException is thrown.

func (*AVCaptureSession) CanAddOutput ¶

func (o *AVCaptureSession) CanAddOutput(output *AVCaptureOutput) bool

@method canAddOutput: @abstract Returns whether the proposed output can be added to the receiver. @param output An AVCaptureOutput instance. @result YES if the proposed output can be added to the receiver, NO otherwise. @discussion An AVCaptureOutput instance can only be added to a session using -addOutput: if -canAddOutput: returns YES, otherwise an NSInvalidArgumentException is thrown. On iOS and Mac Catalyst, some limitations to adding combinations of different types of outputs apply: - A maximum of one output of each type may be added. For applications linked on or after iOS 16.0, this restriction no longer applies to AVCaptureVideoDataOutputs. When adding more than one AVCaptureVideoDataOutput, AVCaptureSession.hardwareCost must be taken into account. - A session cannot contain both an AVCaptureStillImageOutput and an AVCapturePhotoOutput at the same time. - Prior to iOS 16.0, an AVCaptureVideoDataOutput and an AVCaptureMovieFileOutput may be added to the same session, but only one may have its connection active. When both have their connections enabled, the AVCaptureMovieFileOutput "wins" and the AVCaptureVideoDataOutput's connection becomes inactive. For applications linked on or after iOS 16.0, this restriction has been lifted. When adding multiple AVCaptureVideoDataOutputs or a combination of AVCaptureVideoDataOutputs and an AVCaptureMovieFileOutput, AVCaptureSession.hardwareCost must be taken into account. - Similarly, prior to iOS 16.0, an AVCaptureAudioDataOutput and an AVCaptureMovieFileOutput may be added to the same session, but only one may have its connection active. When both have their connections enabled, the AVCaptureMovieFileOutput "wins" and the AVCaptureAudioDataOutput's connection becomes inactive. For applications linked on or after iOS 16.0, this restriction has been lifted.

func (*AVCaptureSession) CanSetSessionPreset ¶

func (o *AVCaptureSession) CanSetSessionPreset(preset *foundation.NSString) bool

@method canSetSessionPreset: @abstract Returns whether the receiver can be configured with the given preset. @param preset An AVCaptureSession preset. @result YES if the receiver can be set to the given preset, NO otherwise. @discussion An AVCaptureSession instance can be associated with a preset that configures its inputs and outputs to fulfill common use cases. This method can be used to determine if the receiver supports the desired preset given its current input and output configuration. The receiver's sessionPreset property may only be set to a certain preset if this method returns YES for that preset.

func (*AVCaptureSession) CommitConfiguration ¶

func (o *AVCaptureSession) CommitConfiguration()

@method commitConfiguration @abstract When preceded by beginConfiguration, allows a client to batch multiple configuration operations on a running session into atomic updates. @discussion -beginConfiguration / -commitConfiguration are AVCaptureSession's mechanism for batching multiple configuration operations on a running session into atomic updates. After calling [session beginConfiguration], clients may add or remove outputs, alter the sessionPreset, or configure individual AVCaptureInput or Output properties. All changes will be pended until the client calls [session commitConfiguration], at which time they will be applied together. -beginConfiguration / -commitConfiguration pairs may be nested, and will only be applied when the outermost commit is invoked. If you've called -beginConfiguration, you must call -commitConfiguration before invoking -startRunning or -stopRunning, otherwise an NSGenericException is thrown.

func (*AVCaptureSession) Connections ¶

@property connections @abstract An NSArray of AVCaptureConnections currently added to the receiver. @discussion The value of this property is an NSArray of AVCaptureConnections currently added to the receiver. Connections are formed implicitly by the receiver when a client calls -addInput: or -addOutput:. Connections are formed explicitly when a client calls -addConnection:.

func (*AVCaptureSession) Controls ¶

@property controls @abstract An `NSArray` of `AVCaptureControl`s currently added to the session. @discussion The value of this property is an `NSArray` of `AVCaptureControl`s currently added to the session. Clients can add `AVCaptureControl`s to a session by calling `-addControl:`.

func (*AVCaptureSession) ControlsDelegate ¶

func (o *AVCaptureSession) ControlsDelegate() AVCaptureSessionControlsDelegate

@property controlsDelegate @abstract The receiver's controls delegate. @discussion The value of this property is an object conforming to the `AVCaptureSessionControlsDelegate` protocol that receives events about the session's controls. The delegate is set using the `-setControlsDelegate:queue:` method. A controls delegate must be specified for controls to become active.

func (*AVCaptureSession) ControlsDelegateCallbackQueue ¶

func (o *AVCaptureSession) ControlsDelegateCallbackQueue() *foundation.NSObject

@property controlsDelegateCallbackQueue @abstract The dispatch queue on which all controls delegate methods will be called. @discussion The value of this property is a `dispatch_queue_t`. The queue is set using the `-setControlsDelegate:queue:` method.

func (*AVCaptureSession) DeferredStartDelegate ¶

func (o *AVCaptureSession) DeferredStartDelegate() AVCaptureSessionDeferredStartDelegate

A delegate object that observes events about deferred start. Call the “setDeferredStartDelegate:deferredStartDelegateCallbackQueue:“ method to set the deferred start delegate for a session.

func (*AVCaptureSession) DeferredStartDelegateCallbackQueue ¶

func (o *AVCaptureSession) DeferredStartDelegateCallbackQueue() *foundation.NSObject

The dispatch queue on which the session calls deferred start delegate methods. Call the “setDeferredStartDelegate:deferredStartDelegateCallbackQueue:“ method to specify the dispatch queue on which to call the deferred start delegate methods.

func (*AVCaptureSession) Inputs ¶

@property inputs @abstract An NSArray of AVCaptureInputs currently added to the receiver. @discussion The value of this property is an NSArray of AVCaptureInputs currently added to the receiver. Clients can add AVCaptureInputs to a session by calling -addInput:.

func (*AVCaptureSession) IsManualDeferredStartSupported ¶

func (o *AVCaptureSession) IsManualDeferredStartSupported() bool

A `BOOL` value that indicates whether the session supports manually running deferred start. Deferred Start is a feature that allows you to control, on a per-output basis, whether output objects start when or after the session is started. The session defers starting an output when its “deferredStartEnabled“ property is set to `true`, and starts it after the session is started. You can only set the “automaticallyRunsDeferredStart“ property value to `false` if the session supports manual deferred start.

func (*AVCaptureSession) IsRunning ¶

func (o *AVCaptureSession) IsRunning() bool

@property running @abstract Indicates whether the session is currently running. @discussion The value of this property is a BOOL indicating whether the receiver is running. Clients can key value observe the value of this property to be notified when the session automatically starts or stops running.

func (*AVCaptureSession) MasterClock ¶

func (o *AVCaptureSession) MasterClock() unsafe.Pointer

@property masterClock @abstract Provides the clock being used for synchronization. @discussion Deprecated. Please use synchronizationClock instead. Deprecated: since macOS 12.3.

func (*AVCaptureSession) MaxControlsCount ¶

func (o *AVCaptureSession) MaxControlsCount() int

@property maxControlsCount @abstract Specifies the maximum number of controls that can be added to a session.

func (*AVCaptureSession) Outputs ¶

@property outputs @abstract An NSArray of AVCaptureOutputs currently added to the receiver. @discussion The value of this property is an NSArray of AVCaptureOutputs currently added to the receiver. Clients can add AVCaptureOutputs to a session by calling -addOutput:.

func (*AVCaptureSession) RemoveConnection ¶

func (o *AVCaptureSession) RemoveConnection(connection *AVCaptureConnection)

@method removeConnection: @abstract Removes an AVCaptureConnection from the session. @param connection An AVCaptureConnection instance. @discussion -removeConnection: may be called while the session is running.

func (*AVCaptureSession) RemoveControl ¶

func (o *AVCaptureSession) RemoveControl(control *AVCaptureControl)

@method removeControl: @abstract Removes an `AVCaptureControl` instance from the session. @param control An `AVCaptureControl` instance. @discussion `-removeControl:` may be called while the session is running.

func (*AVCaptureSession) RemoveInput ¶

func (o *AVCaptureSession) RemoveInput(input *AVCaptureInput)

@method removeInput: @abstract Removes an AVCaptureInput from the session. @param input An AVCaptureInput instance. @discussion -removeInput: may be called while the session is running.

func (*AVCaptureSession) RemoveOutput ¶

func (o *AVCaptureSession) RemoveOutput(output *AVCaptureOutput)

@method removeOutput: @abstract Removes an AVCaptureOutput from the session. @param output An AVCaptureOutput instance. @discussion -removeOutput: may be called while the session is running.

func (*AVCaptureSession) RunDeferredStartWhenNeeded ¶

func (o *AVCaptureSession) RunDeferredStartWhenNeeded()

Tells the session to run deferred start when appropriate. For best perceived startup performance, call this after displaying the first frame, so that deferred start processing doesn't interfere with other initialization operations. For example, if using a <doc://com.apple.documentation/documentation/quartzcore/cametallayer> to draw camera frames, add a `presentHandler` (using <doc://com.apple.documentation/metal/mtldrawable/addpresentedhandler>) to the first drawable and call “runDeferredStartWhenNeeded“ from there. If one or more outputs need to start to perform a capture operation, and “runDeferredStartWhenNeeded“ has not run yet, the session runs the deferred start on your app's behalf. Only call this method once for each configuration commit - after the first call, subsequent calls to “runDeferredStartWhenNeeded“ have no effect. The deferred start runs asynchronously, so this method returns immediately. - Note: You can only call this when “automaticallyRunsDeferredStart“ is `false`. Otherwise, the session throws an `NSInvalidArgumentException`. - Important: To avoid blocking your app's UI, don't call this method from the application's main actor or queue.

func (*AVCaptureSession) SessionPreset ¶

func (o *AVCaptureSession) SessionPreset() *foundation.NSString

@property sessionPreset @abstract Indicates the session preset currently in use by the receiver. @discussion The value of this property is an AVCaptureSessionPreset indicating the current session preset in use by the receiver. The sessionPreset property may be set while the receiver is running.

func (*AVCaptureSession) SetAutomaticallyRunsDeferredStart ¶

func (o *AVCaptureSession) SetAutomaticallyRunsDeferredStart(automaticallyRunsDeferredStart bool)

func (*AVCaptureSession) SetControlsDelegateQueue ¶

func (o *AVCaptureSession) SetControlsDelegateQueue(controlsDelegate AVCaptureSessionControlsDelegate, controlsDelegateCallbackQueue *foundation.NSObject)

@method setControlsDelegate:queue: @abstract Sets the receiver's controls delegate that receives events about the session's controls and the dispatch queue on which the delegate is called. @param controlsDelegate An object conforming to the `AVCaptureSessionControlsDelegate` protocol that receives events about the session's controls. @param controlsDelegateCallbackQueue A dispatch queue on which all delegate methods are called. @discussion Users can interact with an `AVCaptureSession`'s controls by performing specific gestures to enable their visibility. A delegate may be specified to be informed when the controls can be interacted with and are dismissed. All delegate methods will be called on the specified dispatch queue. A serial dispatch queue must be used to guarantee that delegate callbacks will be delivered in order. The `controlsDelegateCallbackQueue` parameter may not be `NULL`, except when setting the `controlsDelegate` to `nil` otherwise `-setControlsDelegate:queue:` throws an `NSInvalidArgumentException`.

func (*AVCaptureSession) SetDeferredStartDelegateDeferredStartDelegateCallbackQueue ¶

func (o *AVCaptureSession) SetDeferredStartDelegateDeferredStartDelegateCallbackQueue(deferredStartDelegate AVCaptureSessionDeferredStartDelegate, deferredStartDelegateCallbackQueue *foundation.NSObject)

Sets a delegate object for the session to call when performing deferred start. This delegate receives a call to the “AVCaptureSessionDeferredStartDelegate/sessionWillRunDeferredStart:“ method when deferred start is about to run. It is non-blocking, so by the time this method is called, the deferred start may already be underway. If you want your app to perform initialization (potentially) concurrently with deferred start (e.g. user-facing camera features that are not needed to display the first preview frame, but are available to the user as soon as possible) it may be done in the delegate's “AVCaptureSessionDeferredStartDelegate/sessionWillRunDeferredStart:“ method. To wait until deferred start is finished to perform some remaining initialization work, use the “AVCaptureSessionDeferredStartDelegate/sessionDidRunDeferredStart:“ method instead. The delegate receives a call to the “AVCaptureSessionDeferredStartDelegate/sessionDidRunDeferredStart:“ method when the deferred start finishes running. This allows you to run less-critical application initialization code. For example, if you've deferred an “AVCapturePhotoOutput“ by setting its “AVCaptureOutput/deferredStartEnabled“ property to `true`, and you'd like to do some app-specific initialization related to still capture, here might be a good place to put it. If the delegate is non-nil, the session still calls the “AVCaptureSessionDeferredStartDelegate/sessionWillRunDeferredStart:“ and “AVCaptureSessionDeferredStartDelegate/sessionDidRunDeferredStart:“ methods regardless of the value of the session's “automaticallyRunsDeferredStart“ property. To minimize the capture session's startup latency, defer all unnecessary work until after the session starts. This delegate provides callbacks for you to schedule deferred work without impacting session startup performance. To perform initialization prior to deferred start but after the user interface displays, set “automaticallyRunsDeferredStart“ to `false`, and then run the custom initialization prior to calling “runDeferredStartWhenNeeded“. If “deferredStartDelegate“ is not `NULL`, the session throws an exception if “deferredStartDelegateCallbackQueue“ is `nil`. - Parameter deferredStartDelegate: An object conforming to the “AVCaptureSessionDeferredStartDelegate“ protocol that receives events about deferred start. - Parameter deferredStartDelegateCallbackQueue: A dispatch queue on which deferredStart delegate methods are called.

func (*AVCaptureSession) SetSessionPreset ¶

func (o *AVCaptureSession) SetSessionPreset(sessionPreset *foundation.NSString)

func (*AVCaptureSession) StartRunning ¶

func (o *AVCaptureSession) StartRunning()

@method startRunning @abstract Starts an AVCaptureSession instance running. @discussion Clients invoke -startRunning to start the flow of data from inputs to outputs connected to the AVCaptureSession instance. This call blocks until the session object has completely started up or failed. A failure to start running is reported through the AVCaptureSessionRuntimeErrorNotification mechanism. If you've called -beginConfiguration, you must call -commitConfiguration before invoking -startRunning, otherwise an NSGenericException is thrown.

func (*AVCaptureSession) StopRunning ¶

func (o *AVCaptureSession) StopRunning()

@method stopRunning @abstract Stops an AVCaptureSession instance that is currently running. @discussion Clients invoke -stopRunning to stop the flow of data from inputs to outputs connected to the AVCaptureSession instance. This call blocks until the session object has completely stopped. -stopRunning may not be called while the session is being configured. If you've called -beginConfiguration, you must call -commitConfiguration before invoking -stopRunning, otherwise an NSGenericException is thrown.

func (*AVCaptureSession) SupportsControls ¶

func (o *AVCaptureSession) SupportsControls() bool

@property supportsControls @abstract Indicates whether session controls are supported on this platform. @discussion `AVCaptureControl`s are only supported on platforms with necessary hardware.

func (*AVCaptureSession) SynchronizationClock ¶

func (o *AVCaptureSession) SynchronizationClock() unsafe.Pointer

@property synchronizationClock @abstract Provides the clock being used for synchronization. @discussion synchronizationClock is readonly. Use synchronizationClock to synchronize AVCaptureOutput data with external data sources (e.g motion samples). All capture output sample buffer timestamps are on the synchronizationClock timebase. For example, if you want to reverse synchronize the output timestamps to the original timestamps, you can do the following: In captureOutput:didOutputSampleBuffer:fromConnection: AVCaptureInputPort *port = [[connection inputPorts] objectAtIndex:0]; CMClockRef originalClock = [port clock]; CMTime syncedPTS = CMSampleBufferGetPresentationTime( sampleBuffer ); CMTime originalPTS = CMSyncConvertTime( syncedPTS, [session synchronizationClock], originalClock ); This property is key-value observable.

type AVCaptureSessionControlsDelegate ¶

type AVCaptureSessionControlsDelegate interface {
	SessionControlsDidBecomeActive(session *AVCaptureSession)
	SessionControlsWillEnterFullscreenAppearance(session *AVCaptureSession)
	SessionControlsWillExitFullscreenAppearance(session *AVCaptureSession)
	SessionControlsDidBecomeInactive(session *AVCaptureSession)
}

AVCaptureSessionControlsDelegate wraps the ObjC protocol AVCaptureSessionControlsDelegate.

type AVCaptureSessionDeferredStartDelegate ¶

type AVCaptureSessionDeferredStartDelegate interface {
	SessionWillRunDeferredStart(session *AVCaptureSession)
	SessionDidRunDeferredStart(session *AVCaptureSession)
}

AVCaptureSessionDeferredStartDelegate wraps the ObjC protocol AVCaptureSessionDeferredStartDelegate.

type AVCaptureSlider ¶

type AVCaptureSlider struct {
	AVCaptureControl
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcaptureslider

func AVCaptureSliderFromID ¶

func AVCaptureSliderFromID(id objc.ID) *AVCaptureSlider

func (*AVCaptureSlider) AccessibilityIdentifier ¶

func (o *AVCaptureSlider) AccessibilityIdentifier() *foundation.NSString

@property accessibilityIdentifier @abstract A string that identifies the slider.

func (*AVCaptureSlider) InitWithLocalizedTitleSymbolNameMinValueMaxValue ¶

func (o *AVCaptureSlider) InitWithLocalizedTitleSymbolNameMinValueMaxValue(localizedTitle *foundation.NSString, symbolName *foundation.NSString, minValue float32, maxValue float32) *AVCaptureSlider

@method initWithLocalizedTitle:symbolName:minValue:maxValue: @abstract Initializes an `AVCaptureSlider` as a continuous slider between `minValue` and `maxValue`. @param localizedTitle A localized string that describes the slider's `action`. @param symbolName The name of a symbol to represent the slider. @param minValue The minimum value the slider can have. `minValue` must be less than `maxValue`, otherwise an `NSInvalidArgumentException` is thrown. @param maxValue The maximum value the slider can have. `maxValue` must be greater than `minValue`, otherwise an `NSInvalidArgumentException` is thrown. @result An `AVCaptureSlider` instance as a continuous slider between `minValue` and `maxValue`. @discussion Continuous sliders are used when any value in the range `minValue...maxValue` is supported.

func (*AVCaptureSlider) InitWithLocalizedTitleSymbolNameMinValueMaxValueStep ¶

func (o *AVCaptureSlider) InitWithLocalizedTitleSymbolNameMinValueMaxValueStep(localizedTitle *foundation.NSString, symbolName *foundation.NSString, minValue float32, maxValue float32, step float32) *AVCaptureSlider

@method initWithLocalizedTitle:symbolName:minValue:maxValue:step: @abstract Initializes an `AVCaptureSlider` as a discrete slider where the valid values are between `minValue` and `maxValue` with `step` distance between each value. @param localizedTitle A localized string that describes the slider's `action`. @param symbolName The name of a symbol to represent the slider. @param minValue The minimum value the slider can have. `minValue` must be less than `maxValue`, otherwise an `NSInvalidArgumentException` is thrown. @param maxValue The maximum value the slider can have. `maxValue` must be greater than `minValue`, otherwise an `NSInvalidArgumentException` is thrown. @param step The distance between each valid value. `step` must be greater than 0, otherwise an `NSInvalidArgumentException` is thrown. @result An `AVCaptureSlider` instance as a discrete slider where the valid values are between `minValue` and `maxValue` with `step` distance between each value. @discussion Discrete sliders are used when only specific values are valid.

func (*AVCaptureSlider) InitWithLocalizedTitleSymbolNameValues ¶

func (o *AVCaptureSlider) InitWithLocalizedTitleSymbolNameValues(localizedTitle *foundation.NSString, symbolName *foundation.NSString, values *foundation.NSArray[*foundation.NSNumber]) *AVCaptureSlider

@method initWithLocalizedTitle:symbolName:values: @abstract Initializes an `AVCaptureSlider` as a discrete slider where `values` contains the valid values. @param localizedTitle A localized string that describes the slider's `action`. @param symbolName The name of a symbol to represent the slider. @param values The only values the slider can have. @result An `AVCaptureSlider` instance as a discrete slider where `values` contains the valid values. @discussion Discrete sliders are used when only specific values are valid.

func (*AVCaptureSlider) LocalizedTitle ¶

func (o *AVCaptureSlider) LocalizedTitle() *foundation.NSString

@property localizedTitle @abstract A localized string that describes the slider's `action`.

func (*AVCaptureSlider) LocalizedValueFormat ¶

func (o *AVCaptureSlider) LocalizedValueFormat() *foundation.NSString

@property localizedValueFormat @abstract A localized string defining the presentation of the slider's value. @discussion To modify the presentation of the slider's value, set `localizedValueFormat` to a format string to display the slider's value with any annotation. The format string may only contain `%@` and no other placeholders like `%d`, `%s`, etc. Invalid format strings will result in the value's default presentation. Examples of valid format strings are: - `%@%%` for "40%" - `%@ fps` for "60 fps" - `+ %@` for "+ 20"

func (*AVCaptureSlider) ProminentValues ¶

func (o *AVCaptureSlider) ProminentValues() *foundation.NSArray[*foundation.NSNumber]

@property prominentValues @abstract Values in this array may receive unique visual representations or behaviors.

func (*AVCaptureSlider) SetAccessibilityIdentifier ¶

func (o *AVCaptureSlider) SetAccessibilityIdentifier(accessibilityIdentifier *foundation.NSString)

func (*AVCaptureSlider) SetActionQueueAction ¶

func (o *AVCaptureSlider) SetActionQueueAction(actionQueue *foundation.NSObject, action func(float32))

@method setActionQueue:action: @abstract Configures the slider's `action` which is called on `actionQueue` whenever the value of the slider is changed. @param actionQueue A queue for the `action` to be called. @param action An action called on `actionQueue` whenever the value of the slider is changed. @discussion Because the camera system may be independent from the main thread or `@MainActor`, `action` is always called on an internal `DispatchSerialQueue` targeted at `actionQueue`. If `action` modifies a property of the camera system, `actionQueue` must represent the same exclusive execution context as the camera system (see `isSameExclusiveExecutionContext`).

func (*AVCaptureSlider) SetLocalizedValueFormat ¶

func (o *AVCaptureSlider) SetLocalizedValueFormat(localizedValueFormat *foundation.NSString)

func (*AVCaptureSlider) SetProminentValues ¶

func (o *AVCaptureSlider) SetProminentValues(prominentValues *foundation.NSArray[*foundation.NSNumber])

func (*AVCaptureSlider) SetValue ¶

func (o *AVCaptureSlider) SetValue(value float32)

func (*AVCaptureSlider) SymbolName ¶

func (o *AVCaptureSlider) SymbolName() *foundation.NSString

@property symbolName @abstract The name of a symbol to represent the slider.

func (*AVCaptureSlider) Value ¶

func (o *AVCaptureSlider) Value() float32

@property value @abstract The current value of the slider. @discussion Because the camera system may be independent from the main thread or `@MainActor`, `value` must be changed on `actionQueue` – the queue provided to `setActionQueue:action:`. The default value is the slider's minimum value. A value may only be set if it is within the slider's minimum and maximum values, otherwise an `NSInvalidArgumentException` is thrown.

type AVCaptureStillImageOutput ¶

type AVCaptureStillImageOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturestillimageoutput Deprecated: Use AVCapturePhotoOutput instead.

func AVCaptureStillImageOutputFromID ¶

func AVCaptureStillImageOutputFromID(id objc.ID) *AVCaptureStillImageOutput

func AVCaptureStillImageOutputNew ¶

func AVCaptureStillImageOutputNew() *AVCaptureStillImageOutput

func (*AVCaptureStillImageOutput) AvailableImageDataCVPixelFormatTypes ¶

func (o *AVCaptureStillImageOutput) AvailableImageDataCVPixelFormatTypes() *foundation.NSArray[*foundation.NSNumber]

@property availableImageDataCVPixelFormatTypes @abstract Indicates the supported image pixel formats that can be specified in outputSettings. @discussion The value of this property is an NSArray of NSNumbers that can be used as values for the kCVPixelBufferPixelFormatTypeKey in the receiver's outputSettings property. The first format in the returned list is the most efficient output format.

func (*AVCaptureStillImageOutput) AvailableImageDataCodecTypes ¶

func (o *AVCaptureStillImageOutput) AvailableImageDataCodecTypes() *foundation.NSArray[*foundation.NSString]

@property availableImageDataCodecTypes @abstract Indicates the supported image codec formats that can be specified in outputSettings. @discussion The value of this property is an NSArray of AVVideoCodecTypes that can be used as values for the AVVideoCodecKey in the receiver's outputSettings property.

func (*AVCaptureStillImageOutput) CaptureStillImageAsynchronouslyFromConnectionCompletionHandler ¶

func (o *AVCaptureStillImageOutput) CaptureStillImageAsynchronouslyFromConnectionCompletionHandler(connection *AVCaptureConnection, handler func(unsafe.Pointer, unsafe.Pointer))

@method captureStillImageAsynchronouslyFromConnection:completionHandler: @abstract Initiates an asynchronous still image capture, returning the result to a completion handler. @param connection The AVCaptureConnection object from which to capture the still image. @param handler A block that will be called when the still image capture is complete. The block will be passed a CMSampleBuffer object containing the image data or an NSError object if an image could not be captured. @discussion This method will return immediately after it is invoked, later calling the provided completion handler block when image data is ready. If the request could not be completed, the error parameter will contain an NSError object describing the failure. Attachments to the image data sample buffer may contain metadata appropriate to the image data format. For instance, a sample buffer containing JPEG data may carry a kCGImagePropertyExifDictionary as an attachment. See <ImageIO/CGImageProperties.h> for a list of keys and value types. Clients should not assume that the completion handler will be called on a specific thread. Calls to captureStillImageAsynchronouslyFromConnection:completionHandler: are not synchronized with AVCaptureDevice manual control completion handlers. Setting a device manual control, waiting for its completion, then calling captureStillImageAsynchronouslyFromConnection:completionHandler: DOES NOT ensure that the still image returned reflects your manual control change. It may be from an earlier time. You can compare your manual control completion handler sync time to the returned still image's presentation time. You can retrieve the sample buffer's pts using CMSampleBufferGetPresentationTimestamp(). If the still image has an earlier timestamp, your manual control command does not apply to it.

func (*AVCaptureStillImageOutput) Init ¶

func (*AVCaptureStillImageOutput) IsCapturingStillImage ¶

func (o *AVCaptureStillImageOutput) IsCapturingStillImage() bool

@property capturingStillImage @abstract A boolean value that becomes true when a still image is being captured. @discussion The value of this property is a BOOL that becomes true when a still image is being captured, and false when no still image capture is underway. This property is key-value observable.

func (*AVCaptureStillImageOutput) IsHighResolutionStillImageOutputEnabled ¶

func (o *AVCaptureStillImageOutput) IsHighResolutionStillImageOutputEnabled() bool

@property highResolutionStillImageOutputEnabled @abstract Indicates whether the receiver should emit still images at the highest resolution supported by its source AVCaptureDevice's activeFormat. @discussion By default, AVCaptureStillImageOutput emits images with the same dimensions as its source AVCaptureDevice's activeFormat.formatDescription. However, if you set this property to YES, the receiver emits still images at its source AVCaptureDevice's activeFormat.highResolutionStillImageDimensions. Note that if you enable video stabilization (see AVCaptureConnection's preferredVideoStabilizationMode) for any output, the high resolution still images emitted by AVCaptureStillImageOutput may be smaller by 10 or more percent.

func (*AVCaptureStillImageOutput) OutputSettings ¶

@property outputSettings @abstract Specifies the options the receiver uses to encode still images before they are delivered. @discussion See AVVideoSettings.h for more information on how to construct an output settings dictionary. On iOS, the only currently supported keys are AVVideoCodecKey and kCVPixelBufferPixelFormatTypeKey. Use -availableImageDataCVPixelFormatTypes and -availableImageDataCodecTypes to determine what codec keys and pixel formats are supported. AVVideoQualityKey is supported on iOS 6.0 and later and may only be used when AVVideoCodecKey is set to AVVideoCodecTypeJPEG.

func (*AVCaptureStillImageOutput) SetHighResolutionStillImageOutputEnabled ¶

func (o *AVCaptureStillImageOutput) SetHighResolutionStillImageOutputEnabled(highResolutionStillImageOutputEnabled bool)

func (*AVCaptureStillImageOutput) SetOutputSettings ¶

func (o *AVCaptureStillImageOutput) SetOutputSettings(outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID])

type AVCaptureSystemExposureBiasSlider ¶

type AVCaptureSystemExposureBiasSlider struct {
	AVCaptureControl
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturesystemexposurebiasslider

func AVCaptureSystemExposureBiasSliderFromID ¶

func AVCaptureSystemExposureBiasSliderFromID(id objc.ID) *AVCaptureSystemExposureBiasSlider

func (*AVCaptureSystemExposureBiasSlider) InitWithDevice ¶

@method initWithDevice: @abstract Initializes an `AVCaptureSystemExposureBiasSlider` for controlling `device`. @param device The device to control. @discussion `AVCaptureSystemExposureBiasSlider` may only be initialized with `AVCaptureDevice` instances that support setting `exposureTargetBias`, otherwise an `NSInvalidArgumentException` is thrown.

func (*AVCaptureSystemExposureBiasSlider) InitWithDeviceAction ¶

func (o *AVCaptureSystemExposureBiasSlider) InitWithDeviceAction(device *AVCaptureDevice, action func(float32)) *AVCaptureSystemExposureBiasSlider

@method initWithDevice:action @abstract Initializes an `AVCaptureSystemExposureBiasSlider` for controlling `device` with a `@MainActor` `action` for handling `exposureTargetBias` changes. @param device The device to control. @param action An action called on `@MainActor` to handle `exposureTargetBias` changes by `AVCaptureSystemExposureBiasSlider`. @discussion `action` is **only** called when `exposureTargetBias` is changed by this control. Clients should not change `exposureTargetBias` on the device when `action` is called. If you need to react to other sources of `exposureTargetBias` changes, you will still need to use key-value observation. `AVCaptureSystemExposureBiasSlider` may only be initialized with `AVCaptureDevice` instances that support setting `exposureTargetBias`, otherwise an `NSInvalidArgumentException` is thrown.

type AVCaptureSystemUserInterface ¶

type AVCaptureSystemUserInterface int64
const (
	AVCaptureSystemUserInterfaceVideoEffects    AVCaptureSystemUserInterface = 1
	AVCaptureSystemUserInterfaceMicrophoneModes AVCaptureSystemUserInterface = 2
)

func (AVCaptureSystemUserInterface) String ¶

type AVCaptureSystemZoomSlider ¶

type AVCaptureSystemZoomSlider struct {
	AVCaptureControl
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturesystemzoomslider

func AVCaptureSystemZoomSliderFromID ¶

func AVCaptureSystemZoomSliderFromID(id objc.ID) *AVCaptureSystemZoomSlider

func (*AVCaptureSystemZoomSlider) InitWithDevice ¶

@method initWithDevice: @abstract Initializes an `AVCaptureSystemZoomSlider` for controlling `device`. @param device The device to control. @discussion `AVCaptureSystemZoomSlider` may only be initialized with `AVCaptureDevice` instances that support setting `videoZoomFactor`, otherwise an `NSInvalidArgumentException` is thrown.

func (*AVCaptureSystemZoomSlider) InitWithDeviceAction ¶

func (o *AVCaptureSystemZoomSlider) InitWithDeviceAction(device *AVCaptureDevice, action func(float64)) *AVCaptureSystemZoomSlider

@method initWithDevice:action @abstract Initializes an `AVCaptureSystemZoomSlider` for controlling `device` with a `@MainActor` `action` for handling `videoZoomFactor` changes. @param device The device to control. @param action An action called on `@MainActor` to handle `videoZoomFactor` changes by `AVCaptureSystemZoomSlider`. @discussion `action` is **only** called when `videoZoomFactor` is changed by this control. Clients should not change `videoZoomFactor` on the device when `action` is called. If you need to react to other sources of `videoZoomFactor` changes like `rampToVideoZoomFactor:withRate:` you will still need to use key-value observation. `AVCaptureSystemZoomSlider` may only be initialized with `AVCaptureDevice` instances that support setting `videoZoomFactor`, otherwise an `NSInvalidArgumentException` is thrown.

type AVCaptureTimecode ¶

type AVCaptureTimecode struct {
	Hours         uint8
	Minutes       uint8
	Seconds       uint8
	Frames        uint8
	UserBits      uint32
	FrameDuration coremedia.CMTime
	SourceType    AVCaptureTimecodeSourceType
}

This structure represents a timecode, adhering to SMPTE standards, which define precise time information and associated timestamps for video or audio synchronization. This structure corresponds to the SMPTE 12M-1 Linear Timecode (LTC) format, widely used for professional video and audio synchronization.

func AVCaptureTimecodeAdvancedByFrames ¶

func AVCaptureTimecodeAdvancedByFrames(timecode AVCaptureTimecode, framesToAdd int64) AVCaptureTimecode

Generates a new timecode by adding a specified number of frames to the given timecode, handling overflow for seconds, minutes, and hours. - Parameter timecode: The original “AVCaptureTimecode“ to be incremented. - Parameter framesToAdd: The number of frames to add to the timecode. - Returns: A new “AVCaptureTimecode“ struct with the updated time values after adding the specified frames.

type AVCaptureTimecodeGenerator ¶

type AVCaptureTimecodeGenerator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturetimecodegenerator

func AVCaptureTimecodeGeneratorFromID ¶

func AVCaptureTimecodeGeneratorFromID(id objc.ID) *AVCaptureTimecodeGenerator

func (*AVCaptureTimecodeGenerator) AvailableSources ¶

An array of available timecode synchronization sources that can be used by the timecode generator. This property provides a list of “AVCaptureTimecodeSource“ objects representing the available timecode sources with which the generator can synchronize. The sources may include built-in options such as the frame counter and real-time clock, as well as dynamically detected sources such as connected MIDI or HID devices. This array is key-value observable, allowing you to monitor changes in real-time. For example, when a new MIDI device is connected, the array is updated to include the corresponding timecode source. - Returns: A read-only array of “AVCaptureTimecodeSource“ objects representing the available timecode synchronization sources.

func (*AVCaptureTimecodeGenerator) CurrentSource ¶

The active timecode source used by “AVCaptureTimecodeGenerator“ to maintain clock synchronization for accurate timecode generation. Indicates the active timecode source, as defined in the “AVCaptureTimecodeSynchronizationSourceType“ enum. If an “AVCaptureTimecodeGenerator“ becomes disconnected from its source, it continues generating timecodes using historical data from its ring buffer. This approach allows the generator to maintain synchronization during brief disruptions, as is common in cinema workflows where timecode signals may experience discontinuities.

func (*AVCaptureTimecodeGenerator) Delegate ¶

The delegate that receives timecode updates from the timecode generator. You can use your “delegate“ to receive real-time timecode updates. Implement the “timecodeGenerator:didReceiveUpdate:“ method in your delegate to handle updates.

func (*AVCaptureTimecodeGenerator) DelegateCallbackQueue ¶

func (o *AVCaptureTimecodeGenerator) DelegateCallbackQueue() *foundation.NSObject

The dispatch queue on which delegate callbacks are invoked. Provides the queue set in “setDelegate:queue:“. If no delegate is assigned, this property is `nil`.

func (*AVCaptureTimecodeGenerator) GenerateInitialTimecode ¶

func (o *AVCaptureTimecodeGenerator) GenerateInitialTimecode() AVCaptureTimecode

Generates an initial timecode intended to be the first in a sequence. - Returns: A populated “AVCaptureTimecode“ structure.

func (*AVCaptureTimecodeGenerator) SetDelegateQueue ¶

func (o *AVCaptureTimecodeGenerator) SetDelegateQueue(delegate AVCaptureTimecodeGeneratorDelegate, callbackQueue *foundation.NSObject)

Assigns a delegate to receive real-time timecode updates and specifies a queue for callbacks. - Parameter delegate: An object conforming to the “AVCaptureTimecodeGeneratorDelegate“ protocol. - Parameter callbackQueue: The dispatch queue on which the delegate methods are invoked. The `callbackQueue` parameter may not be `nil`, except when setting the “AVCaptureTimecodeGeneratorDelegate“ to `nil`, otherwise “setDelegate:queue:“ throws an `NSInvalidArgumentException`. Use this method to configure a delegate that handles timecode updates. The specified `queue` ensures thread-safe invocation of delegate methods.

func (*AVCaptureTimecodeGenerator) SetSynchronizationTimeout ¶

func (o *AVCaptureTimecodeGenerator) SetSynchronizationTimeout(synchronizationTimeout float64)

func (*AVCaptureTimecodeGenerator) SetTimecodeAlignmentOffset ¶

func (o *AVCaptureTimecodeGenerator) SetTimecodeAlignmentOffset(timecodeAlignmentOffset float64)

func (*AVCaptureTimecodeGenerator) SetTimecodeFrameDuration ¶

func (o *AVCaptureTimecodeGenerator) SetTimecodeFrameDuration(timecodeFrameDuration coremedia.CMTime)

func (*AVCaptureTimecodeGenerator) StartSynchronizationWithTimecodeSource ¶

func (o *AVCaptureTimecodeGenerator) StartSynchronizationWithTimecodeSource(source *AVCaptureTimecodeSource)

Synchronizes the generator with the specified timecode source. - Parameter source: The timecode source for synchronization.

func (*AVCaptureTimecodeGenerator) SynchronizationTimeout ¶

func (o *AVCaptureTimecodeGenerator) SynchronizationTimeout() float64

The maximum time interval allowed for source synchronization attempts before timing out. This property specifies the duration, in seconds, that the “AVCaptureTimecodeGenerator“ will attempt to synchronize with a timecode source before timing out if synchronization cannot be achieved. If this threshold is exceeded, the synchronization status updates to reflect a timeout, and your “AVCaptureTimecodeGeneratorDelegate/timecodeGenerator:transitionedToSynchronizationStatus:forSource:“ delegate method fires, informing you of the event. The default value is 15 seconds.

func (*AVCaptureTimecodeGenerator) TimecodeAlignmentOffset ¶

func (o *AVCaptureTimecodeGenerator) TimecodeAlignmentOffset() float64

The time offset, in seconds, applied to the generated timecode. This offset allows fine-tuning of time alignment for synchronization with external sources or to accommodate any intentional delay. The default value is 0 seconds.

func (*AVCaptureTimecodeGenerator) TimecodeFrameDuration ¶

func (o *AVCaptureTimecodeGenerator) TimecodeFrameDuration() coremedia.CMTime

The frame duration that the generator will use to generate timecodes.

type AVCaptureTimecodeGeneratorDelegate ¶

type AVCaptureTimecodeGeneratorDelegate interface {
	TimecodeGeneratorDidReceiveUpdateFromSource(generator *AVCaptureTimecodeGenerator, timecode AVCaptureTimecode, source *AVCaptureTimecodeSource)
	TimecodeGeneratorTransitionedToSynchronizationStatusForSource(generator *AVCaptureTimecodeGenerator, synchronizationStatus AVCaptureTimecodeGeneratorSynchronizationStatus, source *AVCaptureTimecodeSource)
	TimecodeGeneratorDidUpdateAvailableSources(generator *AVCaptureTimecodeGenerator, availableSources *foundation.NSArray[*AVCaptureTimecodeSource])
}

AVCaptureTimecodeGeneratorDelegate wraps the ObjC protocol AVCaptureTimecodeGeneratorDelegate.

type AVCaptureTimecodeGeneratorSynchronizationStatus ¶

type AVCaptureTimecodeGeneratorSynchronizationStatus int64
const (
	// The initial state before a source is selected or during error conditions.
	AVCaptureTimecodeGeneratorSynchronizationStatusUnknown AVCaptureTimecodeGeneratorSynchronizationStatus = 0
	// A timecode source has been selected, but synchronization has not yet started.
	AVCaptureTimecodeGeneratorSynchronizationStatusSourceSelected AVCaptureTimecodeGeneratorSynchronizationStatus = 1
	// The timecode generator is actively synchronizing to the selected source.
	AVCaptureTimecodeGeneratorSynchronizationStatusSynchronizing AVCaptureTimecodeGeneratorSynchronizationStatus = 2
	// The timecode generator is successfully synchronized to the selected source, maintaining active timing alignment.
	AVCaptureTimecodeGeneratorSynchronizationStatusSynchronized AVCaptureTimecodeGeneratorSynchronizationStatus = 3
	// The synchronization has timed out.
	AVCaptureTimecodeGeneratorSynchronizationStatusTimedOut AVCaptureTimecodeGeneratorSynchronizationStatus = 4
	// The timecode generator has failed to establish a connection with a given source.
	AVCaptureTimecodeGeneratorSynchronizationStatusSourceUnavailable AVCaptureTimecodeGeneratorSynchronizationStatus = 5
	// The timecode generator is receiving data from the source in an unrecognized format.
	AVCaptureTimecodeGeneratorSynchronizationStatusSourceUnsupported AVCaptureTimecodeGeneratorSynchronizationStatus = 6
	// The timecode generator does not require active synchronization for a given source.
	AVCaptureTimecodeGeneratorSynchronizationStatusNotRequired AVCaptureTimecodeGeneratorSynchronizationStatus = 7
)

func (AVCaptureTimecodeGeneratorSynchronizationStatus) String ¶

type AVCaptureTimecodeSource ¶

type AVCaptureTimecodeSource struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturetimecodesource

func AVCaptureTimecodeGeneratorFrameCountSource ¶

func AVCaptureTimecodeGeneratorFrameCountSource() *AVCaptureTimecodeSource

A frame counter timecode source that operates independently of any internal or external synchronization. This class property represents a standalone timecode source that advances based purely on frame count, independent of any real-time or external synchronization. It is ideal for scenarios where a simple, self-contained timing reference is sufficient, without requiring alignment to system clocks or external devices.

func AVCaptureTimecodeGeneratorRealTimeClockSource ¶

func AVCaptureTimecodeGeneratorRealTimeClockSource() *AVCaptureTimecodeSource

A predefined timecode source synchronized to the real-time system clock. This class property provides a default timecode source based on the real-time system clock, requiring no external device. It is ideal for live events or scenarios where alignment with the current time of day is necessary.

func AVCaptureTimecodeSourceFromID ¶

func AVCaptureTimecodeSourceFromID(id objc.ID) *AVCaptureTimecodeSource

func (*AVCaptureTimecodeSource) DisplayName ¶

func (o *AVCaptureTimecodeSource) DisplayName() *foundation.NSString

The name of the timecode source. This property provides a descriptive name of the timecode source, useful for display in user interfaces or logging.

func (*AVCaptureTimecodeSource) Type ¶

The type of timecode source. Indicates the type of timecode source, represented as a value from the “AVCaptureTimecodeSynchronizationSourceType“ enum. This helps you identify the source for specific synchronization use cases, such as frame counter, real-time clock, MIDI, or HID.

func (*AVCaptureTimecodeSource) Uuid ¶

A unique identifier for the timecode source. The UUID uniquely identifies this timecode source. It is particularly useful when multiple sources of the same type are available, allowing your application to distinguish between them. - Note: This value does not persist across application sessions.

type AVCaptureTimecodeSourceType ¶

type AVCaptureTimecodeSourceType int64
const (
	// No internal or external source is adopted. Timecodes are zero-based, sequentially generated frame counts.
	AVCaptureTimecodeSourceTypeFrameCount AVCaptureTimecodeSourceType = 0
	// Synchronizes timecode to the system clock for real-time applications. Useful for live events or scenarios requiring alignment with the actual time of day.
	AVCaptureTimecodeSourceTypeRealTimeClock AVCaptureTimecodeSourceType = 1
	// Synchronizes timecode to an external timecode data stream. Ideal for professional audio and video synchronization with external quarter-frame MIDI or HID timecode hardware.
	AVCaptureTimecodeSourceTypeExternal AVCaptureTimecodeSourceType = 2
)

func (AVCaptureTimecodeSourceType) String ¶

type AVCaptureTorchMode ¶

type AVCaptureTorchMode int64
const (
	AVCaptureTorchModeOff  AVCaptureTorchMode = 0
	AVCaptureTorchModeOn   AVCaptureTorchMode = 1
	AVCaptureTorchModeAuto AVCaptureTorchMode = 2
)

func (AVCaptureTorchMode) String ¶

func (e AVCaptureTorchMode) String() string

type AVCaptureVideoDataOutput ¶

type AVCaptureVideoDataOutput struct {
	AVCaptureOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturevideodataoutput

func AVCaptureVideoDataOutputFromID ¶

func AVCaptureVideoDataOutputFromID(id objc.ID) *AVCaptureVideoDataOutput

func AVCaptureVideoDataOutputNew ¶

func AVCaptureVideoDataOutputNew() *AVCaptureVideoDataOutput

func (*AVCaptureVideoDataOutput) AlwaysDiscardsLateVideoFrames ¶

func (o *AVCaptureVideoDataOutput) AlwaysDiscardsLateVideoFrames() bool

@property alwaysDiscardsLateVideoFrames @abstract Specifies whether the receiver should always discard any video frame that is not processed before the next frame is captured. @discussion When the value of this property is YES, the receiver will immediately discard frames that are captured while the dispatch queue handling existing frames is blocked in the captureOutput:didOutputSampleBuffer:fromConnection: delegate method. When the value of this property is NO, delegates will be allowed more time to process old frames before new frames are discarded, but application memory usage may increase significantly as a result. The default value is YES.

func (*AVCaptureVideoDataOutput) AvailableVideoCVPixelFormatTypes ¶

func (o *AVCaptureVideoDataOutput) AvailableVideoCVPixelFormatTypes() *foundation.NSArray[*foundation.NSNumber]

@property availableVideoCVPixelFormatTypes @abstract Indicates the supported video pixel formats that can be specified in videoSettings. @discussion The value of this property is an NSArray of NSNumbers that can be used as values for the kCVPixelBufferPixelFormatTypeKey in the receiver's videoSettings property. The formats are listed in an unspecified order. This list can may change if the activeFormat of the AVCaptureDevice connected to the receiver changes.

func (*AVCaptureVideoDataOutput) AvailableVideoCodecTypes ¶

func (o *AVCaptureVideoDataOutput) AvailableVideoCodecTypes() *foundation.NSArray[*foundation.NSString]

@property availableVideoCodecTypes @abstract Indicates the supported video codec formats that can be specified in videoSettings. @discussion The value of this property is an NSArray of AVVideoCodecTypes that can be used as values for the AVVideoCodecKey in the receiver's videoSettings property.

func (*AVCaptureVideoDataOutput) AvailableVideoCodecTypesForAssetWriterWithOutputFileType ¶

func (o *AVCaptureVideoDataOutput) AvailableVideoCodecTypesForAssetWriterWithOutputFileType(outputFileType *foundation.NSString) *foundation.NSArray[*foundation.NSString]

@method availableVideoCodecTypesForAssetWriterWithOutputFileType: @abstract Specifies the available video codecs for use with AVAssetWriter and a given file type. @param outputFileType Specifies the UTI of the file type to be written (see AVMediaFormat.h for a list of file format UTIs). @result An array of video codecs; see AVVideoSettings.h for a full list. @discussion This method allows you to query the available video codecs that may be used when specifying an AVVideoCodecKey in -recommendedVideoSettingsForVideoCodecType:assetWriterOutputFileType:. When specifying an outputFileType of AVFileTypeQuickTimeMovie, video codecs are ordered identically to -[AVCaptureMovieFileOutput availableVideoCodecTypes].

func (*AVCaptureVideoDataOutput) Init ¶

func (*AVCaptureVideoDataOutput) PreservesDynamicHDRMetadata ¶

func (o *AVCaptureVideoDataOutput) PreservesDynamicHDRMetadata() bool

Indicates whether the receiver should preserve dynamic HDR metadata as an attachment on the output sample buffer's underlying pixel buffer. Set this property to `true` if you wish to use “AVCaptureVideoDataOutput“ with “AVAssetWriter“ to record HDR movies. You must also set “kVTCompressionPropertyKey_PreserveDynamicHDRMetadata“ to `true` in the compression settings you pass to your “AVAssetWriterInput“. These compression settings are represented under the “AVVideoCompressionPropertiesKey“ sub-dictionary of your top-level AVVideoSettings (see <doc://com.apple.documentation/documentation/avfoundation/video-settings>). When you set this key to `true`, performance improves, as the encoder is able to skip HDR metadata calculation for every frame. The default value is `false`.

func (*AVCaptureVideoDataOutput) RecommendedMediaTimeScaleForAssetWriter ¶

func (o *AVCaptureVideoDataOutput) RecommendedMediaTimeScaleForAssetWriter() int32

Indicates the recommended media timescale for the video track. - Returns: The recommended media timescale based on the active capture session's inputs. It is never less than 600. It may or may not be a multiple of 600.

func (*AVCaptureVideoDataOutput) RecommendedMovieMetadataForVideoCodecTypeAssetWriterOutputFileType ¶

func (o *AVCaptureVideoDataOutput) RecommendedMovieMetadataForVideoCodecTypeAssetWriterOutputFileType(videoCodecType *foundation.NSString, outputFileType *foundation.NSString) *foundation.NSArray[*AVMetadataItem]

Recommends movie-level metadata for a particular video codec type and output file type, to be used with an asset writer input. - Parameter videoCodecType: The desired “AVVideoCodecKey“ to be used for compression (see <doc://com.apple.documentation/documentation/avfoundation/video-settings>). - Parameter outputFileType: Specifies the UTI of the file type to be written (see <doc://com.apple.documentation/documentation/avfoundation/avfiletype>). - Returns: A fully populated array of “AVMetadataItem“ objects compatible with “AVAssetWriter“. The value of this property is an array of “AVMetadataItem“ objects representing the collection of top-level metadata to be written in each output file. This array is suitable to use as the “AVAssetWriter/metadata“ property before you have called “AVAssetWriter/startWriting“. For more details see <doc://com.apple.documentation/documentation/avfoundation/avassetwriter/startwriting()>. The “videoCodecType“ string you provide must be present in “availableVideoCodecTypesForAssetWriterWithOutputFileType:“ array, or an `NSInvalidArgumentException` is thrown. For clients writing files using a ProRes Raw codec type, white balance must be locked (call “AVCaptureDevice/setWhiteBalanceModeLockedWithDeviceWhiteBalanceGains:completionHandler:“) before querying this property, or an `NSIvalidArgumentException` is thrown. - Note: The array of metadata is dependent on the current configuration of the receiver's “AVCaptureSession“ and its inputs. The array may change when the session's configuration changes. As such, you should configure and start your session first, then query this method.

func (*AVCaptureVideoDataOutput) RecommendedVideoSettingsForAssetWriterWithOutputFileType ¶

func (o *AVCaptureVideoDataOutput) RecommendedVideoSettingsForAssetWriterWithOutputFileType(outputFileType *foundation.NSString) *foundation.NSDictionary[*foundation.NSString, objc.ID]

@method recommendedVideoSettingsForAssetWriterWithOutputFileType: @abstract Specifies the recommended settings for use with an AVAssetWriterInput. @param outputFileType Specifies the UTI of the file type to be written (see AVMediaFormat.h for a list of file format UTIs). @result A fully populated dictionary of keys and values that are compatible with AVAssetWriter. @discussion The value of this property is an NSDictionary containing values for compression settings keys defined in AVVideoSettings.h. This dictionary is suitable for use as the "outputSettings" parameter when creating an AVAssetWriterInput, such as, [AVAssetWriterInput assetWriterInputWithMediaType:AVMediaTypeVideo outputSettings:outputSettings sourceFormatHint:hint]; The dictionary returned contains all necessary keys and values needed by AVAssetWriter (see AVAssetWriterInput.h, -initWithMediaType:outputSettings: for a more in depth discussion). For QuickTime movie and ISO file types, the recommended video settings will produce output comparable to that of AVCaptureMovieFileOutput. Note that the dictionary of settings is dependent on the current configuration of the receiver's AVCaptureSession and its inputs. The settings dictionary may change if the session's configuration changes. As such, you should configure your session first, then query the recommended video settings. As of iOS 8.3, movies produced with these settings successfully import into the iOS camera roll and sync to and from like devices via iTunes.

func (*AVCaptureVideoDataOutput) RecommendedVideoSettingsForVideoCodecTypeAssetWriterOutputFileType ¶

func (o *AVCaptureVideoDataOutput) RecommendedVideoSettingsForVideoCodecTypeAssetWriterOutputFileType(videoCodecType *foundation.NSString, outputFileType *foundation.NSString) *foundation.NSDictionary[*foundation.NSString, objc.ID]

@method recommendedVideoSettingsForVideoCodecType:assetWriterOutputFileType: @abstract Specifies the recommended settings for a particular video codec type, to be used with an AVAssetWriterInput. @param videoCodecType Specifies the desired AVVideoCodecKey to be used for compression (see AVVideoSettings.h). @param outputFileType Specifies the UTI of the file type to be written (see AVMediaFormat.h for a list of file format UTIs). @result A fully populated dictionary of keys and values that are compatible with AVAssetWriter. @discussion The value of this property is an NSDictionary containing values for compression settings keys defined in AVVideoSettings.h. This dictionary is suitable for use as the "outputSettings" parameter when creating an AVAssetWriterInput, such as, [AVAssetWriterInput assetWriterInputWithMediaType:AVMediaTypeVideo outputSettings:outputSettings sourceFormatHint:hint]; The dictionary returned contains all necessary keys and values needed by AVAssetWriter (see AVAssetWriterInput.h, -initWithMediaType:outputSettings: for a more in depth discussion). For QuickTime movie and ISO file types, the recommended video settings will produce output comparable to that of AVCaptureMovieFileOutput. The videoCodecType string provided must be present in the availableVideoCodecTypesForAssetWriterWithOutputFileType: array, or an NSInvalidArgumentException is thrown. Note that the dictionary of settings is dependent on the current configuration of the receiver's AVCaptureSession and its inputs. The settings dictionary may change if the session's configuration changes. As such, you should configure your session first, then query the recommended video settings. As of iOS 8.3, movies produced with these settings successfully import into the iOS camera roll and sync to and from like devices via iTunes.

func (*AVCaptureVideoDataOutput) RecommendedVideoSettingsForVideoCodecTypeAssetWriterOutputFileTypeOutputFileURL ¶

func (o *AVCaptureVideoDataOutput) RecommendedVideoSettingsForVideoCodecTypeAssetWriterOutputFileTypeOutputFileURL(videoCodecType *foundation.NSString, outputFileType *foundation.NSString, outputFileURL *foundation.NSURL) *foundation.NSDictionary[*foundation.NSString, objc.ID]

@method recommendedVideoSettingsForVideoCodecType:assetWriterOutputFileType:outputFileURL: @abstract Specifies the recommended settings for a particular video codec type with output file URL, to be used with an AVAssetWriterInput. @param videoCodecType Specifies the desired AVVideoCodecKey to be used for compression (see AVVideoSettings.h). @param outputFileType Specifies the UTI of the file type to be written (see AVMediaFormat.h for a list of file format UTIs). @param outputFileURL Specifies the output URL of the file to be written. If you wish to capture onto an external storage device get an externalStorageDevice of type AVExternalStorageDevice (as defined in AVExternalStorageDevice.h): [AVExternalStorageDeviceDiscoverySession sharedSession] externalStorageDevices] Then use [externalStorageDevice nextAvailableURLsWithPathExtensions:pathExtensions error:&error] to get the output file URL. @result A fully populated dictionary of keys and values that are compatible with AVAssetWriter. @discussion The value of this property is an NSDictionary containing values for compression settings keys defined in AVVideoSettings.h. This dictionary is suitable for use as the "outputSettings" parameter when creating an AVAssetWriterInput, such as, [AVAssetWriterInput assetWriterInputWithMediaType:AVMediaTypeVideo outputSettings:outputSettings sourceFormatHint:hint]; The dictionary returned contains all necessary keys and values needed by AVAssetWriter (see AVAssetWriterInput.h, -initWithMediaType:outputSettings: for a more in depth discussion). For QuickTime movie and ISO file types, the recommended video settings will produce output comparable to that of AVCaptureMovieFileOutput. The videoCodecType string provided must be present in the availableVideoCodecTypesForAssetWriterWithOutputFileType: array, or an NSInvalidArgumentException is thrown. Note that the dictionary of settings is dependent on the current configuration of the receiver's AVCaptureSession and its inputs. The settings dictionary may change if the session's configuration changes. As such, you should configure your session first, then query the recommended video settings. As of iOS 8.3, movies produced with these settings successfully import into the iOS camera roll and sync to and from like devices via iTunes.

func (*AVCaptureVideoDataOutput) SampleBufferCallbackQueue ¶

func (o *AVCaptureVideoDataOutput) SampleBufferCallbackQueue() *foundation.NSObject

@property sampleBufferCallbackQueue @abstract The dispatch queue on which all sample buffer delegate methods will be called. @discussion The value of this property is a dispatch_queue_t. The queue is set using the setSampleBufferDelegate:queue: method.

func (*AVCaptureVideoDataOutput) SampleBufferDelegate ¶

@property sampleBufferDelegate @abstract The receiver's delegate. @discussion The value of this property is an object conforming to the AVCaptureVideoDataOutputSampleBufferDelegate protocol that will receive sample buffers after they are captured. The delegate is set using the setSampleBufferDelegate:queue: method.

func (*AVCaptureVideoDataOutput) SetAlwaysDiscardsLateVideoFrames ¶

func (o *AVCaptureVideoDataOutput) SetAlwaysDiscardsLateVideoFrames(alwaysDiscardsLateVideoFrames bool)

func (*AVCaptureVideoDataOutput) SetPreservesDynamicHDRMetadata ¶

func (o *AVCaptureVideoDataOutput) SetPreservesDynamicHDRMetadata(preservesDynamicHDRMetadata bool)

func (*AVCaptureVideoDataOutput) SetSampleBufferDelegateQueue ¶

func (o *AVCaptureVideoDataOutput) SetSampleBufferDelegateQueue(sampleBufferDelegate AVCaptureVideoDataOutputSampleBufferDelegate, sampleBufferCallbackQueue *foundation.NSObject)

@method setSampleBufferDelegate:queue: @abstract Sets the receiver's delegate that will accept captured buffers and dispatch queue on which the delegate will be called. @param sampleBufferDelegate An object conforming to the AVCaptureVideoDataOutputSampleBufferDelegate protocol that will receive sample buffers after they are captured. @param sampleBufferCallbackQueue A dispatch queue on which all sample buffer delegate methods will be called. @discussion When a new video sample buffer is captured it will be vended to the sample buffer delegate using the captureOutput:didOutputSampleBuffer:fromConnection: delegate method. All delegate methods will be called on the specified dispatch queue. If the queue is blocked when new frames are captured, those frames will be automatically dropped at a time determined by the value of the alwaysDiscardsLateVideoFrames property. This allows clients to process existing frames on the same queue without having to manage the potential memory usage increases that would otherwise occur when that processing is unable to keep up with the rate of incoming frames. If their frame processing is consistently unable to keep up with the rate of incoming frames, clients should consider using the minFrameDuration property, which will generally yield better performance characteristics and more consistent frame rates than frame dropping alone. Clients that need to minimize the chances of frames being dropped should specify a queue on which a sufficiently small amount of processing is being done outside of receiving sample buffers. However, if such clients migrate extra processing to another queue, they are responsible for ensuring that memory usage does not grow without bound from frames that have not been processed. A serial dispatch queue must be used to guarantee that video frames will be delivered in order. The sampleBufferCallbackQueue parameter may not be NULL, except when setting the sampleBufferDelegate to nil otherwise -setSampleBufferDelegate:queue: throws an NSInvalidArgumentException.

func (*AVCaptureVideoDataOutput) SetVideoSettings ¶

func (o *AVCaptureVideoDataOutput) SetVideoSettings(videoSettings *foundation.NSDictionary[*foundation.NSString, objc.ID])

func (*AVCaptureVideoDataOutput) VideoSettings ¶

@property videoSettings @abstract Specifies the settings used to decode or re-encode video before it is output by the receiver. @discussion See AVVideoSettings.h for more information on how to construct a video settings dictionary. To receive samples in their device native format, set this property to an empty dictionary (i.e. [NSDictionary dictionary]). To receive samples in a default uncompressed format, set this property to nil. Note that after this property is set to nil, subsequent querying of this property will yield a non-nil dictionary reflecting the settings used by the AVCaptureSession's current sessionPreset. On iOS versions prior to iOS 16.0, the only supported key is kCVPixelBufferPixelFormatTypeKey. Use -availableVideoCVPixelFormatTypes for the list of supported pixel formats. For apps linked on or after iOS 16.0, kCVPixelBufferPixelFormatTypeKey, kCVPixelBufferWidthKey, and kCVPixelBufferHeightKey are supported. The width and height must match the videoOrientation specified on the output's AVCaptureConnection or an NSInvalidArgumentException is thrown. The aspect ratio of width and height must match the aspect ratio of the source's activeFormat (corrected for the connection's videoOrientation) or an NSInvalidArgumentException is thrown. If width or height exceeds the source's activeFormat's width or height, an NSInvalidArgumentException is thrown. Changing width and height when deliversPreviewSizedOutputBuffers is set to YES is not supported and throws an NSInvalidArgumentException.

type AVCaptureVideoDataOutputSampleBufferDelegate ¶

type AVCaptureVideoDataOutputSampleBufferDelegate interface {
}

AVCaptureVideoDataOutputSampleBufferDelegate wraps the ObjC protocol AVCaptureVideoDataOutputSampleBufferDelegate.

type AVCaptureVideoOrientation deprecated

type AVCaptureVideoOrientation int64

Deprecated: Use AVCaptureDeviceRotationCoordinator instead

const (
	AVCaptureVideoOrientationPortrait           AVCaptureVideoOrientation = 1
	AVCaptureVideoOrientationPortraitUpsideDown AVCaptureVideoOrientation = 2
	AVCaptureVideoOrientationLandscapeRight     AVCaptureVideoOrientation = 3
	AVCaptureVideoOrientationLandscapeLeft      AVCaptureVideoOrientation = 4
)

func (AVCaptureVideoOrientation) String ¶

func (e AVCaptureVideoOrientation) String() string

type AVCaptureVideoPreviewLayer ¶

type AVCaptureVideoPreviewLayer struct {
	quartzcore.CALayer
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcapturevideopreviewlayer

func AVCaptureVideoPreviewLayerFromID ¶

func AVCaptureVideoPreviewLayerFromID(id objc.ID) *AVCaptureVideoPreviewLayer

func AVCaptureVideoPreviewLayerLayerWithSession ¶

func AVCaptureVideoPreviewLayerLayerWithSession(session *AVCaptureSession) *AVCaptureVideoPreviewLayer

@method layerWithSession: @abstract Creates an AVCaptureVideoPreviewLayer for previewing the visual output of the specified AVCaptureSession. @param session The AVCaptureSession instance to be previewed. @result A newly initialized AVCaptureVideoPreviewLayer instance.

func AVCaptureVideoPreviewLayerLayerWithSessionWithNoConnection ¶

func AVCaptureVideoPreviewLayerLayerWithSessionWithNoConnection(session *AVCaptureSession) *AVCaptureVideoPreviewLayer

@method layerWithSessionWithNoConnection: @abstract Creates an AVCaptureVideoPreviewLayer for previewing the visual output of the specified AVCaptureSession, but creates no connections to any of the session's eligible video inputs. Only use this initializer if you intend to manually form a connection between a desired AVCaptureInputPort and the receiver using AVCaptureSession's -addConnection: method. @param session The AVCaptureSession instance to be previewed. @result A newly initialized AVCaptureVideoPreviewLayer instance.

func (*AVCaptureVideoPreviewLayer) CaptureDevicePointOfInterestForPoint ¶

func (o *AVCaptureVideoPreviewLayer) CaptureDevicePointOfInterestForPoint(pointInLayer corefoundation.CGPoint) corefoundation.CGPoint

@method captureDevicePointOfInterestForPoint: @abstract Converts a point in layer coordinates to a point of interest in the coordinate space of the capture device providing input to the layer. @param pointInLayer A CGPoint in layer coordinates. @result A CGPoint in the coordinate space of the capture device providing input to the layer. @discussion AVCaptureDevice pointOfInterest is expressed as a CGPoint where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This convenience method converts a point in the coordinate space of the receiver to a point of interest in the coordinate space of the AVCaptureDevice providing input to the receiver. The conversion takes frameSize and videoGravity into consideration.

func (*AVCaptureVideoPreviewLayer) Connection ¶

@property connection @abstract The AVCaptureConnection instance describing the AVCaptureInputPort to which the receiver is connected. @discussion When calling initWithSession: or setSession: with a valid AVCaptureSession instance, a connection is formed to the first eligible video AVCaptureInput. If the receiver is detached from a session, the connection property becomes nil.

func (*AVCaptureVideoPreviewLayer) InitWithSession ¶

@method initWithSession: @abstract Creates an AVCaptureVideoPreviewLayer for previewing the visual output of the specified AVCaptureSession. @param session The AVCaptureSession instance to be previewed. @result A newly initialized AVCaptureVideoPreviewLayer instance.

func (*AVCaptureVideoPreviewLayer) InitWithSessionWithNoConnection ¶

func (o *AVCaptureVideoPreviewLayer) InitWithSessionWithNoConnection(session *AVCaptureSession) *AVCaptureVideoPreviewLayer

@method initWithSessionWithNoConnection: @abstract Creates an AVCaptureVideoPreviewLayer for previewing the visual output of the specified AVCaptureSession, but creates no connections to any of the session's eligible video inputs. Only use this initializer if you intend to manually form a connection between a desired AVCaptureInputPort and the receiver using AVCaptureSession's -addConnection: method. @param session The AVCaptureSession instance to be previewed. @result A newly initialized AVCaptureVideoPreviewLayer instance.

func (*AVCaptureVideoPreviewLayer) IsDeferredStartEnabled ¶

func (o *AVCaptureVideoPreviewLayer) IsDeferredStartEnabled() bool

A `BOOL` value that indicates whether to defer starting this preview layer. When this value is `true`, the session does not prepare the output's resources until some time after “AVCaptureSession/startRunning“ returns. You can start the visual parts of your user interface (e.g. preview) prior to other parts (e.g. photo/movie capture, metadata output, etc..) to improve startup performance. Set this value to `false` if your app needs video preview immediately for startup, and `true` if it does not. By default, this value is `false` for “AVCaptureVideoPreviewLayer“ objects, since this object is used to display preview. For best session start performance, set “deferredStartEnabled“ to `false` for preview layers. If your app contains multiple preview layers, you may want to display the main preview layer as soon as possible and allow the remaining layers to display subsequently. In this case, set “deferredStartEnabled“ to `true` for the remaining layers. - Note: Setting this property to the same value for all outputs, including “AVCaptureVideoPreviewLayer“ and “AVCaptureOutput“, is equivalent to not using deferred start. If “deferredStartSupported“ is `false`, setting this property value to `true` results in the session throwing an `NSInvalidArgumentException`. - Note: Set this value before calling “AVCaptureSession/commitConfiguration“ as it requires a lengthy reconfiguration of the capture render pipeline.

func (*AVCaptureVideoPreviewLayer) IsDeferredStartSupported ¶

func (o *AVCaptureVideoPreviewLayer) IsDeferredStartSupported() bool

A `BOOL` value that indicates whether the preview layer supports deferred start. You can only set the “deferredStartEnabled“ property to `true` if the preview layer supports deferred start.

func (*AVCaptureVideoPreviewLayer) MetadataOutputRectOfInterestForRect ¶

func (o *AVCaptureVideoPreviewLayer) MetadataOutputRectOfInterestForRect(rectInLayerCoordinates corefoundation.CGRect) corefoundation.CGRect

@method metadataOutputRectOfInterestForRect: @abstract Converts a rectangle in layer coordinates to a rectangle of interest in the coordinate space of an AVCaptureMetadataOutput whose capture device is providing input to the layer. @param rectInLayerCoordinates A CGRect in layer coordinates. @result A CGRect in the coordinate space of the metadata output whose capture device is providing input to the layer. @discussion AVCaptureMetadataOutput rectOfInterest is expressed as a CGRect where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This convenience method converts a rectangle in the coordinate space of the receiver to a rectangle of interest in the coordinate space of an AVCaptureMetadataOutput whose AVCaptureDevice is providing input to the receiver. The conversion takes frame size and videoGravity into consideration.

func (*AVCaptureVideoPreviewLayer) PointForCaptureDevicePointOfInterest ¶

func (o *AVCaptureVideoPreviewLayer) PointForCaptureDevicePointOfInterest(captureDevicePointOfInterest corefoundation.CGPoint) corefoundation.CGPoint

@method pointForCaptureDevicePointOfInterest: @abstract Converts a point of interest in the coordinate space of the capture device providing input to the layer to a point in layer coordinates. @param captureDevicePointOfInterest A CGPoint in the coordinate space of the capture device providing input to the layer. @result A CGPoint in layer coordinates. @discussion AVCaptureDevice pointOfInterest is expressed as a CGPoint where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This convenience method converts a point in the coordinate space of the AVCaptureDevice providing input to the coordinate space of the receiver. The conversion takes frame size and videoGravity into consideration.

func (*AVCaptureVideoPreviewLayer) RectForMetadataOutputRectOfInterest ¶

func (o *AVCaptureVideoPreviewLayer) RectForMetadataOutputRectOfInterest(rectInMetadataOutputCoordinates corefoundation.CGRect) corefoundation.CGRect

@method rectForMetadataOutputRectOfInterest: @abstract Converts a rectangle of interest in the coordinate space of an AVCaptureMetadataOutput whose capture device is providing input to the layer to a rectangle in layer coordinates. @param rectInMetadataOutputCoordinates A CGRect in the coordinate space of the metadata output whose capture device is providing input to the layer. @result A CGRect in layer coordinates. @discussion AVCaptureMetadataOutput rectOfInterest is expressed as a CGRect where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. This convenience method converts a rectangle in the coordinate space of an AVCaptureMetadataOutput whose AVCaptureDevice is providing input to the coordinate space of the receiver. The conversion takes frame size and videoGravity into consideration.

func (*AVCaptureVideoPreviewLayer) Session ¶

@property session @abstract The AVCaptureSession instance being previewed by the receiver. @discussion The session is retained by the preview layer.

func (*AVCaptureVideoPreviewLayer) SetDeferredStartEnabled ¶

func (o *AVCaptureVideoPreviewLayer) SetDeferredStartEnabled(deferredStartEnabled bool)

func (*AVCaptureVideoPreviewLayer) SetSession ¶

func (o *AVCaptureVideoPreviewLayer) SetSession(session *AVCaptureSession)

func (*AVCaptureVideoPreviewLayer) SetSessionWithNoConnection ¶

func (o *AVCaptureVideoPreviewLayer) SetSessionWithNoConnection(session *AVCaptureSession)

method setSessionWithNoConnection: @abstract Attaches the receiver to a given session without implicitly forming a connection to the first eligible video AVCaptureInputPort. Only use this setter if you intend to manually form a connection between a desired AVCaptureInputPort and the receiver using AVCaptureSession's -addConnection: method. @discussion The session is retained by the preview layer.

func (*AVCaptureVideoPreviewLayer) SetVideoGravity ¶

func (o *AVCaptureVideoPreviewLayer) SetVideoGravity(videoGravity *foundation.NSString)

func (*AVCaptureVideoPreviewLayer) TransformedMetadataObjectForMetadataObject ¶

func (o *AVCaptureVideoPreviewLayer) TransformedMetadataObjectForMetadataObject(metadataObject *AVMetadataObject) *AVMetadataObject

@method transformedMetadataObjectForMetadataObject: @abstract Converts an AVMetadataObject's visual properties to layer coordinates. @param metadataObject An AVMetadataObject originating from the same AVCaptureInput as the preview layer. @result An AVMetadataObject whose properties are in layer coordinates. @discussion AVMetadataObject bounds may be expressed as a rect where {0,0} represents the top left of the picture area, and {1,1} represents the bottom right on an unrotated picture. Face metadata objects likewise express yaw and roll angles with respect to an unrotated picture. -transformedMetadataObjectForMetadataObject: converts the visual properties in the coordinate space of the supplied AVMetadataObject to the coordinate space of the receiver. The conversion takes orientation, mirroring, layer bounds and videoGravity into consideration. If the provided metadata object originates from an input source other than the preview layer's, nil will be returned.

func (*AVCaptureVideoPreviewLayer) VideoGravity ¶

func (o *AVCaptureVideoPreviewLayer) VideoGravity() *foundation.NSString

@property videoGravity @abstract A string defining how the video is displayed within an AVCaptureVideoPreviewLayer bounds rect. @discussion Options are AVLayerVideoGravityResize, AVLayerVideoGravityResizeAspect and AVLayerVideoGravityResizeAspectFill. AVLayerVideoGravityResizeAspect is default. See <AVFoundation/AVAnimation.h> for a description of these options.

type AVCaptureWhiteBalanceChromaticityValues ¶

type AVCaptureWhiteBalanceChromaticityValues struct {
	X float32
	Y float32
}

@typedef AVCaptureWhiteBalanceChromaticityValues @abstract Structure containing CIE 1931 xy chromaticity values.

type AVCaptureWhiteBalanceGains ¶

type AVCaptureWhiteBalanceGains struct {
	RedGain   float32
	GreenGain float32
	BlueGain  float32
}

@typedef AVCaptureWhiteBalanceGains @abstract Structure containing RGB white balance gain values.

type AVCaptureWhiteBalanceMode ¶

type AVCaptureWhiteBalanceMode int64
const (
	AVCaptureWhiteBalanceModeLocked                     AVCaptureWhiteBalanceMode = 0
	AVCaptureWhiteBalanceModeAutoWhiteBalance           AVCaptureWhiteBalanceMode = 1
	AVCaptureWhiteBalanceModeContinuousAutoWhiteBalance AVCaptureWhiteBalanceMode = 2
)

func (AVCaptureWhiteBalanceMode) String ¶

func (e AVCaptureWhiteBalanceMode) String() string

type AVCaptureWhiteBalanceTemperatureAndTintValues ¶

type AVCaptureWhiteBalanceTemperatureAndTintValues struct {
	Temperature float32
	Tint        float32
}

@typedef AVCaptureWhiteBalanceTemperatureAndTintValues @abstract Structure containing a white balance color correlated temperature in kelvin, plus a tint value in the range of [-150 - +150].

type AVComposition ¶

type AVComposition struct {
	AVAsset
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcomposition

func AVCompositionFromID ¶

func AVCompositionFromID(id objc.ID) *AVComposition

func (*AVComposition) URLAssetInitializationOptions ¶

func (o *AVComposition) URLAssetInitializationOptions() *foundation.NSDictionary[*foundation.NSString, objc.ID]

@property URLAssetInitializationOptions @abstract Specifies the initialization options for the creation of AVURLAssets by the receiver, e.g. AVURLAssetPreferPreciseDurationAndTimingKey. The default behavior for creation of AVURLAssets by an AVComposition is equivalent to the behavior of +[AVURLAsset URLAssetWithURL:options:] when specifying no initialization options. @discussion AVCompositions create AVURLAssets internally for URLs specified by AVCompositionTrackSegments of AVCompositionTracks, as needed, whenever AVCompositionTrackSegments were originally added to a track via -[AVMutableCompositionTrack setSegments:] rather than by inserting timeranges of already existing AVAssets or AVAssetTracks. The value of URLAssetInitializationOptions can be specified at the time an AVMutableComposition is created via +compositionWithURLAssetInitializationOptions:.

type AVCompositionTrack ¶

type AVCompositionTrack struct {
	AVAssetTrack
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcompositiontrack

func AVCompositionTrackFromID ¶

func AVCompositionTrackFromID(id objc.ID) *AVCompositionTrack

func (*AVCompositionTrack) FormatDescriptionReplacements ¶

@property formatDescriptionReplacements @abstract An array of AVCompositionTrackFormatDescriptionReplacement objects indicating original format descriptions and their replacements. @discussion The value of this property is an array of AVCompositionTrackFormatDescriptionReplacement objects, each of which specifies an original format description together with its replacement format description (as specified by a previous call to -replaceFormatDescription:withFormatDescription:). Only format descriptions that are to be replaced will occur as the originalFormatDescription elements in the AVCompositionTrackFormatDescriptionReplacement objects in this array.

type AVCompositionTrackFormatDescriptionReplacement ¶

type AVCompositionTrackFormatDescriptionReplacement struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcompositiontrackformatdescriptionreplacement

func AVCompositionTrackFormatDescriptionReplacementFromID ¶

func AVCompositionTrackFormatDescriptionReplacementFromID(id objc.ID) *AVCompositionTrackFormatDescriptionReplacement

func (*AVCompositionTrackFormatDescriptionReplacement) OriginalFormatDescription ¶

func (o *AVCompositionTrackFormatDescriptionReplacement) OriginalFormatDescription() unsafe.Pointer

@property originalFormatDescription @abstract The original format description.

func (*AVCompositionTrackFormatDescriptionReplacement) ReplacementFormatDescription ¶

func (o *AVCompositionTrackFormatDescriptionReplacement) ReplacementFormatDescription() unsafe.Pointer

@property replacementFormatDescription @abstract The replacement format description.

type AVCompositionTrackSegment ¶

type AVCompositionTrackSegment struct {
	AVAssetTrackSegment
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcompositiontracksegment

func AVCompositionTrackSegmentCompositionTrackSegmentWithTimeRange ¶

func AVCompositionTrackSegmentCompositionTrackSegmentWithTimeRange(timeRange coremedia.CMTimeRange) *AVCompositionTrackSegment

@method compositionTrackSegmentWithTimeRange: @abstract Returns an instance of AVCompositionTrackSegment that presents an empty track segment. @param timeRange The timeRange of the empty AVCompositionTrackSegment. @result An instance of AVCompositionTrackSegment.

func AVCompositionTrackSegmentCompositionTrackSegmentWithURLTrackIDSourceTimeRangeTargetTimeRange ¶

func AVCompositionTrackSegmentCompositionTrackSegmentWithURLTrackIDSourceTimeRangeTargetTimeRange(uRL *foundation.NSURL, trackID int32, sourceTimeRange coremedia.CMTimeRange, targetTimeRange coremedia.CMTimeRange) *AVCompositionTrackSegment

@method compositionTrackSegmentWithURL:trackID:sourceTimeRange:targetTimeRange: @abstract Returns an instance of AVCompositionTrackSegment that presents a portion of a file referenced by URL. @param URL An instance of NSURL that references the container file to be presented by the AVCompositionTrackSegment. @param trackID The track identifier that specifies the track of the container file to be presented by the AVCompositionTrackSegment. @param sourceTimeRange The timeRange of the track of the container file to be presented by the AVCompositionTrackSegment. @param targetTimeRange The timeRange of the composition track during which the AVCompositionTrackSegment is to be presented. @result An instance of AVCompositionTrackSegment. @discussion To specify that the segment be played at the asset's normal rate, set source.duration == target.duration in the timeMapping. Otherwise, the segment will be played at a rate equal to the ratio source.duration / target.duration.

func AVCompositionTrackSegmentFromID ¶

func AVCompositionTrackSegmentFromID(id objc.ID) *AVCompositionTrackSegment

func (*AVCompositionTrackSegment) InitWithTimeRange ¶

@method initWithTimeRange: @abstract Initializes an instance of AVCompositionTrackSegment that presents an empty track segment. @param timeRange The timeRange of the empty AVCompositionTrackSegment. @result An instance of AVCompositionTrackSegment.

func (*AVCompositionTrackSegment) InitWithURLTrackIDSourceTimeRangeTargetTimeRange ¶

func (o *AVCompositionTrackSegment) InitWithURLTrackIDSourceTimeRangeTargetTimeRange(uRL *foundation.NSURL, trackID int32, sourceTimeRange coremedia.CMTimeRange, targetTimeRange coremedia.CMTimeRange) *AVCompositionTrackSegment

@method initWithURL:trackID:sourceTimeRange:targetTimeRange: @abstract Initializes an instance of AVCompositionTrackSegment that presents a portion of a file referenced by URL. @param URL An instance of NSURL that references the container file to be presented by the AVCompositionTrackSegment. @param trackID The track identifier that specifies the track of the container file to be presented by the AVCompositionTrackSegment. @param sourceTimeRange The timeRange of the track of the container file to be presented by the AVCompositionTrackSegment. @param targetTimeRange The timeRange of the composition track during which the AVCompositionTrackSegment is to be presented. @result An instance of AVCompositionTrackSegment. @discussion To specify that the segment be played at the asset's normal rate, set source.duration == target.duration in the timeMapping. Otherwise, the segment will be played at a rate equal to the ratio source.duration / target.duration.

func (*AVCompositionTrackSegment) SourceTrackID ¶

func (o *AVCompositionTrackSegment) SourceTrackID() int32

func (*AVCompositionTrackSegment) SourceURL ¶

func (o *AVCompositionTrackSegment) SourceURL() *foundation.NSURL

type AVContentAuthorizationStatus ¶

type AVContentAuthorizationStatus int64
const (
	AVContentAuthorizationUnknown      AVContentAuthorizationStatus = 0
	AVContentAuthorizationCompleted    AVContentAuthorizationStatus = 1
	AVContentAuthorizationCancelled    AVContentAuthorizationStatus = 2
	AVContentAuthorizationTimedOut     AVContentAuthorizationStatus = 3
	AVContentAuthorizationBusy         AVContentAuthorizationStatus = 4
	AVContentAuthorizationNotAvailable AVContentAuthorizationStatus = 5
	AVContentAuthorizationNotPossible  AVContentAuthorizationStatus = 6
)

func (AVContentAuthorizationStatus) String ¶

type AVContentKey ¶

type AVContentKey struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcontentkey

func AVContentKeyFromID ¶

func AVContentKeyFromID(id objc.ID) *AVContentKey

func (*AVContentKey) ContentKeySpecifier ¶

func (o *AVContentKey) ContentKeySpecifier() *AVContentKeySpecifier

Specifies the content key.

func (*AVContentKey) ExternalContentProtectionStatus ¶

func (o *AVContentKey) ExternalContentProtectionStatus() AVExternalContentProtectionStatus

The external protection status for the AVContentKey based on all attached displays. This property is not key-value observable, instead the contentKeySession:externalProtectionStatusDidChangeForContentKey: delegate method should be used.

func (*AVContentKey) Revoke ¶

func (o *AVContentKey) Revoke()

Revokes the decryption context of the content key, and removes it from its associated AVContentKeySession. Once revoked, the AVContentKey is no longer eligible to be used with any media. If the key is required again, or if the key is requested to be loaded by the application, a new AVContentKeyRequest will be dispatched to the delegate. If there is media playback occurring which is dependent on the content key it will fail and may result in an error being generated with the playback halting.

type AVContentKeyRecipient ¶

type AVContentKeyRecipient interface {
	MayRequireContentKeysForMediaDataProcessing() bool
}

AVContentKeyRecipient wraps the ObjC protocol AVContentKeyRecipient.

type AVContentKeyRequest ¶

type AVContentKeyRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcontentkeyrequest

func AVContentKeyRequestFromID ¶

func AVContentKeyRequestFromID(id objc.ID) *AVContentKeyRequest

func (*AVContentKeyRequest) CanProvidePersistableContentKey ¶

func (o *AVContentKeyRequest) CanProvidePersistableContentKey() bool

When the value of this property is YES, you can use the method -persistableContentKeyFromKeyVendorResponse:options:error: to create a persistable content key from the content key response. The value of this property will be YES only when the receiver is provided to your AVContentKeySession delegate via the method -contentKeySession:didProvidePersistableContentKeyRequest:. If you have an AVContentKeyRequest for which the value of canProvidePersistableContentKey is NO, but you wish to obtain a persistable content key, send the AVContentKeyRequest the message -respondByRequestingPersistableContentKeyRequest.

func (*AVContentKeyRequest) ContentKey ¶

func (o *AVContentKeyRequest) ContentKey() *AVContentKey

Represents an AVContentKey that results from an invocation of -processContentKeyResponse:. Before the receiver achieves the status AVContentKeyRequestReceivedResponse, the value of this property will be nil. Once that status has been achieved, the value of this property becomes a non-nil AVContentKey that can be provided to content key recipients that apply content keys manually to objects that require them, such as CMSampleBuffers, or to initiate renewal. A non-nil value does not indicate that the content key is valid; authorization failures may yet be possible.

func (*AVContentKeyRequest) ContentKeySpecifier ¶

func (o *AVContentKeyRequest) ContentKeySpecifier() *AVContentKeySpecifier

Specifies the requested content key.

func (*AVContentKeyRequest) Error ¶

func (o *AVContentKeyRequest) Error() unsafe.Pointer

If the receiver's status is AVContentKeyRequestStatusFailed, this describes the error that caused the failure. The value of this property is an NSError that describes what caused the content key request to fail. If the receiver's status is not AVContentKeyRequestStatusFailed, the value of this property is nil.

func (*AVContentKeyRequest) Identifier ¶

func (o *AVContentKeyRequest) Identifier() objc.ID

Container- and protocol-specific identifier for the content key. In order to use a key with an HTTP Live Streaming AVURLAsset, the identifier must be an NSURL that matches a key URI in the Media Playlist.

func (*AVContentKeyRequest) InitializationData ¶

func (o *AVContentKeyRequest) InitializationData() *foundation.NSData

func (*AVContentKeyRequest) MakeStreamingContentKeyRequestDataForAppContentIdentifierOptionsCompletionHandler ¶

func (o *AVContentKeyRequest) MakeStreamingContentKeyRequestDataForAppContentIdentifierOptionsCompletionHandler(appIdentifier *foundation.NSData, contentIdentifier *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID], handler func(*foundation.NSData, unsafe.Pointer))

Obtains a content key request data for a specific combination of application and content. If option AVContentKeyRequestProtocolVersionsKey is not specified the default protocol version of 1 is assumed. - Parameter appIdentifier: An opaque identifier for the application. The value of this identifier depends on the particular system used to provide the content key. - Parameter contentIdentifier: An optional opaque identifier for the content. The value of this identifier depends on the particular system used to provide the content key. - Parameter options: Additional information necessary to obtain the key, or nil if none. See AVContentKeyRequest*Key below. - Parameter handler: Once the streaming content key request is prepared, this block will be called with the request data or an error describing the failure.

func (*AVContentKeyRequest) Options ¶

Additional information specified while initiaing key loading using -processContentKeyRequestWithIdentifier:initializationData:options:.

func (*AVContentKeyRequest) OriginatingRecipient ¶

func (o *AVContentKeyRequest) OriginatingRecipient() AVContentKeyRecipient

The AVContentKeyRecipient which initiated this request, if any. The originatingRecipient is an AVFoundation object responsible for initiating an AVContentKeyRequest. For example, an AVURLAsset used for playback can trigger an AVContentKeyRequest. If an application triggers key loading directly, for example with -[AVContentKeySession processContentKeyRequestWithIdentifier:initializationData:options:], the value of originatingRecipient will be nil. The originatingRecipient of key requests from HLS interstitials will always be the corresponding interstitial AVURLAsset. To receive key requests for DRM-protected interstitial content, applications must ensure their AVContentKeySession is attached to these interstitial AVURLAssets. These interstitial AVURLAssets may be retrieved from the primary AVURLAsset via AVPlayerInterstitialEventMonitor.

func (*AVContentKeyRequest) ProcessContentKeyResponse ¶

func (o *AVContentKeyRequest) ProcessContentKeyResponse(keyResponse *AVContentKeyResponse)

Informs the receiver to process the specified content key response. After you receive an AVContentKeyRequest via -contentKeySession:didProvideContentKeyRequest: and after you invoke -[AVContentKeyRequest makeStreamingContentKeyRequestDataForApp:contentIdentifier:options:completionHandler:] on that request, you must obtain a response to the request in accordance with the protocol in use by the entity that controls the use of the media data. This is the method you use to provide the content key response to make protected content available for processing. If obtaining the content key response fails, use -processContentKeyResponseError:. - Parameter keyResponse: An instance of AVContentKeyResponse carrying a response to a content key request.

func (*AVContentKeyRequest) ProcessContentKeyResponseError ¶

func (o *AVContentKeyRequest) ProcessContentKeyResponseError(error_ unsafe.Pointer)

Informs the receiver that obtaining a content key response has failed, resulting in failure handling. - Parameter error: An instance of NSError that describes the specific failure that occurred.

func (*AVContentKeyRequest) RenewsExpiringResponseData ¶

func (o *AVContentKeyRequest) RenewsExpiringResponseData() bool

func (*AVContentKeyRequest) RespondByRequestingPersistableContentKeyRequestAndReturnError ¶

func (o *AVContentKeyRequest) RespondByRequestingPersistableContentKeyRequestAndReturnError() (bool, error)

Informs the receiver to process a persistable content key request. When you receive an AVContentKeyRequest via -contentKeySession:didProvideContentKeyRequest: and you want the resulting key response to produce a key that can persist across multiple playback sessions, you must invoke -respondByRequestingPersistableContentKeyRequest on that AVContentKeyRequest in order to signal that you want to process an AVPersistableContentKeyRequest instead. If the underlying protocol supports persistable content keys, in response your delegate will receive an AVPersistableContentKeyRequest via -contentKeySession:didProvidePersistableContentKeyRequest:. NSInternalInconsistencyException will be raised, if you are attempting to create and use a persistable key but your AVContentKeySession delegate does not respond to contentKeySession:didProvidePersistableContentKeyRequest:. - Parameter outError: The error returned if a persistable content key request cannot be requested. - Returns: YES if sucessful. If NO, this request should be responded to via processContentKeyResponse: or processContentKeyResponseError:.

func (*AVContentKeyRequest) Status ¶

This describes the state of the AVContentKeyRequest, value is one of AVContentKeyRequestStatus.

type AVContentKeyRequestStatus ¶

type AVContentKeyRequestStatus int64
const (
	// Indicates that the request has just been created.
	AVContentKeyRequestStatusRequestingResponse AVContentKeyRequestStatus = 0
	// Indicates that a response to a key reequest was received and key is in use. This does not indicate that the key is valid.
	AVContentKeyRequestStatusReceivedResponse AVContentKeyRequestStatus = 1
	// Indicates that the key request was renewed. This does not indicate that the key is valid.
	AVContentKeyRequestStatusRenewed AVContentKeyRequestStatus = 2
	// Indicates that the key request was retried.
	AVContentKeyRequestStatusRetried AVContentKeyRequestStatus = 3
	// Indicates that the key request was cancelled.
	AVContentKeyRequestStatusCancelled AVContentKeyRequestStatus = 4
	// Indicates that the request has encountered an error. See also the error property.
	AVContentKeyRequestStatusFailed AVContentKeyRequestStatus = 5
)

func (AVContentKeyRequestStatus) String ¶

func (e AVContentKeyRequestStatus) String() string

type AVContentKeyResponse ¶

type AVContentKeyResponse struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcontentkeyresponse

func AVContentKeyResponseContentKeyResponseWithAuthorizationTokenData ¶

func AVContentKeyResponseContentKeyResponseWithAuthorizationTokenData(authorizationTokenData *foundation.NSData) *AVContentKeyResponse

Create an AVContentKeyResponse from authorization token data when using AVContentKeySystemAuthorizationToken key system. The object created by this method is typically used with an AVContentKeyRequest created by an AVContentKeySession using keySystem AVContentKeySystemAuthorizationToken. It is passed to AVContentKeyRequest -processContentKeyResponse: in order to supply the authorization token data. - Parameter authorizationTokenData: Data blob containing the authorization token. - Returns: A new AVContentKeyResponse holding the authorization token data.

func AVContentKeyResponseContentKeyResponseWithClearKeyDataInitializationVector ¶

func AVContentKeyResponseContentKeyResponseWithClearKeyDataInitializationVector(keyData *foundation.NSData, initializationVector *foundation.NSData) *AVContentKeyResponse

Create an AVContentKeyResponse from the key and IV when using AVContentKeySystemClearKey as the key system The object created by this method is typically used with an AVContentKeyRequest created by an AVContentKeySession using keySystem AVContentKeySystemClearKey. It is passed to AVContentKeyRequest -processContentKeyResponse: in order to supply the decryptor with key data. - Parameter keyData: The key used for decrypting content. - Parameter initializationVector: The initialization vector used for decrypting content, or nil if initialization vector is available in the media to be decrypted - Returns: A new AVContentKeyResponse holding Clear Key data.

func AVContentKeyResponseContentKeyResponseWithFairPlayStreamingKeyResponseData ¶

func AVContentKeyResponseContentKeyResponseWithFairPlayStreamingKeyResponseData(keyResponseData *foundation.NSData) *AVContentKeyResponse

Create an AVContentKeyResponse from the server response to a key request made when using FairPlayStreaming (FPS) as the method of key delivery. The object created by this method is typically used with an AVContentKeyRequest created by an AVContentKeySession using keySystem AVContentKeySystemFairPlayStreaming. It is passed to AVContentKeyRequest -processContentKeyResponse: in order to supply the decryptor with key data - Parameter keyResponseData: The response from the FairPlayStreaming key server - Returns: A new AVContentKeyResponse holding data from a FairPlayStreaming key server that is used to decrypt the content

func AVContentKeyResponseFromID ¶

func AVContentKeyResponseFromID(id objc.ID) *AVContentKeyResponse

type AVContentKeySession ¶

type AVContentKeySession struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcontentkeysession

func AVContentKeySessionContentKeySessionWithKeySystem ¶

func AVContentKeySessionContentKeySessionWithKeySystem(keySystem *foundation.NSString) *AVContentKeySession

Creates a new instance of AVContentKeySession to manage a collection of media content keys. This method returns an AVContentKeySession instance that is capable of managing collection of media content keys corresponding to the input keySystem. An NSInvalidArgumentException will be raised if the value of keySystem is unsupported. - Parameter keySystem: A valid key system for retrieving keys. - Returns: A new AVContentKeySession.

func AVContentKeySessionContentKeySessionWithKeySystemStorageDirectoryAtURL ¶

func AVContentKeySessionContentKeySessionWithKeySystemStorageDirectoryAtURL(keySystem *foundation.NSString, storageURL *foundation.NSURL) *AVContentKeySession

Creates a new instance of AVContentKeySession to manage a collection of media content keys. This method returns an AVContentKeySession instance that is capable of managing collection of media content keys corresponding to the input keySystem. An NSInvalidArgumentException will be raised if the value of keySystem is unsupported. - Parameter keySystem: A valid key system for retrieving keys. - Parameter storageURL: URL to a writable directory that the session will use to facilitate expired session reports after abnormal session termination. - Returns: A new AVContentKeySession.

func AVContentKeySessionFromID ¶

func AVContentKeySessionFromID(id objc.ID) *AVContentKeySession

func (*AVContentKeySession) AddContentKeyRecipient ¶

func (o *AVContentKeySession) AddContentKeyRecipient(recipient AVContentKeyRecipient)

Informs the receiver that the specified recipient will be used for the session. It is an error to add recipient to sessions that have received an expire message. It is also an error to add recipients after they have already begun to process media data (e.g. after an AVURLAsset has loaded the values of any of its keys). Such errors will result in NSInternalInconsistencyExceptions. Sending this message to an AVContentKeySession is atomic.

func (*AVContentKeySession) ContentKeyRecipients ¶

func (o *AVContentKeySession) ContentKeyRecipients() *foundation.NSArray[AVContentKeyRecipient]

func (*AVContentKeySession) ContentProtectionSessionIdentifier ¶

func (o *AVContentKeySession) ContentProtectionSessionIdentifier() *foundation.NSData

An opaque identifier for the current content protection session. May be nil. Will call the delegate's contentKeySessionContentProtectionSessionIdentifierDidChange: when the identifier changes. The protection session ID is a unique string identifier generated by the AVContentKeySession that can be used by the application to identify content key session objects.

func (*AVContentKeySession) Delegate ¶

The receiver's delegate. The value of this property is an object conforming to the AVContentKeySessionDelegate protocol. The delegate is set using the setDelegate:queue: method.

func (*AVContentKeySession) DelegateQueue ¶

func (o *AVContentKeySession) DelegateQueue() *foundation.NSObject

The dispatch queue on which all delegate methods will be invoked whenever processes requiring content keys are executed asynchronously. The value of this property is a dispatch_queue_t. The queue is set using the setDelegate:queue: method.

func (*AVContentKeySession) Expire ¶

func (o *AVContentKeySession) Expire()

Tells the receiver to treat the session as having been intentionally and normally expired. When an instance of AVContentKeySession receives an expire message, all of its associated objects conforming to the AVContentKeyRecipient protocol will become inoperable. Send this message only after you have finished operating on the media data.

func (*AVContentKeySession) InvalidateAllPersistableContentKeysForAppOptionsCompletionHandler ¶

func (o *AVContentKeySession) InvalidateAllPersistableContentKeysForAppOptionsCompletionHandler(appIdentifier *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID], handler func(*foundation.NSData, unsafe.Pointer))

Invalidates all persistable content keys associated with the application and creates a secure server playback context (SPC) that the client could send to the key server to verify the outcome of invalidation request. Once invalidated, persistable content keys cannot be used to answer key requests during later playback sessions. - Parameter appIdentifier: An opaque identifier for the application. The contents of this identifier depend on the particular protocol in use by the entity that controls the use of the media data. - Parameter options: Additional information necessary to generate the server playback context, or nil if none. See AVContentKeySessionServerPlaybackContextOption for supported options. - Parameter handler: Once the server playback context is ready, this block will be called with the data or an error describing the failure.

func (*AVContentKeySession) InvalidatePersistableContentKeyOptionsCompletionHandler ¶

func (o *AVContentKeySession) InvalidatePersistableContentKeyOptionsCompletionHandler(persistableContentKeyData *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID], handler func(*foundation.NSData, unsafe.Pointer))

Invalidates the persistable content key and creates a secure server playback context (SPC) that the client could send to the key server to verify the outcome of invalidation request. Once invalidated, a persistable content key cannot be used to answer key requests during later playback sessions. - Parameter persistableContentKeyData: Persistable content key data that was previously created using -[AVContentKeyRequest persistableContentKeyFromKeyVendorResponse:options:error:] or obtained via AVContentKeySessionDelegate callback -contentKeySession:didUpdatePersistableContentKey:forContentKeyIdentifier:. - Parameter options: Additional information necessary to generate the server playback context, or nil if none. See AVContentKeySessionServerPlaybackContextOption for supported options. - Parameter handler: Once the server playback context is ready, this block will be called with the data or an error describing the failure.

func (*AVContentKeySession) KeySystem ¶

func (o *AVContentKeySession) KeySystem() *foundation.NSString

The key system used for retrieving keys

func (*AVContentKeySession) MakeSecureTokenForExpirationDateOfPersistableContentKeyCompletionHandler ¶

func (o *AVContentKeySession) MakeSecureTokenForExpirationDateOfPersistableContentKeyCompletionHandler(persistableContentKeyData *foundation.NSData, handler func(*foundation.NSData, unsafe.Pointer))

Creates a secure server playback context (SPC) that the client could send to the key server to obtain an expiration date for the provided persistable content key data. - Parameter persistableContentKeyData: Persistable content key data that was previously created using -[AVContentKeyRequest persistableContentKeyFromKeyVendorResponse:options:error:] or obtained via AVContentKeySessionDelegate callback -contentKeySession:didUpdatePersistableContentKey:forContentKeyIdentifier:. - Parameter handler: Once the secure token is ready, this block will be called with the token or an error describing the failure.

func (*AVContentKeySession) ProcessContentKeyRequestWithIdentifierInitializationDataOptions ¶

func (o *AVContentKeySession) ProcessContentKeyRequestWithIdentifierInitializationDataOptions(identifier objc.ID, initializationData *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID])

Informs the receiver that it should attempt to instantiate a content decryption key using the specified initialization data. May be used to generate an AVContentKeyRequest from request initialization data already in hand, without awaiting such data during the processing of media data of an associated recipient. - Parameter identifier: Container- and protocol-specific identifier to be used to obtain a key response. Either identifier or initializationData must be non-nil. Both can be non-nil, if the content protection protocol requires both. - Parameter initializationData: Container- and protocol-specific data to be used to obtain a key response. Either identifier or initializationData must be non-nil. Both can be non-nil, if the content protection protocol requires both. - Parameter options: Additional information necessary to obtain the key, or nil if none. See AVContentKeyRequest*Key below.

func (*AVContentKeySession) RemoveContentKeyRecipient ¶

func (o *AVContentKeySession) RemoveContentKeyRecipient(recipient AVContentKeyRecipient)

Informs the receiver that the specified recipient will no longer be used. After the specified recipient is removed from the receiver it will become inoperable. Remove the recipient only after you have finished operating on the media data associated with it. Sending this message to an AVContentKeySession is atomic.

func (*AVContentKeySession) RenewExpiringResponseDataForContentKeyRequest ¶

func (o *AVContentKeySession) RenewExpiringResponseDataForContentKeyRequest(contentKeyRequest *AVContentKeyRequest)

Informs the receiver that the already provided response data for an earlier AVContentKeyRequest will imminently expire. In response the receiver will invoke your delegate with a new content key request entreating it to renew the expiring response data, via -contentKeySession:didProvideRenewingContentKeyRequest:.

func (*AVContentKeySession) SetDelegateQueue ¶

func (o *AVContentKeySession) SetDelegateQueue(delegate AVContentKeySessionDelegate, delegateQueue *foundation.NSObject)

Sets the receiver's delegate. A delegate is required to handle content key initialization. - Parameter delegate: An object conforming to the AVContentKeySessionDelegate protocol. - Parameter delegateQueue: A dispatch queue on which delegate methods will be invoked whenever processes requiring content keys are executed asynchronously. Passing a value of nil for the delegateQueue parameter along with a non-nil value for the delegate parameter will result in an invalid argument exception.

func (*AVContentKeySession) StorageURL ¶

func (o *AVContentKeySession) StorageURL() *foundation.NSURL

The storage URL provided when the AVContentKeySession was created. May be nil. URL to a writable directory; may be nil. The session will use this to facilitate expired session reports after abnormal session termination.

type AVContentKeySessionDelegate ¶

type AVContentKeySessionDelegate interface {
	ContentKeySessionDidProvideContentKeyRequest(session *AVContentKeySession, keyRequest *AVContentKeyRequest)
}

AVContentKeySessionDelegate wraps the ObjC protocol AVContentKeySessionDelegate.

type AVContentKeySpecifier ¶

type AVContentKeySpecifier struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcontentkeyspecifier

func AVContentKeySpecifierContentKeySpecifierForKeySystemIdentifierOptions ¶

func AVContentKeySpecifierContentKeySpecifierForKeySystemIdentifierOptions(keySystem *foundation.NSString, contentKeyIdentifier objc.ID, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVContentKeySpecifier

Creates a new instance of AVContentKeySpecifier. This method returns an AVContentKeySpecifier instance that represents a content key in a specific content key system. - Parameter keySystem: A valid key system for content keys. - Parameter contentKeyIdentifier: Container and protocol-specific key identifier. - Parameter options: Additional information necessary to obtain the key, can be empty if none needed. - Returns: A new AVContentKeySpecifier

func AVContentKeySpecifierFromID ¶

func AVContentKeySpecifierFromID(id objc.ID) *AVContentKeySpecifier

func (*AVContentKeySpecifier) Identifier ¶

func (o *AVContentKeySpecifier) Identifier() objc.ID

Container and protocol-specific key identifier.

func (*AVContentKeySpecifier) InitForKeySystemIdentifierOptions ¶

func (o *AVContentKeySpecifier) InitForKeySystemIdentifierOptions(keySystem *foundation.NSString, contentKeyIdentifier objc.ID, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVContentKeySpecifier

Initialize an instance of AVContentKeySpecifier. This method returns an AVContentKeySpecifier instance that represents a content key in a specific content key system. - Parameter keySystem: A valid key system for content keys. - Parameter contentKeyIdentifier: Container and protocol-specific key identifier. - Parameter options: Additional information necessary to obtain the key, can be empty if none needed. - Returns: An instance of AVContentKeySpecifier

func (*AVContentKeySpecifier) KeySystem ¶

func (o *AVContentKeySpecifier) KeySystem() *foundation.NSString

A valid key system for content keys.

func (*AVContentKeySpecifier) Options ¶

Additional information necessary to obtain the key, can be empty if none needed.

type AVCoordinatedPlaybackParticipant ¶

type AVCoordinatedPlaybackParticipant struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcoordinatedplaybackparticipant

func AVCoordinatedPlaybackParticipantFromID ¶

func AVCoordinatedPlaybackParticipantFromID(id objc.ID) *AVCoordinatedPlaybackParticipant

func (*AVCoordinatedPlaybackParticipant) Identifier ¶

A unique id for the participant. Use this identifier to distinguish participants.

func (*AVCoordinatedPlaybackParticipant) IsReadyToPlay ¶

func (o *AVCoordinatedPlaybackParticipant) IsReadyToPlay() bool

YES if the participant is ready to play.

func (*AVCoordinatedPlaybackParticipant) SuspensionReasons ¶

The reason, if any, this participant is currently not participating in coordinated playback.

type AVCoordinatedPlaybackSuspension ¶

type AVCoordinatedPlaybackSuspension struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcoordinatedplaybacksuspension

func AVCoordinatedPlaybackSuspensionFromID ¶

func AVCoordinatedPlaybackSuspensionFromID(id objc.ID) *AVCoordinatedPlaybackSuspension

func (*AVCoordinatedPlaybackSuspension) BeginDate ¶

The begin time of the suspension.

func (*AVCoordinatedPlaybackSuspension) End ¶

Ends the suspension. If this is the last suspension, the coordinator will adjust timing of its playback object to match the group. Also see endProposingNewTime: for a way to end a suspension and simultaneously proposing a new time to the group.

func (*AVCoordinatedPlaybackSuspension) EndProposingNewTime ¶

func (o *AVCoordinatedPlaybackSuspension) EndProposingNewTime(time_ coremedia.CMTime)

Ends the suspension and proposes a new time that everyone should seek to. If this is the last suspension, the coordinator will propose the new time to the group without changing the groups playback rate. If this is not the last suspension, the time will be ignored. If the time is not numeric, this will behave like a call to [suspension end].

func (*AVCoordinatedPlaybackSuspension) Reason ¶

The reason for the suspension. This will be communicated to other participants while coordination is suspended.

type AVCustomMediaSelectionScheme ¶

type AVCustomMediaSelectionScheme struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avcustommediaselectionscheme

func AVCustomMediaSelectionSchemeFromID ¶

func AVCustomMediaSelectionSchemeFromID(id objc.ID) *AVCustomMediaSelectionScheme

func (*AVCustomMediaSelectionScheme) AvailableLanguages ¶

Provides available language choices. Each string in the array is intended to be interpreted as a BCP 47 language tag.

func (*AVCustomMediaSelectionScheme) MediaPresentationSettingsForSelectorComplementaryToLanguageSettings ¶

func (o *AVCustomMediaSelectionScheme) MediaPresentationSettingsForSelectorComplementaryToLanguageSettings(selector *AVMediaPresentationSelector, language *foundation.NSString, settings *foundation.NSArray[*AVMediaPresentationSetting]) *foundation.NSArray[*AVMediaPresentationSetting]

Provides an array of media presentation settings that can be effective at the same time as the specified language and settings for other selectors of the receiver. If the content is authored to provide a collection of AVMediaSelectionOptions that include one or more with all of the combinations of media characteristics of the specified AVMediaPresentationSettings together with all of the settings of the specified AVMediaPresentationSelector, this method will return all of the settings for that selector. However, if one or more of the available combinations are not possessed by any of the AVMediaSelectionOptions, it will return fewer. - Parameter selector: The AVMediaPresentationSelector for which complementary settings are requested. - Parameter language: A BCP 47 language tag chosen among the availableLanguages of the receiver. If no language setting pertains, can be nil. - Parameter settings: A collection of AVMediaPresentationSettings provided by selectors of the receiver other than the specified selector. Because no two AVMediaPresentationSettings of the same AVMediaPresentationSelector are complementary, an empty array will be returned if you specify more than one setting for any selector.

func (*AVCustomMediaSelectionScheme) Selectors ¶

Provides custom settings.

func (*AVCustomMediaSelectionScheme) ShouldOfferLanguageSelection ¶

func (o *AVCustomMediaSelectionScheme) ShouldOfferLanguageSelection() bool

Indicates whether an alternative selection interface should provide a menu of language choices.

type AVDateRangeMetadataGroup ¶

type AVDateRangeMetadataGroup struct {
	AVMetadataGroup
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdaterangemetadatagroup

func AVDateRangeMetadataGroupFromID ¶

func AVDateRangeMetadataGroupFromID(id objc.ID) *AVDateRangeMetadataGroup

func (*AVDateRangeMetadataGroup) EndDate ¶

func (*AVDateRangeMetadataGroup) InitWithItemsStartDateEndDate ¶

func (o *AVDateRangeMetadataGroup) InitWithItemsStartDateEndDate(items *foundation.NSArray[*AVMetadataItem], startDate *foundation.NSDate, endDate *foundation.NSDate) *AVDateRangeMetadataGroup

@method initWithItems:startDate:endDate: @abstract Initializes an instance of AVDateRangeMetadataGroup with a collection of metadata items. @param items An NSArray of AVMetadataItems. @param startDate The start date of the collection of AVMetadataItems. @param endDate The end date of the collection of AVMetadataItems. If the receiver is intended to represent information about an instantaneous event, the value of endDate should be equal to the value of startDate. A value of nil for endDate indicates that the endDate is indefinite. @result An instance of AVDateRangeMetadataGroup.

func (*AVDateRangeMetadataGroup) StartDate ¶

func (o *AVDateRangeMetadataGroup) StartDate() *foundation.NSDate

type AVDelegatingPlaybackCoordinator ¶

type AVDelegatingPlaybackCoordinator struct {
	AVPlaybackCoordinator
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdelegatingplaybackcoordinator

func AVDelegatingPlaybackCoordinatorFromID ¶

func AVDelegatingPlaybackCoordinatorFromID(id objc.ID) *AVDelegatingPlaybackCoordinator

func (*AVDelegatingPlaybackCoordinator) CoordinateRateChangeToRateOptions ¶

func (o *AVDelegatingPlaybackCoordinator) CoordinateRateChangeToRateOptions(rate float32, options AVDelegatingPlaybackCoordinatorRateChangeOptions)

Coordinaties a rate change across the group of connected participants, waiting for other participants to become ready if necessary. The coordinator will request a coordinated rate change from all other connected participants. When changing the rate from zero to non-zero, it may also wait out other participant's suspensions as configured by the suspensionReasonsThatTriggerWaiting property. This method should not be called when the rate change should not affect the group, or the group should not have control over local playback temporarily, e.g. a pause because of an audio session interruption. In those cases, the coordinator should be informed by beginning a suspension with the appropriate reason instead. If other participants pause is dependent on the coordinator's configuration. The suspension will stop the coordinator from issuing further commands to its playbackControlDelegate. After beginning the suspension, the playback object can be reconfigured as necessary. - Parameter rate: The playback rate the group should be using. - Parameter options: Additional configuration of the rate change. For details see AVDelegatingPlaybackCoordinatorRateChangeOptions. - NOTE: Calling this method while the coordinator is suspended affects only the local playback object. The group state will not be affected, even after the suspension ends.

func (*AVDelegatingPlaybackCoordinator) CoordinateSeekToTimeOptions ¶

func (o *AVDelegatingPlaybackCoordinator) CoordinateSeekToTimeOptions(time_ coremedia.CMTime, options AVDelegatingPlaybackCoordinatorSeekOptions)

Triggers a seek to the requested time for all connected participants. For behavior around resuming playback after the seek is complete and suspensions, see the discussion of coordinateRateChangeToRate:options. - Parameter time: The time the group should seek to when the command ends. - Parameter options: Additional configuration of the seek. For details see AVDelegatingPlaybackCoordinatorSeekOptions. - NOTE: Calling this method while the coordinator is suspended affects only the local playback object. The group state will not be affected, even after the suspension ends. To end a suspension and also affect the group timing see -[AVCoordinatedPlaybackSuspension endProposingNewTime:]

func (*AVDelegatingPlaybackCoordinator) CurrentItemIdentifier ¶

func (o *AVDelegatingPlaybackCoordinator) CurrentItemIdentifier() *foundation.NSString

The item identifier of the current item. Previously set by a call to transitionToItemWithIdentifier:proposingInitialTimingBasedOnTimebase:

func (*AVDelegatingPlaybackCoordinator) InitWithPlaybackControlDelegate ¶

func (o *AVDelegatingPlaybackCoordinator) InitWithPlaybackControlDelegate(playbackControlDelegate AVPlaybackCoordinatorPlaybackControlDelegate) *AVDelegatingPlaybackCoordinator

Creates an AVPlaybackCoordinator for a custom playback object. Use this to create an AVPlaybackCoordinator when playback is not driven by an AVPlayer. - Parameter playbackControlDelegate: An object conforming to the AVPlaybackCoordinatorPlaybackControlDelegate protocol representing a custom playback object. The coordinator will only hold a weak reference to its delegate. - NOTE: See AVPlayer's playbackCoordinator property to get an AVPlaybackCoordinator for an AVPlayer.

func (*AVDelegatingPlaybackCoordinator) PlaybackControlDelegate ¶

The custom player implementation controlled by the coordinator.

func (*AVDelegatingPlaybackCoordinator) ReapplyCurrentItemStateToPlaybackControlDelegate ¶

func (o *AVDelegatingPlaybackCoordinator) ReapplyCurrentItemStateToPlaybackControlDelegate()

Instructs the coordinator to re-issue commands to synchronize the current item back to the state of the other participants. Use this method when the playback object is in a state that doesn't match the group for some reason and should be re-synchronized.

func (*AVDelegatingPlaybackCoordinator) TransitionToItemWithIdentifierProposingInitialTimingBasedOnTimebase ¶

func (o *AVDelegatingPlaybackCoordinator) TransitionToItemWithIdentifierProposingInitialTimingBasedOnTimebase(itemIdentifier *foundation.NSString, snapshotTimebase unsafe.Pointer)

Informs the coordinator to transition to a new current item. The coordinator will stop sending commands for any previous item identifier and begin sending commands for the new identifier. The proposed timing will either be used as the new referece timing for the group, or it will be compared to an already existing reference timing. If the proposed timing doesn't match such an existing reference timing, the coordinator will use the playbackControlDelegate to issue appropriate commands to match up the timing. - Parameter itemIdentifier: The identifier for the new current item. May be nil if nothing is playing. - Parameter snapshotTimebase: A timebase used to communicate the initial playback state of the new item. If NULL, the coordinator will assume that playback is paused at kCMTimeZero. An appropriate timebase to pass to the completion handler may be retreived from AVFoundation playback objects such as AVSampleBufferRenderSynchronizer. It can also be created manually using CMTimebaseCreateWithSourceClock. The timebase will only be used to take a snapshot of its immediate timing. It will not be observed further. - NOTE: This is not a way to affect the play queue of other participants. All other participants must do this independently, e.g. as a side-effect of an automatic item transition or an out-of-band communication requesting a similar item change.

type AVDelegatingPlaybackCoordinatorBufferingCommand ¶

type AVDelegatingPlaybackCoordinatorBufferingCommand struct {
	AVDelegatingPlaybackCoordinatorPlaybackControlCommand
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdelegatingplaybackcoordinatorbufferingcommand

func AVDelegatingPlaybackCoordinatorBufferingCommandFromID ¶

func AVDelegatingPlaybackCoordinatorBufferingCommandFromID(id objc.ID) *AVDelegatingPlaybackCoordinatorBufferingCommand

func (*AVDelegatingPlaybackCoordinatorBufferingCommand) AnticipatedPlaybackRate ¶

func (o *AVDelegatingPlaybackCoordinatorBufferingCommand) AnticipatedPlaybackRate() float32

The rate to prepare playback for. The command should only be considered complete once the player is ready to receive an AVDelegatingPlaybackCoordinatorPlayCommand with the indicated rate.

func (*AVDelegatingPlaybackCoordinatorBufferingCommand) CompletionDueDate ¶

Communicates when the coordinator expects the command's completion handler at the latest. A receiver of a buffering command should fire the completion handler by this date at the latest. This is useful in buffering situations where the receiver has not yet buffered enough data to be considered ready to play by the due date. The receiver should then decide to either complete the command as is to try and keep up with the group, or alternatively begin a stall recovery suspension to communicate the situation to the other participants. Completing the command after this date means that the coordinator will likely send a play command for a later time than the receiver buffered for.

type AVDelegatingPlaybackCoordinatorPauseCommand ¶

type AVDelegatingPlaybackCoordinatorPauseCommand struct {
	AVDelegatingPlaybackCoordinatorPlaybackControlCommand
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdelegatingplaybackcoordinatorpausecommand

func AVDelegatingPlaybackCoordinatorPauseCommandFromID ¶

func AVDelegatingPlaybackCoordinatorPauseCommandFromID(id objc.ID) *AVDelegatingPlaybackCoordinatorPauseCommand

func (*AVDelegatingPlaybackCoordinatorPauseCommand) AnticipatedPlaybackRate ¶

func (o *AVDelegatingPlaybackCoordinatorPauseCommand) AnticipatedPlaybackRate() float32

The rate to prepare for if shouldBufferInAnticipationOfPlayback is YES.

func (*AVDelegatingPlaybackCoordinatorPauseCommand) ShouldBufferInAnticipationOfPlayback ¶

func (o *AVDelegatingPlaybackCoordinatorPauseCommand) ShouldBufferInAnticipationOfPlayback() bool

Indicates that playback is anticipated and the player should begin buffering if necessary. When shouldBufferInAnticipationOfPlayback is YES, some participant wants to resume playback at the rate indicated by the anticipatedPlaybackRate property. This should be treated similar to receiving a separate AVDelegatingPlaybackCoordinatorBufferingCommand. If YES, the command should only be considered complete once the player is ready to receive an AVDelegatingPlaybackCoordinatorPlayCommand with the indicated rate.

type AVDelegatingPlaybackCoordinatorPlayCommand ¶

type AVDelegatingPlaybackCoordinatorPlayCommand struct {
	AVDelegatingPlaybackCoordinatorPlaybackControlCommand
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdelegatingplaybackcoordinatorplaycommand

func AVDelegatingPlaybackCoordinatorPlayCommandFromID ¶

func AVDelegatingPlaybackCoordinatorPlayCommandFromID(id objc.ID) *AVDelegatingPlaybackCoordinatorPlayCommand

func (*AVDelegatingPlaybackCoordinatorPlayCommand) HostClockTime ¶

This is the host clock time (see CMClockGetHostTimeClock()) defining when playback should start (or should have started) at the given itemTime.

func (*AVDelegatingPlaybackCoordinatorPlayCommand) ItemTime ¶

The itemTime that playback should begin at. The receiver of this command should verify that data is loaded for the requested time and potentially begin loading it before beginning playback. It is not important to load data for time exactly. If data "similar" to time is already loaded, it is acceptable to start playback with the loaded data. Playback should still start with the requested timing. Should the receiver be unable to start with the exact requested timing, playback will be out of sync with the group. If data for the requested time cannot be loaded, or playback stalls later, the command handler may want to indicate this to the coordinator by beginning a suspension with AVCoordinatedPlaybackSuspensionReasonStallRecovery.

func (*AVDelegatingPlaybackCoordinatorPlayCommand) Rate ¶

Playback rate. Will always be non-zero.

type AVDelegatingPlaybackCoordinatorPlaybackControlCommand ¶

type AVDelegatingPlaybackCoordinatorPlaybackControlCommand struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdelegatingplaybackcoordinatorplaybackcontrolcommand

func (*AVDelegatingPlaybackCoordinatorPlaybackControlCommand) ExpectedCurrentItemIdentifier ¶

Indicates the item this command was issued for. Commands are always meant for the current item. A command handler should verify that the identifier of its current item matches this identifier. If it doesn't this command is obsolete and should be ignored. Note that any completion handler of the delegate method issuing the command must still be invoked.

func (*AVDelegatingPlaybackCoordinatorPlaybackControlCommand) Originator ¶

The participant causing this command to be issued. Only commands issued on behalf of another participant will contain an originator. Commands caused by local requests, e.g., requests to coordinate a rate change, will not contain an originator. Similarly, re-application of older commands, e.g., in response to a call to [AVDelegatingPlaybackCoordinator reapplyCurrentItemStateToPlaybackControlDelegate], will not contain an originator. If the originator is non-nil, it may be appropriate to show UI indicating someone else's action.

type AVDelegatingPlaybackCoordinatorRateChangeOptions ¶

type AVDelegatingPlaybackCoordinatorRateChangeOptions uint64
const (
	// Requests that the coordinator begin playback as soon as possible and ignore other participant's readiness and suspensions.
	AVDelegatingPlaybackCoordinatorRateChangeOptionPlayImmediately AVDelegatingPlaybackCoordinatorRateChangeOptions = 1
)

func (AVDelegatingPlaybackCoordinatorRateChangeOptions) String ¶

type AVDelegatingPlaybackCoordinatorSeekCommand ¶

type AVDelegatingPlaybackCoordinatorSeekCommand struct {
	AVDelegatingPlaybackCoordinatorPlaybackControlCommand
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdelegatingplaybackcoordinatorseekcommand

func AVDelegatingPlaybackCoordinatorSeekCommandFromID ¶

func AVDelegatingPlaybackCoordinatorSeekCommandFromID(id objc.ID) *AVDelegatingPlaybackCoordinatorSeekCommand

func (*AVDelegatingPlaybackCoordinatorSeekCommand) AnticipatedPlaybackRate ¶

func (o *AVDelegatingPlaybackCoordinatorSeekCommand) AnticipatedPlaybackRate() float32

The rate to prepare for if shouldBufferInAnticipationOfPlayback is YES.

func (*AVDelegatingPlaybackCoordinatorSeekCommand) CompletionDueDate ¶

Communicates when the coordinator expects the command's completion handler at the latest. A seek command expecting buffering in anticipation of playback does expect the receiver to fire the completion handler by this date at the latest. This is useful in buffering situations where the receiver has not yet buffered enough data to be considered ready to play by the due date. The receiver should then decide to either complete the command as is to try and keep up with the group, or alternatively begin a stall recovery suspension to communicate the situation to the other participants. Completing the command after this date means that the coordinator will likely send a play command for a later time than the receiver buffered for.

func (*AVDelegatingPlaybackCoordinatorSeekCommand) ItemTime ¶

The time to seek the currentItem to. Playback should never automatically resume after seeking to this time. The coordinator will issue a new PlayCommand when everyone else is ready to resume.

func (*AVDelegatingPlaybackCoordinatorSeekCommand) ShouldBufferInAnticipationOfPlayback ¶

func (o *AVDelegatingPlaybackCoordinatorSeekCommand) ShouldBufferInAnticipationOfPlayback() bool

Indicates that playback is anticipated and the player should begin buffering if necessary. When shouldBufferInAnticipationOfPlayback, playback is expected to eventually resume at the rate indicated by the anticipatedPlaybackRate property. This should be treated similar to receiving a separate AVDelegatingPlaybackCoordinatorBufferingCommand. If YES, the command should only be considered complete once the player is ready to receive an AVDelegatingPlaybackCoordinatorPlayCommand with the indicated rate.

type AVDelegatingPlaybackCoordinatorSeekOptions ¶

type AVDelegatingPlaybackCoordinatorSeekOptions uint64
const (
	// Requests that the coordinator resume playback as soon as possible after the seek is complete and ignore other participant's readiness and suspensions.
	AVDelegatingPlaybackCoordinatorSeekOptionResumeImmediately AVDelegatingPlaybackCoordinatorSeekOptions = 1
)

func (AVDelegatingPlaybackCoordinatorSeekOptions) String ¶

type AVDepthData ¶

type AVDepthData struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avdepthdata

func AVDepthDataDepthDataFromDictionaryRepresentationError ¶

func AVDepthDataDepthDataFromDictionaryRepresentationError(imageSourceAuxDataInfoDictionary *foundation.NSDictionary[objc.ID, objc.ID]) (*AVDepthData, error)

@method depthDataFromDictionaryRepresentation:error: @abstract Returns an AVDepthData instance from depth information in an image file. @param imageSourceAuxDataInfoDictionary A dictionary of primitive depth-related information obtained from CGImageSourceCopyAuxiliaryDataInfoAtIndex. @param outError On return, if the depth data cannot be created, points to an NSError describing the problem. @result An AVDepthData instance, or nil if the auxiliary data info dictionary was malformed. @discussion When using ImageIO framework's CGImageSource API to read from a HEIF or JPEG file containing depth data, AVDepthData can be instantiated using the result of CGImageSourceCopyAuxiliaryDataInfoAtIndex, which returns a CFDictionary of primitive map information.

func AVDepthDataFromID ¶

func AVDepthDataFromID(id objc.ID) *AVDepthData

func (*AVDepthData) AvailableDepthDataTypes ¶

func (o *AVDepthData) AvailableDepthDataTypes() *foundation.NSArray[*foundation.NSNumber]

@property availableDepthDataTypes @abstract Specifies which depth data pixel formats may be used with depthDataByConvertingToDepthDataType:. @discussion This property presents the available pixel format types as an array of NSNumbers, each wrapping an OSType (CV pixel format type).

func (*AVDepthData) CameraCalibrationData ¶

func (o *AVDepthData) CameraCalibrationData() *AVCameraCalibrationData

@property cameraCalibrationData @abstract The calibration data of the camera with which AVDepthData map's values are aligned. @discussion See AVCameraCalibrationData for more information. This property may return nil if no camera calibration data is available for the depth data.

func (*AVDepthData) DepthDataAccuracy ¶

func (o *AVDepthData) DepthDataAccuracy() AVDepthDataAccuracy

@property depthDataAccuracy @abstract Specifies the accuracy of the units in the depth data map's values. @discussion See AVDepthDataAccuracy documentation for more information.

func (*AVDepthData) DepthDataByApplyingExifOrientation ¶

func (o *AVDepthData) DepthDataByApplyingExifOrientation(exifOrientation imageio.CGImagePropertyOrientation) *AVDepthData

@method depthDataByApplyingExifOrientation: @abstract Returns a derivative AVDepthData instance in which the specified Exif orientation has been applied. @param exifOrientation One of the 8 standard Exif orientation tags expressing how the depth data should be rotated / mirrored. @result An AVDepthData instance. @discussion When applying simple 90 degree rotation or mirroring edits to media containing depth data, you may use this initializer to create a derivative copy of the depth in which the specified orientation is applied to both the underlying pixel map data and the camera calibration data. This method throws an NSInvalidArgumentException if you pass an unrecognized exifOrientation.

func (*AVDepthData) DepthDataByConvertingToDepthDataType ¶

func (o *AVDepthData) DepthDataByConvertingToDepthDataType(depthDataType uint) *AVDepthData

@method depthDataByConvertingToDepthDataType: @abstract Returns a converted, derivative AVDepthData instance in the specified depthDataType. @param depthDataType The OSType of depthData object to which you'd like to convert. Must be present in availableDepthDataTypes. @result An AVDepthData instance. @discussion This method throws an NSInvalidArgumentException if you pass an unrecognized depthDataType. See

func (*AVDepthData) DepthDataByReplacingDepthDataMapWithPixelBufferError ¶

func (o *AVDepthData) DepthDataByReplacingDepthDataMapWithPixelBufferError(pixelBuffer unsafe.Pointer) (*AVDepthData, error)

@method depthDataByReplacingDepthDataMapWithPixelBuffer:error: @abstract Returns an AVDepthData instance wrapping the replacement depth data map pixel buffer. @param pixelBuffer A pixel buffer containing depth data information in one of the 4 supported disparity / depth pixel formats. @param outError On return, if the depth data cannot be created, points to an NSError describing the problem. @result An AVDepthData instance, or nil if the pixel buffer is malformed. @discussion When applying complex edits to media containing depth data, you may create a derivative map with arbitrary transforms applied to it, then use this initializer to create a new AVDepthData. Note that this new depth data object has no camera calibration data, so its cameraCalibrationData property always returns nil.

func (*AVDepthData) DepthDataMap ¶

func (o *AVDepthData) DepthDataMap() unsafe.Pointer

@property depthDataMap @abstract Provides access to the depth data object's internal map. @discussion The depth data map's pixel format can be queried using the depthDataType property.

func (*AVDepthData) DepthDataQuality ¶

func (o *AVDepthData) DepthDataQuality() AVDepthDataQuality

@property depthDataQuality @abstract Specifies the overall quality of the depth data map's values. @discussion See AVDepthDataQuality documentation for more information.

func (*AVDepthData) DepthDataType ¶

func (o *AVDepthData) DepthDataType() uint

@property depthDataType @abstract Specifies the pixel format type of this depth data object's internal map. @discussion One of kCVPixelFormatType_DisparityFloat16, kCVPixelFormatType_DisparityFloat32, kCVPixelFormatType_DepthFloat16, or kCVPixelFormatType_DepthFloat32.

func (*AVDepthData) DictionaryRepresentationForAuxiliaryDataType ¶

func (o *AVDepthData) DictionaryRepresentationForAuxiliaryDataType(outAuxDataType *foundation.NSString) *foundation.NSDictionary[objc.ID, objc.ID]

@method dictionaryRepresentationForAuxiliaryDataType: @abstract Returns a dictionary of primitive map information to be used when writing an image file with depth data. @param outAuxDataType On output, either kCGImageAuxiliaryDataTypeDisparity or kCGImageAuxiliaryDataTypeDepth, depending on the depth data's file. @result A dictionary of CGImageDestination compatible depth information, or nil if the auxDataType is unsupported. @discussion When using ImageIO framework's CGImageDestination API to write depth data to a HEIF or JPEG file, you may use this method to generate a dictionary of primitive map information consumed by CGImageDestinationAddAuxiliaryDataInfo.

func (*AVDepthData) IsDepthDataFiltered ¶

func (o *AVDepthData) IsDepthDataFiltered() bool

@property depthDataFiltered @abstract Specifies whether the depth data pixel buffer map contains filtered (hole-filled) data. @discussion By setting either AVCaptureDepthDataOutput's filteringEnabled property or AVCapturePhotoSettings' depthDataFiltered property to YES, the resulting depth data are filtered to remove invalid pixel values that may be present due to a variety of factors including low light and lens occlusion. If you've requested depth data filtering, all depth data holes are filled. Note that filtering the depth data makes it more usable for applying effects, but alters the data such that it may no longer be suitable for computer vision tasks. Unfiltered depth maps present missing data as NaN.

type AVDepthDataAccuracy ¶

type AVDepthDataAccuracy int64
const (
	AVDepthDataAccuracyRelative AVDepthDataAccuracy = 0
	AVDepthDataAccuracyAbsolute AVDepthDataAccuracy = 1
)

func (AVDepthDataAccuracy) String ¶

func (e AVDepthDataAccuracy) String() string

type AVDepthDataQuality ¶

type AVDepthDataQuality int64
const (
	AVDepthDataQualityLow  AVDepthDataQuality = 0
	AVDepthDataQualityHigh AVDepthDataQuality = 1
)

func (AVDepthDataQuality) String ¶

func (e AVDepthDataQuality) String() string

type AVEdgeWidths ¶

type AVEdgeWidths struct {
	Left   float64
	Top    float64
	Right  float64
	Bottom float64
}

type AVError ¶

type AVError int64
const (
	AVErrorUnknown                                       AVError = -11800
	AVErrorOutOfMemory                                   AVError = -11801
	AVErrorSessionNotRunning                             AVError = -11803
	AVErrorDeviceAlreadyUsedByAnotherSession             AVError = -11804
	AVErrorNoDataCaptured                                AVError = -11805
	AVErrorSessionConfigurationChanged                   AVError = -11806
	AVErrorDiskFull                                      AVError = -11807
	AVErrorDeviceWasDisconnected                         AVError = -11808
	AVErrorMediaChanged                                  AVError = -11809
	AVErrorMaximumDurationReached                        AVError = -11810
	AVErrorMaximumFileSizeReached                        AVError = -11811
	AVErrorMediaDiscontinuity                            AVError = -11812
	AVErrorMaximumNumberOfSamplesForFileFormatReached    AVError = -11813
	AVErrorDeviceNotConnected                            AVError = -11814
	AVErrorDeviceInUseByAnotherApplication               AVError = -11815
	AVErrorDeviceLockedForConfigurationByAnotherProcess  AVError = -11817
	AVErrorExportFailed                                  AVError = -11820
	AVErrorDecodeFailed                                  AVError = -11821
	AVErrorInvalidSourceMedia                            AVError = -11822
	AVErrorFileAlreadyExists                             AVError = -11823
	AVErrorCompositionTrackSegmentsNotContiguous         AVError = -11824
	AVErrorInvalidCompositionTrackSegmentDuration        AVError = -11825
	AVErrorInvalidCompositionTrackSegmentSourceStartTime AVError = -11826
	AVErrorInvalidCompositionTrackSegmentSourceDuration  AVError = -11827
	AVErrorFileFormatNotRecognized                       AVError = -11828
	AVErrorFileFailedToParse                             AVError = -11829
	AVErrorMaximumStillImageCaptureRequestsExceeded      AVError = -11830
	AVErrorContentIsProtected                            AVError = -11831
	AVErrorNoImageAtTime                                 AVError = -11832
	AVErrorDecoderNotFound                               AVError = -11833
	AVErrorEncoderNotFound                               AVError = -11834
	AVErrorContentIsNotAuthorized                        AVError = -11835
	AVErrorApplicationIsNotAuthorized                    AVError = -11836
	AVErrorEncoderTemporarilyUnavailable                 AVError = -11840
	AVErrorInvalidVideoComposition                       AVError = -11841
	AVErrorReferenceForbiddenByReferencePolicy           AVError = -11842
	AVErrorInvalidOutputURLPathExtension                 AVError = -11843
	AVErrorScreenCaptureFailed                           AVError = -11844
	AVErrorDisplayWasDisabled                            AVError = -11845
	AVErrorTorchLevelUnavailable                         AVError = -11846
	AVErrorIncompatibleAsset                             AVError = -11848
	AVErrorFailedToLoadMediaData                         AVError = -11849
	AVErrorServerIncorrectlyConfigured                   AVError = -11850
	AVErrorApplicationIsNotAuthorizedToUseDevice         AVError = -11852
	AVErrorFailedToParse                                 AVError = -11853
	AVErrorFileTypeDoesNotSupportSampleReferences        AVError = -11854
	AVErrorUndecodableMediaData                          AVError = -11855
	AVErrorAirPlayControllerRequiresInternet             AVError = -11856
	AVErrorAirPlayReceiverRequiresInternet               AVError = -11857
	AVErrorVideoCompositorFailed                         AVError = -11858
	AVErrorCreateContentKeyRequestFailed                 AVError = -11860
	AVErrorUnsupportedOutputSettings                     AVError = -11861
	AVErrorOperationNotAllowed                           AVError = -11862
	AVErrorContentIsUnavailable                          AVError = -11863
	AVErrorFormatUnsupported                             AVError = -11864
	AVErrorMalformedDepth                                AVError = -11865
	AVErrorContentNotUpdated                             AVError = -11866
	AVErrorNoLongerPlayable                              AVError = -11867
	AVErrorNoCompatibleAlternatesForExternalDisplay      AVError = -11868
	AVErrorNoSourceTrack                                 AVError = -11869
	AVErrorExternalPlaybackNotSupportedForAsset          AVError = -11870
	AVErrorOperationNotSupportedForPreset                AVError = -11871
	AVErrorIncorrectlyConfigured                         AVError = -11875
	AVErrorSegmentStartedWithNonSyncSample               AVError = -11876
	AVErrorRosettaNotInstalled                           AVError = -11877
	AVErrorOperationCancelled                            AVError = -11878
	AVErrorContentKeyRequestCancelled                    AVError = -11879
	AVErrorInvalidSampleCursor                           AVError = -11880
	AVErrorFailedToLoadSampleData                        AVError = -11881
	AVErrorAirPlayReceiverTemporarilyUnavailable         AVError = -11882
	AVErrorEncodeFailed                                  AVError = -11883
	AVErrorSandboxExtensionDenied                        AVError = -11884
	AVErrorToneMappingFailed                             AVError = -11885
	AVErrorMediaExtensionDisabled                        AVError = -11886
	AVErrorMediaExtensionConflict                        AVError = -11887
)

func (AVError) String ¶

func (e AVError) String() string

type AVExposureBiasRange ¶

type AVExposureBiasRange struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avexposurebiasrange

func AVExposureBiasRangeFromID ¶

func AVExposureBiasRangeFromID(id objc.ID) *AVExposureBiasRange

func (*AVExposureBiasRange) ContainsExposureBias ¶

func (o *AVExposureBiasRange) ContainsExposureBias(exposureBias float32) bool

@method containsExposureBias: @abstract Tests if a given exposure bias in EV units is within the exposure bias range. @param exposureBias The exposure bias to test. @result Returns YES if the given exposure bias is within the exposure bias, NO otherwise. @discussion Note that the exposure bias ranges are inclusive.

func (*AVExposureBiasRange) MaxExposureBias ¶

func (o *AVExposureBiasRange) MaxExposureBias() float32

@property maxExposureBias @abstract A float indicating the maximum exposure bias in EV units supported by this range.

func (*AVExposureBiasRange) MinExposureBias ¶

func (o *AVExposureBiasRange) MinExposureBias() float32

@property minExposureBias @abstract A float indicating the minimum exposure bias in EV units supported by this range.

type AVExternalContentProtectionStatus ¶

type AVExternalContentProtectionStatus int64
const (
	// Indicates that the current protection status has not yet been discovered for the attached display(s).
	AVExternalContentProtectionStatusPending AVExternalContentProtectionStatus = 0
	// Indicates that sufficient protection with the attached display(s) has been established, content protected by the associated AVContentKey will be eligible to be displayed on the display(s).
	AVExternalContentProtectionStatusSufficient AVExternalContentProtectionStatus = 1
	// Indicates that sufficient protection with the attached display(s) has failed to be established, content protected by the associated AVContentKey will not be displayed.
	AVExternalContentProtectionStatusInsufficient AVExternalContentProtectionStatus = 2
)

func (AVExternalContentProtectionStatus) String ¶

type AVExternalStorageDevice ¶

type AVExternalStorageDevice struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avexternalstoragedevice

func AVExternalStorageDeviceFromID ¶

func AVExternalStorageDeviceFromID(id objc.ID) *AVExternalStorageDevice

func (*AVExternalStorageDevice) DisplayName ¶

func (o *AVExternalStorageDevice) DisplayName() *foundation.NSString

@property displayName @abstract Display name of the external storage device. @discussion This property can be used for displaying the name of an external storage device in a user interface. Will return nil if we fail to extract information from external storage device.

func (*AVExternalStorageDevice) FreeSize ¶

func (o *AVExternalStorageDevice) FreeSize() int

@property freeSize @abstract Current free size in bytes. @discussion This property represents the free size available on the external storage device. Will return -1 if we fail to extract information from external storage device.

func (*AVExternalStorageDevice) IsConnected ¶

func (o *AVExternalStorageDevice) IsConnected() bool

@property connected @abstract Indicates whether the external storage device is connected and available to the system. @discussion The property gives the current connection status of the external storage device.

func (*AVExternalStorageDevice) IsNotRecommendedForCaptureUse ¶

func (o *AVExternalStorageDevice) IsNotRecommendedForCaptureUse() bool

@property notRecommendedForCaptureUse @abstract Indicates whether the external storage device is not recommended for capture use. @discussion This property is used to let the client know if the external storage device is not suitable for camera capture.

func (*AVExternalStorageDevice) NextAvailableURLsWithPathExtensionsError ¶

func (o *AVExternalStorageDevice) NextAvailableURLsWithPathExtensionsError(extensionArray *foundation.NSArray[*foundation.NSString]) (*foundation.NSArray[*foundation.NSURL], error)

@method nextAvailableURLsWithPathExtensions:error: @abstract Next available security-scoped, DCF compliant URL array with different path extensions. @param extensionArray An array of path extensions for the next available URL requested. @param outError An out parameter with error information indicating why the URL could not be provided. If this method is successful, error will be nil. @result An array of DCF compliant security-scoped URL with all the path extensions requested. @discussion Configures the folder structure (create a DCIM folder if there isn't one already) on the external storage device to provide the next available unique DCF compliant security-scoped URL array with different path extensions. Security-scoped URL requires the use of startAccessingSecurityScopedResource, and stopAccessingSecurityScopedResource for access. [nextAvailableURL startAccessingSecurityScopedResource]; . . . // your code to capture image / video . . . [nextAvailableURL stopAccessingSecurityScopedResource]; Use the +requestAccessWithCompletionHandler: method to request access to external storage device before getting the next available URL array else an error will be thrown.

func (*AVExternalStorageDevice) TotalSize ¶

func (o *AVExternalStorageDevice) TotalSize() int

@property totalSize @abstract Total storage size in bytes. @discussion This property represents the total storage size available on the external storage device. Will return -1 if we fail to extract information from external storage device.

func (*AVExternalStorageDevice) Uuid ¶

@property uuid @abstract A unique identifier for external storage device. @discussion This property can be used to select a specific external storage device with ImageCapture framework APIs to read media assets. Will return nil if we fail to extract information from external storage device. For example the string value of this property will match the value from [ICDevice UUIDString].

type AVExternalStorageDeviceDiscoverySession ¶

type AVExternalStorageDeviceDiscoverySession struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avexternalstoragedevicediscoverysession

func AVExternalStorageDeviceDiscoverySessionFromID ¶

func AVExternalStorageDeviceDiscoverySessionFromID(id objc.ID) *AVExternalStorageDeviceDiscoverySession

func AVExternalStorageDeviceDiscoverySessionSharedSession ¶

func AVExternalStorageDeviceDiscoverySessionSharedSession() *AVExternalStorageDeviceDiscoverySession

@@property sharedSession @abstract Returns the singleton instance of the external storage device discovery session. @discussion There is only one external storage device discovery session for each host device which can be accessed using this method. Will return nil if the device doesn't support external storage devices.

func (*AVExternalStorageDeviceDiscoverySession) ExternalStorageDevices ¶

@property externalStorageDevices @abstract An array of external storage devices connected to this device. Read only. Key-value observable. @discussion An array of AVExternalStorageDevice objects connected to this device. The list is updated when the external storage device detected status changes.

type AVExternalSyncDevice ¶

type AVExternalSyncDevice struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avexternalsyncdevice

func AVExternalSyncDeviceFromID ¶

func AVExternalSyncDeviceFromID(id objc.ID) *AVExternalSyncDevice

func (*AVExternalSyncDevice) Clock ¶

func (o *AVExternalSyncDevice) Clock() unsafe.Pointer

A clock representing the source of time from the external sync device. This property returns `NULL` until the “status“ reaches “AVExternalSyncDeviceStatusActiveSync“.

func (*AVExternalSyncDevice) ProductID ¶

func (o *AVExternalSyncDevice) ProductID() uint

The USB product identifier associated with the external sync device. This `UInt32` value comes from the hardware vendor, and returns 0 if not available. Use this value in conjunction with the “vendorID“ to determine a specific product.

func (*AVExternalSyncDevice) SetSignalCompensationDelay ¶

func (o *AVExternalSyncDevice) SetSignalCompensationDelay(signalCompensationDelay coremedia.CMTime)

func (*AVExternalSyncDevice) SignalCompensationDelay ¶

func (o *AVExternalSyncDevice) SignalCompensationDelay() coremedia.CMTime

Delay to wait before starting the frame capture. An external sync is generally used to configure multiple devices in the real world. A display and a camera may receive a signal at the same time, but that does not mean the refresh of the display and camera are aligned in a way that does not cause tearing in the recording. The signal compensation delay can be used to offset the readout of a camera on an intra-frame scale. - Important: You should always set this property to a value less than the frame duration at which the camera is operating.

func (*AVExternalSyncDevice) Status ¶

The status of the externally connected device. Use this property to query the current connection status of the external sync device. This property is key-value observable.

func (*AVExternalSyncDevice) Uuid ¶

A unique identifier for an external sync device. Use this property to select a specific external sync device.

func (*AVExternalSyncDevice) VendorID ¶

func (o *AVExternalSyncDevice) VendorID() uint

The USB vendor identifier associated with the external sync device. This `UInt32` value is provided by the hardware vendor, and returns 0 if not available.

type AVExternalSyncDeviceDelegate ¶

type AVExternalSyncDeviceDelegate interface {
}

AVExternalSyncDeviceDelegate wraps the ObjC protocol AVExternalSyncDeviceDelegate.

type AVExternalSyncDeviceDiscoverySession ¶

type AVExternalSyncDeviceDiscoverySession struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avexternalsyncdevicediscoverysession

func AVExternalSyncDeviceDiscoverySessionFromID ¶

func AVExternalSyncDeviceDiscoverySessionFromID(id objc.ID) *AVExternalSyncDeviceDiscoverySession

func AVExternalSyncDeviceDiscoverySessionSharedSession ¶

func AVExternalSyncDeviceDiscoverySessionSharedSession() *AVExternalSyncDeviceDiscoverySession

The singleton instance of the external sync source device discovery session. Access the one and only external sync device discovery session on this host device using this method. “sharedSession“ returns `nil` if the host device doesn't support external sync devices.

func (*AVExternalSyncDeviceDiscoverySession) Devices ¶

An array of external sync devices connected to this host. The list is updated when external sync devices are connected to the host and they remain in the list until they become unavailable. This property is key-value observable.

type AVExternalSyncDeviceStatus ¶

type AVExternalSyncDeviceStatus int64
const (
	// Indicates that external sync signal is not connected, or has transitioned to a state that is not recoverable.
	AVExternalSyncDeviceStatusUnavailable AVExternalSyncDeviceStatus = 0
	// Indicates that a device supporting external sync is connected, but calibration has not started.
	AVExternalSyncDeviceStatusReady AVExternalSyncDeviceStatus = 1
	// Indicates that the external sync signal is connected and that the AVExternalSyncDevice object is calibrating to follow.
	AVExternalSyncDeviceStatusCalibrating AVExternalSyncDeviceStatus = 2
	// Indicates that the “AVExternalSyncDevice“ object is running and that the clock property on “AVExternalSyncDevice“ is calibrated to the external sync signal.
	AVExternalSyncDeviceStatusActiveSync AVExternalSyncDeviceStatus = 3
	// Indicates that the AVExternalSyncDevice was calibrated to follow the external sync, but the sync signal has been lost. The camera will continue to match the last signal it received, but sync is not guaranteed.
	AVExternalSyncDeviceStatusFreeRunSync AVExternalSyncDeviceStatus = 4
)

func (AVExternalSyncDeviceStatus) String ¶

type AVFragmentMinding ¶

type AVFragmentMinding interface {
	IsAssociatedWithFragmentMinder() bool
}

AVFragmentMinding wraps the ObjC protocol AVFragmentMinding.

type AVFragmentedAsset ¶

type AVFragmentedAsset struct {
	AVURLAsset
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avfragmentedasset

func AVFragmentedAssetFragmentedAssetWithURLOptions ¶

func AVFragmentedAssetFragmentedAssetWithURLOptions(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVFragmentedAsset

Returns an instance of AVFragmentedAsset for inspection of a fragmented media resource. - Parameter URL: An instance of NSURL that references a media resource. - Parameter options: An instance of NSDictionary that contains keys for specifying options for the initialization of the AVFragmentedAsset. See AVURLAssetPreferPreciseDurationAndTimingKey and AVURLAssetReferenceRestrictionsKey above. - Returns: An instance of AVFragmentedAsset.

func AVFragmentedAssetFromID ¶

func AVFragmentedAssetFromID(id objc.ID) *AVFragmentedAsset

type AVFragmentedAssetMinder ¶

type AVFragmentedAssetMinder struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avfragmentedassetminder

func AVFragmentedAssetMinderFragmentedAssetMinderWithAssetMindingInterval ¶

func AVFragmentedAssetMinderFragmentedAssetMinderWithAssetMindingInterval(asset *AVAsset, mindingInterval float64) *AVFragmentedAssetMinder

Creates an AVFragmentedAssetMinder, adds the specified asset to it, and sets the mindingInterval to the specified value. - Parameter asset: An instance of AVFragmentedAsset to add to the AVFragmentedAssetMinder - Parameter mindingInterval: The initial minding interval of the AVFragmentedAssetMinder. - Returns: A new instance of AVFragmentedAssetMinder.

func AVFragmentedAssetMinderFromID ¶

func AVFragmentedAssetMinderFromID(id objc.ID) *AVFragmentedAssetMinder

func (*AVFragmentedAssetMinder) AddFragmentedAsset ¶

func (o *AVFragmentedAssetMinder) AddFragmentedAsset(asset *AVAsset)

Adds a fragmented asset to the array of assets being minded. This method throws an exception if the asset is not a supported type (AVFragmentedAsset, AVFragmentedMovie), or if the asset is already being minded by another fragment minder. - Parameter asset: The fragmented asset to add to the minder.

func (*AVFragmentedAssetMinder) Assets ¶

An NSArray of the AVFragmentedAsset objects being minded.

func (*AVFragmentedAssetMinder) InitWithAssetMindingInterval ¶

func (o *AVFragmentedAssetMinder) InitWithAssetMindingInterval(asset *AVAsset, mindingInterval float64) *AVFragmentedAssetMinder

Creates an AVFragmentedAssetMinder, adds the specified asset to it, and sets the mindingInterval to the specified value. - Parameter asset: An instance of AVFragmentedAsset to add to the AVFragmentedAssetMinder - Parameter mindingInterval: The initial minding interval of the AVFragmentedAssetMinder. - Returns: A new instance of AVFragmentedAssetMinder.

func (*AVFragmentedAssetMinder) MindingInterval ¶

func (o *AVFragmentedAssetMinder) MindingInterval() float64

An NSTimeInterval indicating how often a check for additional fragments should be performed. The default interval is 10.0. This property throws an excepion if a value is set less than one millisecond (0.001) in duration.

func (*AVFragmentedAssetMinder) RemoveFragmentedAsset ¶

func (o *AVFragmentedAssetMinder) RemoveFragmentedAsset(asset *AVAsset)

Removes a fragmented asset from the array of assets being minded. This method throws an exception if the asset is not a supported type (AVFragmentedAsset, AVFragmentedMovie). - Parameter asset: The fragmented asset to remove from the minder.

func (*AVFragmentedAssetMinder) SetMindingInterval ¶

func (o *AVFragmentedAssetMinder) SetMindingInterval(mindingInterval float64)

type AVFragmentedAssetTrack ¶

type AVFragmentedAssetTrack struct {
	AVAssetTrack
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avfragmentedassettrack

func AVFragmentedAssetTrackFromID ¶

func AVFragmentedAssetTrackFromID(id objc.ID) *AVFragmentedAssetTrack

type AVFragmentedMovie ¶

type AVFragmentedMovie struct {
	AVMovie
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avfragmentedmovie

func AVFragmentedMovieFromID ¶

func AVFragmentedMovieFromID(id objc.ID) *AVFragmentedMovie

type AVFragmentedMovieMinder ¶

type AVFragmentedMovieMinder struct {
	AVFragmentedAssetMinder
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avfragmentedmovieminder

func AVFragmentedMovieMinderFragmentedMovieMinderWithMovieMindingInterval ¶

func AVFragmentedMovieMinderFragmentedMovieMinderWithMovieMindingInterval(movie *AVFragmentedMovie, mindingInterval float64) *AVFragmentedMovieMinder

@method fragmentedMovieMinderWithMovie:mindingInterval: @abstract Creates an AVFragmentedMovieMinder, adds the specified movie to it, and sets the mindingInterval to the specified value. @param movie An instance of AVFragmentedMovie to add to the AVFragmentedMovieMinder @param mindingInterval The initial minding interval of the AVFragmentedMovieMinder. @result A new instance of AVFragmentedMovieMinder.

func AVFragmentedMovieMinderFromID ¶

func AVFragmentedMovieMinderFromID(id objc.ID) *AVFragmentedMovieMinder

func (*AVFragmentedMovieMinder) AddFragmentedMovie ¶

func (o *AVFragmentedMovieMinder) AddFragmentedMovie(movie *AVFragmentedMovie)

@method addFragmentedMovie: @abstract Adds a fragmented movie to the array of movies being minded. @param movie The fragmented movie to add to the minder.

func (*AVFragmentedMovieMinder) InitWithMovieMindingInterval ¶

func (o *AVFragmentedMovieMinder) InitWithMovieMindingInterval(movie *AVFragmentedMovie, mindingInterval float64) *AVFragmentedMovieMinder

@method initWithMovie:mindingInterval: @abstract Creates an AVFragmentedMovieMinder, adds the specified movie to it, and sets the mindingInterval to the specified value. @param movie An instance of AVFragmentedMovie to add to the AVFragmentedMovieMinder @param mindingInterval The initial minding interval of the AVFragmentedMovieMinder. @result A new instance of AVFragmentedMovieMinder.

func (*AVFragmentedMovieMinder) Movies ¶

@property movies @abstract An NSArray of the AVFragmentedMovie objects being minded.

func (*AVFragmentedMovieMinder) RemoveFragmentedMovie ¶

func (o *AVFragmentedMovieMinder) RemoveFragmentedMovie(movie *AVFragmentedMovie)

@method removeFragmentedMovie: @abstract Removes a fragmented movie from the array of movies being minded. @param movie The fragmented movie to remove from the minder.

type AVFragmentedMovieTrack ¶

type AVFragmentedMovieTrack struct {
	AVMovieTrack
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avfragmentedmovietrack

func AVFragmentedMovieTrackFromID ¶

func AVFragmentedMovieTrackFromID(id objc.ID) *AVFragmentedMovieTrack

type AVFrameRateRange ¶

type AVFrameRateRange struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avframeraterange

func AVFrameRateRangeFromID ¶

func AVFrameRateRangeFromID(id objc.ID) *AVFrameRateRange

func (*AVFrameRateRange) MaxFrameDuration ¶

func (o *AVFrameRateRange) MaxFrameDuration() coremedia.CMTime

@property maxFrameDuration @abstract A CMTime indicating the maximum frame duration supported by this range. @discussion This read-only property indicates the maximum frame duration supported by this range. It is the reciprocal of minFrameRate, and expresses minFrameRate as a duration.

func (*AVFrameRateRange) MaxFrameRate ¶

func (o *AVFrameRateRange) MaxFrameRate() float64

@property maxFrameRate @abstract A Float64 indicating the maximum frame rate supported by this range. @discussion This read-only property indicates the maximum frame rate supported by this range in frames per second.

func (*AVFrameRateRange) MinFrameDuration ¶

func (o *AVFrameRateRange) MinFrameDuration() coremedia.CMTime

@property minFrameDuration @abstract A CMTime indicating the minimum frame duration supported by this range. @discussion This read-only property indicates the minimum frame duration supported by this range. It is the reciprocal of maxFrameRate, and expresses maxFrameRate as a duration.

func (*AVFrameRateRange) MinFrameRate ¶

func (o *AVFrameRateRange) MinFrameRate() float64

@property minFrameRate @abstract A Float64 indicating the minimum frame rate supported by this range. @discussion This read-only property indicates the minimum frame rate supported by this range in frames per second.

type AVKeyValueStatus ¶

type AVKeyValueStatus int64
const (
	AVKeyValueStatusUnknown   AVKeyValueStatus = 0
	AVKeyValueStatusLoading   AVKeyValueStatus = 1
	AVKeyValueStatusLoaded    AVKeyValueStatus = 2
	AVKeyValueStatusFailed    AVKeyValueStatus = 3
	AVKeyValueStatusCancelled AVKeyValueStatus = 4
)

func (AVKeyValueStatus) String ¶

func (e AVKeyValueStatus) String() string

type AVMediaDataStorage ¶

type AVMediaDataStorage struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediadatastorage

func AVMediaDataStorageFromID ¶

func AVMediaDataStorageFromID(id objc.ID) *AVMediaDataStorage

func (*AVMediaDataStorage) InitWithURLOptions ¶

@method initWithURL:options: @abstract Creates an AVMediaDataStorage object associated with a file URL. @param URL An NSURL object that specifies a file where sample data that is added to a movie or track should be written. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMediaDataStorage object. Currently no keys are defined. @result An AVMediaDataStorage object

func (*AVMediaDataStorage) URL ¶

@method URL @abstract The URL from which the receiver was initialized; may be nil.

type AVMediaExtensionProperties ¶

type AVMediaExtensionProperties struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediaextensionproperties

func AVMediaExtensionPropertiesFromID ¶

func AVMediaExtensionPropertiesFromID(id objc.ID) *AVMediaExtensionProperties

func (*AVMediaExtensionProperties) ContainingBundleName ¶

func (o *AVMediaExtensionProperties) ContainingBundleName() *foundation.NSString

The name of the containing application bundle. The localized name of the application that hosts the MediaExtension.

func (*AVMediaExtensionProperties) ContainingBundleURL ¶

func (o *AVMediaExtensionProperties) ContainingBundleURL() *foundation.NSURL

The file URL of the host application for the MediaExtension.

func (*AVMediaExtensionProperties) ExtensionIdentifier ¶

func (o *AVMediaExtensionProperties) ExtensionIdentifier() *foundation.NSString

The identifier of the Media Extension. The extension identifier string, corresponding to the ClassImplementationID value from the EXAppExtensionAttributes dictionary in the Info.plist file.

func (*AVMediaExtensionProperties) ExtensionName ¶

func (o *AVMediaExtensionProperties) ExtensionName() *foundation.NSString

The name of the MediaExtension. The localized name of the MediaExtension format reader or video decoder, corresponding to the CFBundleDisplayName.

func (*AVMediaExtensionProperties) ExtensionURL ¶

func (o *AVMediaExtensionProperties) ExtensionURL() *foundation.NSURL

The file URL of the MediaExtension bundle.

type AVMediaPresentationSelector ¶

type AVMediaPresentationSelector struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediapresentationselector

func AVMediaPresentationSelectorFromID ¶

func AVMediaPresentationSelectorFromID(id objc.ID) *AVMediaPresentationSelector

func (*AVMediaPresentationSelector) DisplayNameForLocaleIdentifier ¶

func (o *AVMediaPresentationSelector) DisplayNameForLocaleIdentifier(localeIdentifier *foundation.NSString) *foundation.NSString

Returns the display name for the selector that best matches the specified locale identifier.

func (*AVMediaPresentationSelector) Identifier ¶

Provides the authored identifier for the selector.

func (*AVMediaPresentationSelector) Settings ¶

Provides selectable mutually exclusive settings for the selector.

type AVMediaPresentationSetting ¶

type AVMediaPresentationSetting struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediapresentationsetting

func AVMediaPresentationSettingFromID ¶

func AVMediaPresentationSettingFromID(id objc.ID) *AVMediaPresentationSetting

func (*AVMediaPresentationSetting) DisplayNameForLocaleIdentifier ¶

func (o *AVMediaPresentationSetting) DisplayNameForLocaleIdentifier(localeIdentifier *foundation.NSString) *foundation.NSString

Returns the display name for the selectable setting that best matches the specified locale identifier.

func (*AVMediaPresentationSetting) MediaCharacteristic ¶

func (o *AVMediaPresentationSetting) MediaCharacteristic() *foundation.NSString

Provides the media characteristic that corresponds to the selectable setting.

type AVMediaSelection ¶

type AVMediaSelection struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediaselection

func AVMediaSelectionFromID ¶

func AVMediaSelectionFromID(id objc.ID) *AVMediaSelection

func (*AVMediaSelection) Asset ¶

func (o *AVMediaSelection) Asset() *AVAsset

func (*AVMediaSelection) MediaSelectionCriteriaCanBeAppliedAutomaticallyToMediaSelectionGroup ¶

func (o *AVMediaSelection) MediaSelectionCriteriaCanBeAppliedAutomaticallyToMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) bool

@method mediaSelectionCriteriaCanBeAppliedAutomaticallyToMediaSelectionGroup: @abstract Indicates that specified media selection group is subject to automatic media selection. @param mediaSelectionGroup A media selection group obtained from the receiver's asset. @result YES if the group is subject to automatic media selection. @discussion Automatic application of media selection criteria is suspended in any group in which a specific selection has been made via an invocation of -selectMediaOption:inMediaSelectionGroup:.

func (*AVMediaSelection) SelectedMediaOptionInMediaSelectionGroup ¶

func (o *AVMediaSelection) SelectedMediaOptionInMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *AVMediaSelectionOption

@method selectedMediaOptionInMediaSelectionGroup: @abstract Indicates the media selection option that's currently selected from the specified group. May be nil. @param mediaSelectionGroup A media selection group obtained from the receiver's asset. @result An instance of AVMediaSelectionOption that describes the currently selection option in the group. @discussion If the value of the property allowsEmptySelection of the AVMediaSelectionGroup is YES, the currently selected option in the group may be nil.

type AVMediaSelectionGroup ¶

type AVMediaSelectionGroup struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediaselectiongroup

func AVMediaSelectionGroupFromID ¶

func AVMediaSelectionGroupFromID(id objc.ID) *AVMediaSelectionGroup

func (*AVMediaSelectionGroup) AllowsEmptySelection ¶

func (o *AVMediaSelectionGroup) AllowsEmptySelection() bool

Indicates whether it's possible to present none of the options in the group when an associated AVPlayerItem is played. If allowsEmptySelection is YES, all of the available media options in the group can be deselected by passing nil as the specified AVMediaSelectionOption to -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:].

func (*AVMediaSelectionGroup) CustomMediaSelectionScheme ¶

func (o *AVMediaSelectionGroup) CustomMediaSelectionScheme() *AVCustomMediaSelectionScheme

func (*AVMediaSelectionGroup) DefaultOption ¶

func (o *AVMediaSelectionGroup) DefaultOption() *AVMediaSelectionOption

Indicates the default option in the group, i.e. the option that's intended for use in the absence of a specific end-user selection or preference. Can be nil, indicating that without a specific end-user selection or preference, no option in the group is intended to be selected.

func (*AVMediaSelectionGroup) MediaSelectionOptionWithPropertyList ¶

func (o *AVMediaSelectionGroup) MediaSelectionOptionWithPropertyList(plist objc.ID) *AVMediaSelectionOption

Returns the instance of AVMediaSelectionOption with properties that match the specified property list. - Parameter plist: A property list previously obtained from an option in the group via -[AVMediaSelectionOption propertyList]. - Returns: If the specified properties match those of an option in the group, an instance of AVMediaSelectionOption. Otherwise nil.

func (*AVMediaSelectionGroup) Options ¶

A collection of mutually exclusive media selection options. An NSArray of AVMediaSelectionOption*.

type AVMediaSelectionOption ¶

type AVMediaSelectionOption struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmediaselectionoption

func AVMediaSelectionOptionFromID ¶

func AVMediaSelectionOptionFromID(id objc.ID) *AVMediaSelectionOption

func (*AVMediaSelectionOption) AssociatedMediaSelectionOptionInMediaSelectionGroup ¶

func (o *AVMediaSelectionOption) AssociatedMediaSelectionOptionInMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *AVMediaSelectionOption

If a media selection option in another group is associated with the specified option, returns a reference to the associated option. Audible media selection options often have associated legible media selection options; in particular, audible options are typically associated with forced-only subtitle options with the same locale. See AVMediaCharacteristicContainsOnlyForcedSubtitles in AVMediaFormat.h for a discussion of forced-only subtitles. - Parameter mediaSelectionGroup: A media selection group in which an associated option is to be sought. - Returns: An instance of AVMediaSelectionOption.

func (*AVMediaSelectionOption) AvailableMetadataFormats ¶

func (o *AVMediaSelectionOption) AvailableMetadataFormats() *foundation.NSArray[*foundation.NSString]

Provides an NSArray of NSStrings, each representing a metadata format that contains metadata associated with the option (e.g. ID3, iTunes metadata, etc.). Metadata formats are defined in AVMetadataFormat.h.

func (*AVMediaSelectionOption) CommonMetadata ¶

Provides an array of AVMetadataItems for each common metadata key for which a value is available. The array of AVMetadataItems can be filtered according to language via +[AVMetadataItem metadataItemsFromArray:filteredAndSortedAccordingToPreferredLanguages:], according to locale via +[AVMetadataItem metadataItemsFromArray:withLocale:], or according to key via +[AVMetadataItem metadataItemsFromArray:withKey:keySpace:]. Example: to obtain the name (or title) of a media selection option in any of the user's preferred languages. ```objc NSString *title = nil; NSArray *titles = [AVMetadataItem metadataItemsFromArray:[mediaSelectionOption commonMetadata] withKey:AVMetadataCommonKeyTitle keySpace:AVMetadataKeySpaceCommon]; if ([titles count] > 0) { // Try to get a title that matches one of the user's preferred languages. NSArray *titlesForPreferredLanguages = [AVMetadataItem metadataItemsFromArray:titles filteredAndSortedAccordingToPreferredLanguages:[NSLocale preferredLanguages]]; if ([titlesForPreferredLanguages count] > 0) { title = [[titlesForPreferredLanguages objectAtIndex:0] stringValue]; } // No matches in any of the preferred languages. Just use the primary title metadata we find. if (title == nil) { title = [[titles objectAtIndex:0] stringValue]; } } ```

func (*AVMediaSelectionOption) DisplayName ¶

func (o *AVMediaSelectionOption) DisplayName() *foundation.NSString

Provides an NSString suitable for display using the current system locale. May use this option's common metadata, media characteristics and locale properties in addition to the current system locale to formulate an NSString intended for display. In the event that common metadata is not available in the specified locale, displayName will fall back to considering locales with the multilingual ("mul") then undetermined ("und") locale identifiers. For a display name strictly with the specified locale use displayNameWithLocale: instead.

func (*AVMediaSelectionOption) DisplayNameWithLocale ¶

func (o *AVMediaSelectionOption) DisplayNameWithLocale(locale *foundation.NSLocale) *foundation.NSString

Provides an NSString suitable for display. May use this option's common metadata, media characteristics and locale properties in addition to the provided locale to formulate an NSString intended for display. Will only consider common metadata with the specified locale. - Parameter locale: Localize manufactured portions of the string using the specificed locale.

func (*AVMediaSelectionOption) ExtendedLanguageTag ¶

func (o *AVMediaSelectionOption) ExtendedLanguageTag() *foundation.NSString

Indicates the RFC 4646 language tag associated with the option. May be nil.

func (*AVMediaSelectionOption) HasMediaCharacteristic ¶

func (o *AVMediaSelectionOption) HasMediaCharacteristic(mediaCharacteristic *foundation.NSString) bool

Reports whether the media selection option includes media with the specified media characteristic. - Parameter mediaCharacteristic: The media characteristic of interest, e.g. AVMediaCharacteristicVisual, AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, etc. - Returns: YES if the media selection option includes media with the specified characteristic, otherwise NO.

func (*AVMediaSelectionOption) IsPlayable ¶

func (o *AVMediaSelectionOption) IsPlayable() bool

Indicates whether a media selection option is playable. If the media data associated with the option cannot be decoded or otherwise rendered, playable is NO.

func (*AVMediaSelectionOption) Locale ¶

Indicates the locale for which the media option was authored. Use -[NSLocale objectForKey:NSLocaleLanguageCode] to obtain the language code of the locale. See NSLocale.h for additional information.

func (*AVMediaSelectionOption) MediaSubTypes ¶

The mediaSubTypes of the media data associated with the option. An NSArray of NSNumbers carrying four character codes (of type FourCharCode) as defined in CoreAudioTypes.h for audio media and in CMFormatDescription.h for video media. Also see CMFormatDescriptionGetMediaSubType in CMFormatDescription.h for more information about media subtypes. Note that if no information is available about the encoding of the media presented when a media option is selected, the value of mediaSubTypes will be an empty array. This can occur, for example, with streaming media. In these cases the value of mediaSubTypes should simply not be used as a criteria for selection.

func (*AVMediaSelectionOption) MediaType ¶

func (o *AVMediaSelectionOption) MediaType() *foundation.NSString

The media type of the media data, e.g. AVMediaTypeAudio, AVMediaTypeSubtitle, etc.

func (*AVMediaSelectionOption) MetadataForFormat ¶

Provides an NSArray of AVMetadataItems, one for each metadata item in the container of the specified format. - Parameter format: The metadata format for which items are requested. - Returns: An NSArray containing AVMetadataItems.

func (*AVMediaSelectionOption) PropertyList ¶

func (o *AVMediaSelectionOption) PropertyList() objc.ID

Returns a serializable property list that can be used to obtain an instance of AVMediaSelectionOption representing the same option as the receiver via -[AVMediaSelectionGroup mediaSelectionOptionWithPropertyList:]. - Returns: A serializable property list that's sufficient to identify the option within its group. For serialization utilities, see NSPropertyList.h.

type AVMetadataBodyObject ¶

type AVMetadataBodyObject struct {
	AVMetadataObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadatabodyobject

func AVMetadataBodyObjectFromID ¶

func AVMetadataBodyObjectFromID(id objc.ID) *AVMetadataBodyObject

func (*AVMetadataBodyObject) BodyID ¶

func (o *AVMetadataBodyObject) BodyID() int

type AVMetadataFaceObject ¶

type AVMetadataFaceObject struct {
	AVMetadataObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadatafaceobject

func AVMetadataFaceObjectFromID ¶

func AVMetadataFaceObjectFromID(id objc.ID) *AVMetadataFaceObject

func (*AVMetadataFaceObject) FaceID ¶

func (o *AVMetadataFaceObject) FaceID() int

@property faceID @abstract A unique number associated with the receiver. @discussion The value of this property is an NSInteger indicating the unique identifier of this face in the picture. When a new face enters the picture, it is assigned a new unique identifier. faceIDs are not re-used as faces leave the picture and new ones enter. Faces that leave the picture then re-enter are assigned a new faceID.

func (*AVMetadataFaceObject) HasRollAngle ¶

func (o *AVMetadataFaceObject) HasRollAngle() bool

@property hasRollAngle @abstract A BOOL indicating whether the rollAngle property is valid for this receiver.

func (*AVMetadataFaceObject) HasYawAngle ¶

func (o *AVMetadataFaceObject) HasYawAngle() bool

@property hasYawAngle @abstract A BOOL indicating whether the yawAngle property is valid for this receiver.

func (*AVMetadataFaceObject) RollAngle ¶

func (o *AVMetadataFaceObject) RollAngle() float64

@property rollAngle @abstract The roll angle of the face in degrees. @discussion The value of this property is a CGFloat indicating the face's angle of roll (or tilt) in degrees. A value of 0.0 indicates that the face is level in the picture. If -hasRollAngle returns NO, then reading this property throws an NSGenericException.

func (*AVMetadataFaceObject) YawAngle ¶

func (o *AVMetadataFaceObject) YawAngle() float64

@property yawAngle @abstract The yaw angle of the face in degrees. @discussion The value of this property is a CGFloat indicating the face's angle of yaw (or turn) in degrees. A value of 0.0 indicates that the face is straight on in the picture. If -hasYawAngle returns NO, then reading this property throws an NSGenericException.

type AVMetadataGroup ¶

type AVMetadataGroup struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadatagroup

func AVMetadataGroupFromID ¶

func AVMetadataGroupFromID(id objc.ID) *AVMetadataGroup

func (*AVMetadataGroup) ClassifyingLabel ¶

func (o *AVMetadataGroup) ClassifyingLabel() *foundation.NSString

func (*AVMetadataGroup) Items ¶

func (*AVMetadataGroup) UniqueID ¶

func (o *AVMetadataGroup) UniqueID() *foundation.NSString

type AVMetadataItem ¶

type AVMetadataItem struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadataitem

func AVMetadataItemFromID ¶

func AVMetadataItemFromID(id objc.ID) *AVMetadataItem

func AVMetadataItemMetadataItemWithPropertiesOfMetadataItemValueLoadingHandler ¶

func AVMetadataItemMetadataItemWithPropertiesOfMetadataItemValueLoadingHandler(metadataItem *AVMetadataItem, handler func(*AVMetadataItemValueRequest)) *AVMetadataItem

@method metadataItemWithPropertiesOfMetadataItem:valueLoadingHandler: @abstract Creates an instance of AVMutableMetadataItem with a value that you do not wish to load unless required, e.g. a large image value that needn't be loaded into memory until another module wants to display it. @param metadataItem An instance of AVMetadataItem with the identifier, extendedLanguageTag, and other property values that you want the newly created instance of AVMetadataItem to share. The value of metadataItem is ignored. @param handler A block that loads the value of the metadata item. @result An instance of AVMetadataItem. @discussion This method is intended for the creation of metadata items for optional display purposes, when there is no immediate need to load specific metadata values. For example, see the interface for navigation markers as consumed by AVPlayerViewController. It's not intended for the creation of metadata items with values that are required immediately, such as metadata items that are provided for impending serialization operations (e.g. via -[AVAssetExportSession setMetadata:] and other similar methods defined on AVAssetWriter and AVAssetWriterInput). When -loadValuesAsynchronouslyForKeys:completionHandler: is invoked on an AVMetadataItem created via +metadataItemWithPropertiesOfMetadataItem:valueLoadingHandler: and @"value" is among the keys for which loading is requested, the block you provide as the value loading handler will be executed on an arbitrary dispatch queue, off the main thread. The handler can perform I/O and other necessary operations to obtain the value. If loading of the value succeeds, provide the value by invoking -[AVMetadataItemValueRequest respondWithValue:]. If loading of the value fails, provide an instance of NSError that describes the failure by invoking -[AVMetadataItemValueRequest respondWithError:].

func (*AVMetadataItem) CommonKey ¶

func (o *AVMetadataItem) CommonKey() *foundation.NSString

func (*AVMetadataItem) DataType ¶

func (o *AVMetadataItem) DataType() *foundation.NSString

func (*AVMetadataItem) DataValue ¶

func (o *AVMetadataItem) DataValue() *foundation.NSData

func (*AVMetadataItem) DateValue ¶

func (o *AVMetadataItem) DateValue() *foundation.NSDate

func (*AVMetadataItem) Duration ¶

func (o *AVMetadataItem) Duration() coremedia.CMTime

func (*AVMetadataItem) ExtendedLanguageTag ¶

func (o *AVMetadataItem) ExtendedLanguageTag() *foundation.NSString

func (*AVMetadataItem) ExtraAttributes ¶

func (o *AVMetadataItem) ExtraAttributes() *foundation.NSDictionary[*foundation.NSString, objc.ID]

func (*AVMetadataItem) Identifier ¶

func (o *AVMetadataItem) Identifier() *foundation.NSString

func (*AVMetadataItem) Key ¶

func (o *AVMetadataItem) Key() objc.ID

func (*AVMetadataItem) KeySpace ¶

func (o *AVMetadataItem) KeySpace() *foundation.NSString

func (*AVMetadataItem) LoadValuesAsynchronouslyForKeysCompletionHandler ¶

func (o *AVMetadataItem) LoadValuesAsynchronouslyForKeysCompletionHandler(keys *foundation.NSArray[*foundation.NSString], handler func())

func (*AVMetadataItem) Locale ¶

func (o *AVMetadataItem) Locale() *foundation.NSLocale

func (*AVMetadataItem) NumberValue ¶

func (o *AVMetadataItem) NumberValue() *foundation.NSNumber

func (*AVMetadataItem) StartDate ¶

func (o *AVMetadataItem) StartDate() *foundation.NSDate

func (*AVMetadataItem) StatusOfValueForKeyError ¶

func (o *AVMetadataItem) StatusOfValueForKeyError(key *foundation.NSString) (AVKeyValueStatus, error)

func (*AVMetadataItem) StringValue ¶

func (o *AVMetadataItem) StringValue() *foundation.NSString

func (*AVMetadataItem) Time ¶

func (o *AVMetadataItem) Time() coremedia.CMTime

func (*AVMetadataItem) Value ¶

func (o *AVMetadataItem) Value() objc.ID

type AVMetadataItemFilter ¶

type AVMetadataItemFilter struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadataitemfilter

func AVMetadataItemFilterFromID ¶

func AVMetadataItemFilterFromID(id objc.ID) *AVMetadataItemFilter

func AVMetadataItemFilterMetadataItemFilterForSharing ¶

func AVMetadataItemFilterMetadataItemFilterForSharing() *AVMetadataItemFilter

type AVMetadataItemValueRequest ¶

type AVMetadataItemValueRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadataitemvaluerequest

func AVMetadataItemValueRequestFromID ¶

func AVMetadataItemValueRequestFromID(id objc.ID) *AVMetadataItemValueRequest

func (*AVMetadataItemValueRequest) MetadataItem ¶

func (o *AVMetadataItemValueRequest) MetadataItem() *AVMetadataItem

func (*AVMetadataItemValueRequest) RespondWithError ¶

func (o *AVMetadataItemValueRequest) RespondWithError(error_ unsafe.Pointer)

@method respondWithError: @abstract Allows you to respond to an AVMetadataItemValueRequest in the case of failure. @param error An instance of NSError that describes a failure encountered while loading the value of an AVMetadataItem.

func (*AVMetadataItemValueRequest) RespondWithValue ¶

func (o *AVMetadataItemValueRequest) RespondWithValue(value objc.ID)

@method respondWithValue: @abstract Allows you to respond to an AVMetadataItemValueRequest by providing a value. @param value The value of the AVMetadataItem.

type AVMetadataMachineReadableCodeObject ¶

type AVMetadataMachineReadableCodeObject struct {
	AVMetadataObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadatamachinereadablecodeobject

func AVMetadataMachineReadableCodeObjectFromID ¶

func AVMetadataMachineReadableCodeObjectFromID(id objc.ID) *AVMetadataMachineReadableCodeObject

func (*AVMetadataMachineReadableCodeObject) Corners ¶

@property corners @abstract The points defining the (X,Y) locations of the corners of the machine-readable code. @discussion The value of this property is an NSArray of NSDictionaries, each of which has been created from a CGPoint using CGPointCreateDictionaryRepresentation(), representing the coordinates of the corners of the object with respect to the image in which it resides. If the metadata originates from video, the points may be expressed as scalar values from 0. - 1. The points in the corners differ from the bounds rectangle in that bounds is axis-aligned to orientation of the captured image, and the values of the corners reside within the bounds rectangle. The points are arranged in counter-clockwise order (clockwise if the code or image is mirrored), starting with the top-left of the code in its canonical orientation.

func (*AVMetadataMachineReadableCodeObject) Descriptor ¶

func (*AVMetadataMachineReadableCodeObject) StringValue ¶

@property stringValue @abstract Returns the receiver's errorCorrectedData decoded into a human-readable string. @discussion The value of this property is an NSString created by decoding the binary payload according to the format of the machine readable code. Returns nil if a string representation cannot be created from the payload.

type AVMetadataObject ¶

type AVMetadataObject struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetadataobject

func AVMetadataObjectFromID ¶

func AVMetadataObjectFromID(id objc.ID) *AVMetadataObject

func (*AVMetadataObject) Bounds ¶

@property bounds @abstract The bounding rectangle of the receiver. @discussion The value of this property is a CGRect representing the bounding rectangle of the object with respect to the picture in which it resides. The rectangle's origin is top left. If the metadata originates from video, bounds may be expressed as scalar values from 0. - 1. If the original video has been scaled down, the bounds of the metadata object still are meaningful. This property may return CGRectZero if the metadata has no bounds.

func (*AVMetadataObject) CinematicVideoFocusMode ¶

func (o *AVMetadataObject) CinematicVideoFocusMode() AVCaptureCinematicVideoFocusMode

The current focus mode when an object is detected during a Cinematic Video recording. Default is “AVCaptureCinematicVideoFocusMode/AVCaptureCinematicVideoFocusModeNone“.

func (*AVMetadataObject) Duration ¶

func (o *AVMetadataObject) Duration() coremedia.CMTime

@property duration @abstract The media duration associated with this metadata object. @discussion The value of this property is a CMTime representing the duration of the metadata object. If this metadata object originates from a CMSampleBuffer, its duration matches the sample buffer's duration. This property may return kCMTimeInvalid.

func (*AVMetadataObject) GroupID ¶

func (o *AVMetadataObject) GroupID() int

An identifier associated with a metadata object used to group it with other metadata objects belonging to a common parent. When presented with a collection of “AVMetadataObject“ instances of different types, you may use the objects' “groupID“ to combine them into groups. For example, a human body and face belonging to the same person have the same “groupID“. If an object's “groupID“ property is set to -1, it is invalid. When set to a value of >=0, it is unique across all object groups.

func (*AVMetadataObject) IsFixedFocus ¶

func (o *AVMetadataObject) IsFixedFocus() bool

A BOOL indicating whether this metadata object represents a fixed focus.

func (*AVMetadataObject) ObjectID ¶

func (o *AVMetadataObject) ObjectID() int

A unique identifier for each detected object type (face, body, hands, heads and salient objects) in a collection. Defaults to a value of -1 when invalid or not available. When used in conjunction with an “AVCaptureMetadataOutput“, each newly detected object that enters the scene is assigned a unique identifier. “objectID“s are never re-used as objects leave the picture and new ones enter. Objects that leave the picture and then re-enter are assigned a new “objectID“.

func (*AVMetadataObject) Time ¶

func (o *AVMetadataObject) Time() coremedia.CMTime

@property time @abstract The media time associated with this metadata object. @discussion The value of this property is a CMTime associated with the metadata object. For capture, it is the time at which this object was captured. If this metadata object originates from a CMSampleBuffer, its time matches the sample buffer's presentation time. This property may return kCMTimeInvalid.

func (*AVMetadataObject) Type ¶

@property type @abstract An identifier for the metadata object. @discussion The value of this property is an AVMetadataObjectType representing the type of the metadata object. Clients inspecting a collection of metadata objects can use this property to filter objects with a matching type.

type AVMetricContentKeyRequestEvent ¶

type AVMetricContentKeyRequestEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetriccontentkeyrequestevent

func AVMetricContentKeyRequestEventFromID ¶

func AVMetricContentKeyRequestEventFromID(id objc.ID) *AVMetricContentKeyRequestEvent

func (*AVMetricContentKeyRequestEvent) ContentKeySpecifier ¶

func (o *AVMetricContentKeyRequestEvent) ContentKeySpecifier() *AVContentKeySpecifier

Returns the content key specifier for the request.

func (*AVMetricContentKeyRequestEvent) IsClientInitiated ¶

func (o *AVMetricContentKeyRequestEvent) IsClientInitiated() bool

Returns whether the content key resource request was initiated by the client.

func (*AVMetricContentKeyRequestEvent) MediaResourceRequestEvent ¶

func (o *AVMetricContentKeyRequestEvent) MediaResourceRequestEvent() *AVMetricMediaResourceRequestEvent

Returns the media resource request event which was used to satisfy the content key.

func (*AVMetricContentKeyRequestEvent) MediaType ¶

Returns the media type. If the value cannot be determined, returns AVMediaTypeMuxed.

type AVMetricDownloadSummaryEvent ¶

type AVMetricDownloadSummaryEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricdownloadsummaryevent

func AVMetricDownloadSummaryEventFromID ¶

func AVMetricDownloadSummaryEventFromID(id objc.ID) *AVMetricDownloadSummaryEvent

func (*AVMetricDownloadSummaryEvent) BytesDownloadedCount ¶

func (o *AVMetricDownloadSummaryEvent) BytesDownloadedCount() int

Returns the total number of bytes downloaded by the download task.

func (*AVMetricDownloadSummaryEvent) DownloadDuration ¶

func (o *AVMetricDownloadSummaryEvent) DownloadDuration() float64

Returns the total duration of the download in seconds.

func (*AVMetricDownloadSummaryEvent) ErrorEvent ¶

Returns the error event if any. If no value is available, returns nil.

func (*AVMetricDownloadSummaryEvent) MediaResourceRequestCount ¶

func (o *AVMetricDownloadSummaryEvent) MediaResourceRequestCount() int

Returns the total number of media requests performed by the download task. This includes playlist requests, media segment requests, and content key requests.

func (*AVMetricDownloadSummaryEvent) RecoverableErrorCount ¶

func (o *AVMetricDownloadSummaryEvent) RecoverableErrorCount() int

Returns the total count of recoverable errors encountered during the download. If no errors were encountered, returns 0. Error counts may not be consistent across OS versions. Comparisons should be made within a given OS version, as error reporting is subject to change with OS updates.

func (*AVMetricDownloadSummaryEvent) Variants ¶

Returns the variants that were downloaded.

type AVMetricErrorEvent ¶

type AVMetricErrorEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricerrorevent

func AVMetricErrorEventFromID ¶

func AVMetricErrorEventFromID(id objc.ID) *AVMetricErrorEvent

func (*AVMetricErrorEvent) DidRecover ¶

func (o *AVMetricErrorEvent) DidRecover() bool

Returns whether the error was recoverable.

func (*AVMetricErrorEvent) Error ¶

func (o *AVMetricErrorEvent) Error() unsafe.Pointer

Returns the error encountered.

type AVMetricEvent ¶

type AVMetricEvent struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricevent

func AVMetricEventFromID ¶

func AVMetricEventFromID(id objc.ID) *AVMetricEvent

func (*AVMetricEvent) Date ¶

func (o *AVMetricEvent) Date() *foundation.NSDate

Returns the date when the event occurred.

func (*AVMetricEvent) MediaTime ¶

func (o *AVMetricEvent) MediaTime() coremedia.CMTime

Returns the time in the media timeline when the event occured.

func (*AVMetricEvent) SessionID ¶

func (o *AVMetricEvent) SessionID() *foundation.NSString

A GUID that identifies the media session. If not available, value is nil.

type AVMetricEventStream ¶

type AVMetricEventStream struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetriceventstream

func AVMetricEventStreamEventStream ¶

func AVMetricEventStreamEventStream() *AVMetricEventStream

Returns an autoreleased instance.

func AVMetricEventStreamFromID ¶

func AVMetricEventStreamFromID(id objc.ID) *AVMetricEventStream

func (*AVMetricEventStream) AddPublisher ¶

func (o *AVMetricEventStream) AddPublisher(publisher AVMetricEventStreamPublisher) bool

The publisher should be an AVFoundation instance conforming to AVMetricEventStreamPublisher.

func (*AVMetricEventStream) SetSubscriberQueue ¶

func (o *AVMetricEventStream) SetSubscriberQueue(subscriber AVMetricEventStreamSubscriber, queue *foundation.NSObject) bool

Set a subscriber delegate. - Parameter subscriber: A subscriber delegate object conforming to AVMetricEventStreamSubscriber. - Parameter queue: Dispatch queue for the delegate callbacks.

func (*AVMetricEventStream) SubscribeToAllMetricEvents ¶

func (o *AVMetricEventStream) SubscribeToAllMetricEvents()

Subscribe to all metric event classes.

func (*AVMetricEventStream) SubscribeToMetricEvent ¶

func (o *AVMetricEventStream) SubscribeToMetricEvent(metricEventClass objc.Class)

Subscribe to a specific metric event class. - Parameter metricEventClass: Type of metric event class to subscribe to.

func (*AVMetricEventStream) SubscribeToMetricEvents ¶

func (o *AVMetricEventStream) SubscribeToMetricEvents(metricEventClasses *foundation.NSArray[objc.Class])

Subscribe to set of metric event classes. - Parameter metricEventClasses: Set of metric event classes to subscribe to.

type AVMetricEventStreamPublisher ¶

type AVMetricEventStreamPublisher interface {
}

AVMetricEventStreamPublisher wraps the ObjC protocol AVMetricEventStreamPublisher.

type AVMetricEventStreamSubscriber ¶

type AVMetricEventStreamSubscriber interface {
	PublisherDidReceiveEvent(publisher AVMetricEventStreamPublisher, event *AVMetricEvent)
}

AVMetricEventStreamSubscriber wraps the ObjC protocol AVMetricEventStreamSubscriber.

type AVMetricHLSMediaSegmentRequestEvent ¶

type AVMetricHLSMediaSegmentRequestEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetrichlsmediasegmentrequestevent

func AVMetricHLSMediaSegmentRequestEventFromID ¶

func AVMetricHLSMediaSegmentRequestEventFromID(id objc.ID) *AVMetricHLSMediaSegmentRequestEvent

func (*AVMetricHLSMediaSegmentRequestEvent) ByteRange ¶

Returns the byte range for the media segment. If not available, the range start and end will be 0.

func (*AVMetricHLSMediaSegmentRequestEvent) IndexFileURL ¶

Returns the URL of the index file in which this segment was declared. If not available, returns nil.

func (*AVMetricHLSMediaSegmentRequestEvent) IsMapSegment ¶

func (o *AVMetricHLSMediaSegmentRequestEvent) IsMapSegment() bool

Returns true if the media segment request is for a map segment.

func (*AVMetricHLSMediaSegmentRequestEvent) MediaResourceRequestEvent ¶

Returns the media resource request event which was used to satisfy the media segment.

func (*AVMetricHLSMediaSegmentRequestEvent) MediaType ¶

Returns the media type. If the value cannot be determined, returns AVMediaTypeMuxed.

func (*AVMetricHLSMediaSegmentRequestEvent) SegmentDuration ¶

func (o *AVMetricHLSMediaSegmentRequestEvent) SegmentDuration() float64

Returns the duration of segment in seconds.

func (*AVMetricHLSMediaSegmentRequestEvent) Url ¶

Returns the URL of the media segment. If no value is available, returns nil.

type AVMetricHLSPlaylistRequestEvent ¶

type AVMetricHLSPlaylistRequestEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetrichlsplaylistrequestevent

func AVMetricHLSPlaylistRequestEventFromID ¶

func AVMetricHLSPlaylistRequestEventFromID(id objc.ID) *AVMetricHLSPlaylistRequestEvent

func (*AVMetricHLSPlaylistRequestEvent) IsMultivariantPlaylist ¶

func (o *AVMetricHLSPlaylistRequestEvent) IsMultivariantPlaylist() bool

Returns true if the playlist request is for a multivariant playlist.

func (*AVMetricHLSPlaylistRequestEvent) MediaResourceRequestEvent ¶

Returns the media resource request event which was used to satisfy the playlist.

func (*AVMetricHLSPlaylistRequestEvent) MediaType ¶

Returns the media type. If the value cannot be determined, returns AVMediaTypeMuxed.

func (*AVMetricHLSPlaylistRequestEvent) Url ¶

Returns the URL of the playlist. If no value is available, returns nil.

type AVMetricMediaRendition ¶

type AVMetricMediaRendition struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricmediarendition

func AVMetricMediaRenditionFromID ¶

func AVMetricMediaRenditionFromID(id objc.ID) *AVMetricMediaRendition

func (*AVMetricMediaRendition) StableID ¶

@property stableID @abstract Provides ID corresponding to the rendition. This is equivalent to the STABLE-RENDITION-ID in the HLS playlist. If not available, value is nil.

func (*AVMetricMediaRendition) URL ¶

@property URL @abstract Provides URL corresponding to the rendition's HLS playlist. If not available, value is nil.

type AVMetricMediaResourceRequestEvent ¶

type AVMetricMediaResourceRequestEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricmediaresourcerequestevent

func AVMetricMediaResourceRequestEventFromID ¶

func AVMetricMediaResourceRequestEventFromID(id objc.ID) *AVMetricMediaResourceRequestEvent

func (*AVMetricMediaResourceRequestEvent) ByteRange ¶

Returns the byte range downloaded for the resource request. If not available, the range start and end will be 0.

func (*AVMetricMediaResourceRequestEvent) ErrorEvent ¶

Returns the error event, if any, encountered during the resource request. If no value is present, returns nil.

func (*AVMetricMediaResourceRequestEvent) NetworkTransactionMetrics ¶

Returns the NSURLSessionTaskMetrics associated with the resource request. If no value is present, returns nil

func (*AVMetricMediaResourceRequestEvent) RequestEndTime ¶

Returns the end time of the resource request.

func (*AVMetricMediaResourceRequestEvent) RequestStartTime ¶

func (o *AVMetricMediaResourceRequestEvent) RequestStartTime() *foundation.NSDate

Returns the start time of the resource request.

func (*AVMetricMediaResourceRequestEvent) ResponseEndTime ¶

func (o *AVMetricMediaResourceRequestEvent) ResponseEndTime() *foundation.NSDate

Returns the end time of the resource request response.

func (*AVMetricMediaResourceRequestEvent) ResponseStartTime ¶

func (o *AVMetricMediaResourceRequestEvent) ResponseStartTime() *foundation.NSDate

Returns the start time of the resource request response.

func (*AVMetricMediaResourceRequestEvent) ServerAddress ¶

The IP address of the server. If not available, the value is nil.

func (*AVMetricMediaResourceRequestEvent) Url ¶

Returns the URL of the resource request. If no value is available, returns nil.

func (*AVMetricMediaResourceRequestEvent) WasReadFromCache ¶

func (o *AVMetricMediaResourceRequestEvent) WasReadFromCache() bool

Returns true if the resource was read from the cache.

type AVMetricPlayerItemInitialLikelyToKeepUpEvent ¶

type AVMetricPlayerItemInitialLikelyToKeepUpEvent struct {
	AVMetricPlayerItemLikelyToKeepUpEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeriteminitiallikelytokeepupevent

func AVMetricPlayerItemInitialLikelyToKeepUpEventFromID ¶

func AVMetricPlayerItemInitialLikelyToKeepUpEventFromID(id objc.ID) *AVMetricPlayerItemInitialLikelyToKeepUpEvent

func (*AVMetricPlayerItemInitialLikelyToKeepUpEvent) ContentKeyRequestEvents ¶

Returns the content key request required to reach likely to keep up.

func (*AVMetricPlayerItemInitialLikelyToKeepUpEvent) MediaSegmentRequestEvents ¶

Returns the media segment request events required to reach likely to keep up.

func (*AVMetricPlayerItemInitialLikelyToKeepUpEvent) PlaylistRequestEvents ¶

Returns the playlist request events required to reach likely to keep up.

type AVMetricPlayerItemLikelyToKeepUpEvent ¶

type AVMetricPlayerItemLikelyToKeepUpEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeritemlikelytokeepupevent

func AVMetricPlayerItemLikelyToKeepUpEventFromID ¶

func AVMetricPlayerItemLikelyToKeepUpEventFromID(id objc.ID) *AVMetricPlayerItemLikelyToKeepUpEvent

func (*AVMetricPlayerItemLikelyToKeepUpEvent) LoadedTimeRanges ¶

This property provides a collection of time ranges for which the player has the media data readily available. The ranges provided might be discontinuous. Returns an NSArray of NSValues containing CMTimeRanges.

func (*AVMetricPlayerItemLikelyToKeepUpEvent) TimeTaken ¶

Returns the total time taken to reach likely to keep up.

func (*AVMetricPlayerItemLikelyToKeepUpEvent) Variant ¶

Returns the variant selected at the time likely to keep up is achieved. If no value is present, returns nil.

type AVMetricPlayerItemPlaybackSummaryEvent ¶

type AVMetricPlayerItemPlaybackSummaryEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeritemplaybacksummaryevent

func AVMetricPlayerItemPlaybackSummaryEventFromID ¶

func AVMetricPlayerItemPlaybackSummaryEventFromID(id objc.ID) *AVMetricPlayerItemPlaybackSummaryEvent

func (*AVMetricPlayerItemPlaybackSummaryEvent) ErrorEvent ¶

Returns the error event if any. If no value is available, returns nil.

func (*AVMetricPlayerItemPlaybackSummaryEvent) MediaResourceRequestCount ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) MediaResourceRequestCount() int

Returns the total number of media requests performed by the player. This includes playlist requests, media segment requests, and content key requests.

func (*AVMetricPlayerItemPlaybackSummaryEvent) PlaybackDuration ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) PlaybackDuration() int

Returns the total duration of playback in seconds.

func (*AVMetricPlayerItemPlaybackSummaryEvent) RecoverableErrorCount ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) RecoverableErrorCount() int

Returns the total count of recoverable errors encountered during playback. If no errors were encountered, returns 0.

func (*AVMetricPlayerItemPlaybackSummaryEvent) StallCount ¶

Returns the total count of stalls encountered during playback. If no stalls were encountered, returns 0.

func (*AVMetricPlayerItemPlaybackSummaryEvent) TimeSpentInInitialStartup ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) TimeSpentInInitialStartup() float64

Returns the total time spent in initial startup of playback.

func (*AVMetricPlayerItemPlaybackSummaryEvent) TimeSpentRecoveringFromStall ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) TimeSpentRecoveringFromStall() float64

Returns the total time spent recovering from a stall event.

func (*AVMetricPlayerItemPlaybackSummaryEvent) TimeWeightedAverageBitrate ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) TimeWeightedAverageBitrate() int

Returns the playtime weighted average bitrate played in bits / second.

func (*AVMetricPlayerItemPlaybackSummaryEvent) TimeWeightedPeakBitrate ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) TimeWeightedPeakBitrate() int

Returns the playtime weighted peak bitrate played in bits / second.

func (*AVMetricPlayerItemPlaybackSummaryEvent) VariantSwitchCount ¶

func (o *AVMetricPlayerItemPlaybackSummaryEvent) VariantSwitchCount() int

Returns the total count of variant switch encountered during playback.

type AVMetricPlayerItemRateChangeEvent ¶

type AVMetricPlayerItemRateChangeEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeritemratechangeevent

func AVMetricPlayerItemRateChangeEventFromID ¶

func AVMetricPlayerItemRateChangeEventFromID(id objc.ID) *AVMetricPlayerItemRateChangeEvent

func (*AVMetricPlayerItemRateChangeEvent) PreviousRate ¶

func (o *AVMetricPlayerItemRateChangeEvent) PreviousRate() float64

Returns the playback rate before the rate change event.

func (*AVMetricPlayerItemRateChangeEvent) Rate ¶

Returns the playback rate after the rate change event.

func (*AVMetricPlayerItemRateChangeEvent) Variant ¶

Returns the variant being played at the time of rate change. If no value is present, returns nil.

type AVMetricPlayerItemSeekDidCompleteEvent ¶

type AVMetricPlayerItemSeekDidCompleteEvent struct {
	AVMetricPlayerItemRateChangeEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeritemseekdidcompleteevent

func AVMetricPlayerItemSeekDidCompleteEventFromID ¶

func AVMetricPlayerItemSeekDidCompleteEventFromID(id objc.ID) *AVMetricPlayerItemSeekDidCompleteEvent

func (*AVMetricPlayerItemSeekDidCompleteEvent) DidSeekInBuffer ¶

func (o *AVMetricPlayerItemSeekDidCompleteEvent) DidSeekInBuffer() bool

type AVMetricPlayerItemVariantSwitchEvent ¶

type AVMetricPlayerItemVariantSwitchEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeritemvariantswitchevent

func AVMetricPlayerItemVariantSwitchEventFromID ¶

func AVMetricPlayerItemVariantSwitchEventFromID(id objc.ID) *AVMetricPlayerItemVariantSwitchEvent

func (*AVMetricPlayerItemVariantSwitchEvent) AudioRendition ¶

Represents the currently selected video rendition's identifiers. Subclasses of this type that are used from Swift must fulfill the requirements of a Sendable type.

func (*AVMetricPlayerItemVariantSwitchEvent) DidSucceed ¶

Returns if the switch did succeed.

func (*AVMetricPlayerItemVariantSwitchEvent) FromVariant ¶

Returns the variant before the switch. If no value is available, returns nil

func (*AVMetricPlayerItemVariantSwitchEvent) LoadedTimeRanges ¶

This property provides a collection of time ranges for which the player has the media data readily available. The ranges provided might be discontinuous. Returns an NSArray of NSValues containing CMTimeRanges.

func (*AVMetricPlayerItemVariantSwitchEvent) SubtitleRendition ¶

Represents the currently selected audio rendition's identifiers. Subclasses of this type that are used from Swift must fulfill the requirements of a Sendable type.

func (*AVMetricPlayerItemVariantSwitchEvent) ToVariant ¶

Returns the variant after the switch.

func (*AVMetricPlayerItemVariantSwitchEvent) VideoRendition ¶

Represents the currently selected video rendition's identifiers. Subclasses of this type that are used from Swift must fulfill the requirements of a Sendable type.

type AVMetricPlayerItemVariantSwitchStartEvent ¶

type AVMetricPlayerItemVariantSwitchStartEvent struct {
	AVMetricEvent
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmetricplayeritemvariantswitchstartevent

func AVMetricPlayerItemVariantSwitchStartEventFromID ¶

func AVMetricPlayerItemVariantSwitchStartEventFromID(id objc.ID) *AVMetricPlayerItemVariantSwitchStartEvent

func (*AVMetricPlayerItemVariantSwitchStartEvent) AudioRendition ¶

@property audioRendition @abstract Contains information corresponding to the currently selected audio rendition.

func (*AVMetricPlayerItemVariantSwitchStartEvent) FromVariant ¶

Returns the variant from which the switch is attempted. If no value is available, returns nil

func (*AVMetricPlayerItemVariantSwitchStartEvent) LoadedTimeRanges ¶

This property provides a collection of time ranges for which the player has the media data readily available. The ranges provided might be discontinuous. Returns an NSArray of NSValues containing CMTimeRanges.

func (*AVMetricPlayerItemVariantSwitchStartEvent) SubtitleRendition ¶

@property subtitleRendition @abstract Contains information corresponding to the currently selected subtitle rendition.

func (*AVMetricPlayerItemVariantSwitchStartEvent) ToVariant ¶

Returns the variant to which the switch is attempted.

func (*AVMetricPlayerItemVariantSwitchStartEvent) VideoRendition ¶

@property videoRendition @abstract Contains information corresponding to the currently selected video rendition.

type AVMovie ¶

type AVMovie struct {
	AVAsset
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmovie

func AVMovieFromID ¶

func AVMovieFromID(id objc.ID) *AVMovie

func AVMovieMovieWithDataOptions ¶

func AVMovieMovieWithDataOptions(data *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVMovie

@method movieWithData:options: @abstract Creates an AVMovie object from a movie header stored in an NSData object. @param data An NSData object containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMovie object. @result An AVMovie object @discussion You can use this method to operate on movie headers that are not stored in files; this might include movie headers on the pasteboard (which do not contain media data). In general you should avoid loading an entire movie file with its media data into an instance of NSData! By default, the defaultMediaDataStorage property will be nil and each associated AVMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from an NSData object and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func AVMovieMovieWithURLOptions ¶

func AVMovieMovieWithURLOptions(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVMovie

@method movieWithURL:options: @abstract Creates an AVMovie object from a movie header stored in a QuickTime movie file or ISO base media file. @param URL An NSURL object that specifies a file containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMovie object. @result An AVMovie object @discussion By default, the defaultMediaDataStorage property will be nil and each associated AVMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from a file and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMovie) CanContainMovieFragments ¶

func (o *AVMovie) CanContainMovieFragments() bool

@property canContainMovieFragments @abstract Indicates whether the movie file is capable of being extended by fragments. @discussion The value of this property is YES if an 'mvex' box is present in the 'moov' box. The 'mvex' box is necessary in order to signal the possible presence of later 'moof' boxes.

func (*AVMovie) ContainsMovieFragments ¶

func (o *AVMovie) ContainsMovieFragments() bool

@property containsMovieFragments @abstract Indicates whether the movie file is extended by at least one movie fragment. @discussion The value of this property is YES if canContainMovieFragments is YES and at least one 'moof' box is present after the 'moov' box.

func (*AVMovie) Data ¶

func (o *AVMovie) Data() *foundation.NSData

@property data @abstract The data block with which the instance of AVMovie was initialized; may be nil.

func (*AVMovie) DefaultMediaDataStorage ¶

func (o *AVMovie) DefaultMediaDataStorage() *AVMediaDataStorage

@property defaultMediaDataStorage @abstract The default storage container for media data added to a movie. @discussion The value of this property is an AVMediaDataStorage object that indicates where sample data that is added to a movie should be written by default.

func (*AVMovie) InitWithDataOptions ¶

func (o *AVMovie) InitWithDataOptions(data *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVMovie

@method initWithData:options: @abstract Creates an AVMovie object from a movie header stored in an NSData object. @param data An NSData object containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMovie object. @result An AVMovie object @discussion You can use this method to operate on movie headers that are not stored in files. In general you should avoid loading an entire movie file with its media data into an instance of NSData! By default, the defaultMediaDataStorage property will be nil and each associated AVMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from an NSData object and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMovie) InitWithURLOptions ¶

func (o *AVMovie) InitWithURLOptions(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVMovie

@method initWithURL:options: @abstract Creates an AVMovie object from a movie header stored in a QuickTime movie file or ISO base media file. @param URL An NSURL object that specifies a file containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMovie object. @result An AVMovie object @discussion By default, the defaultMediaDataStorage property will be nil and each associated AVMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from a file and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMovie) IsCompatibleWithFileType ¶

func (o *AVMovie) IsCompatibleWithFileType(fileType *foundation.NSString) bool

@method isCompatibleWithFileType: @abstract Indicates whether a movie header for the AVMovie object can be created for the specified file type. @param fileType A UTI indicating a movie file format (e.g. AVFileTypeQuickTimeMovie for a QuickTime movie). @discussion This method returns a BOOL that indicates whether a movie header of the specified type can be created for the receiver. For example, this method returns NO if the movie contains tracks whose media types or media subtypes are not allowed by the specified file type.

func (*AVMovie) MovieHeaderWithFileTypeError ¶

func (o *AVMovie) MovieHeaderWithFileTypeError(fileType *foundation.NSString) (*foundation.NSData, error)

@method movieHeaderWithFileType:error: @abstract Creates an NSData object containing the movie header of the AVMovie object. @param fileType A UTI indicating the specific file format of the movie header (e.g. AVFileTypeQuickTimeMovie for a QuickTime movie). @param outError If an error occurs reading the movie header, describes the nature of the failure. @result An NSData object. @discussion The movie header will be a pure reference movie, with no base URL, suitable for use on the pasteboard.

func (*AVMovie) URL ¶

func (o *AVMovie) URL() *foundation.NSURL

@property URL @abstract The URL with which the instance of AVMovie was initialized; may be nil.

func (*AVMovie) WriteMovieHeaderToURLFileTypeOptionsError ¶

func (o *AVMovie) WriteMovieHeaderToURLFileTypeOptionsError(uRL *foundation.NSURL, fileType *foundation.NSString, options AVMovieWritingOptions) (bool, error)

@method writeMovieHeaderToURL:fileType:options:error: @abstract Writes the movie header to a destination URL. @param URL An NSURL object indicating where to write the movie header. @param fileType A UTI indicating the specific file format (e.g. AVFileTypeQuickTimeMovie for a QuickTime movie). @param options An NSUInteger whose bits specify options for the writing of the movie header. See AVMovieWritingOptions above. @param outError If an error occurs writing the movie header, describes the nature of the failure. @discussion Note that modifications to instances of AVMutableMovie, to their constituent AVMutableMovieTracks, or to their collections of metadata are committed to storage when their movie headers are written.

type AVMovieTrack ¶

type AVMovieTrack struct {
	AVAssetTrack
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmovietrack

func AVMovieTrackFromID ¶

func AVMovieTrackFromID(id objc.ID) *AVMovieTrack

func (*AVMovieTrack) AlternateGroupID ¶

func (o *AVMovieTrack) AlternateGroupID() int

func (*AVMovieTrack) MediaDataStorage ¶

func (o *AVMovieTrack) MediaDataStorage() *AVMediaDataStorage

func (*AVMovieTrack) MediaDecodeTimeRange ¶

func (o *AVMovieTrack) MediaDecodeTimeRange() coremedia.CMTimeRange

@property mediaDecodeTimeRange @abstract A CMTimeRange indicating the range of decode times for the track's media.

func (*AVMovieTrack) MediaPresentationTimeRange ¶

func (o *AVMovieTrack) MediaPresentationTimeRange() coremedia.CMTimeRange

@property mediaPresentationTimeRange @abstract A CMTimeRange indicating the range of presentation times for the track's media.

type AVMovieWritingOptions ¶

type AVMovieWritingOptions uint64
const (
	AVMovieWritingAddMovieHeaderToDestination          AVMovieWritingOptions = 0
	AVMovieWritingTruncateDestinationToMovieHeaderOnly AVMovieWritingOptions = 1
)

func (AVMovieWritingOptions) String ¶

func (e AVMovieWritingOptions) String() string

type AVMutableAssetDownloadStorageManagementPolicy ¶

type AVMutableAssetDownloadStorageManagementPolicy struct {
	AVAssetDownloadStorageManagementPolicy
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutableassetdownloadstoragemanagementpolicy

func AVMutableAssetDownloadStorageManagementPolicyFromID ¶

func AVMutableAssetDownloadStorageManagementPolicyFromID(id objc.ID) *AVMutableAssetDownloadStorageManagementPolicy

func (*AVMutableAssetDownloadStorageManagementPolicy) SetExpirationDate ¶

func (o *AVMutableAssetDownloadStorageManagementPolicy) SetExpirationDate(expirationDate *foundation.NSDate)

func (*AVMutableAssetDownloadStorageManagementPolicy) SetPriority ¶

type AVMutableAudioMix ¶

type AVMutableAudioMix struct {
	AVAudioMix
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutableaudiomix

func AVMutableAudioMixAudioMix ¶

func AVMutableAudioMixAudioMix() *AVMutableAudioMix

func AVMutableAudioMixFromID ¶

func AVMutableAudioMixFromID(id objc.ID) *AVMutableAudioMix

func (*AVMutableAudioMix) SetInputParameters ¶

func (o *AVMutableAudioMix) SetInputParameters(inputParameters *foundation.NSArray[*AVAudioMixInputParameters])

type AVMutableAudioMixInputParameters ¶

type AVMutableAudioMixInputParameters struct {
	AVAudioMixInputParameters
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutableaudiomixinputparameters

func AVMutableAudioMixInputParametersAudioMixInputParameters ¶

func AVMutableAudioMixInputParametersAudioMixInputParameters() *AVMutableAudioMixInputParameters

func AVMutableAudioMixInputParametersAudioMixInputParametersWithTrack ¶

func AVMutableAudioMixInputParametersAudioMixInputParametersWithTrack(track *AVAssetTrack) *AVMutableAudioMixInputParameters

func AVMutableAudioMixInputParametersFromID ¶

func AVMutableAudioMixInputParametersFromID(id objc.ID) *AVMutableAudioMixInputParameters

func (*AVMutableAudioMixInputParameters) SetAudioTapProcessor ¶

func (o *AVMutableAudioMixInputParameters) SetAudioTapProcessor(audioTapProcessor unsafe.Pointer)

func (*AVMutableAudioMixInputParameters) SetAudioTimePitchAlgorithm ¶

func (o *AVMutableAudioMixInputParameters) SetAudioTimePitchAlgorithm(audioTimePitchAlgorithm *foundation.NSString)

func (*AVMutableAudioMixInputParameters) SetTrackID ¶

func (o *AVMutableAudioMixInputParameters) SetTrackID(trackID int32)

func (*AVMutableAudioMixInputParameters) SetVolumeAtTime ¶

func (o *AVMutableAudioMixInputParameters) SetVolumeAtTime(volume float32, time_ coremedia.CMTime)

func (*AVMutableAudioMixInputParameters) SetVolumeRampFromStartVolumeToEndVolumeTimeRange ¶

func (o *AVMutableAudioMixInputParameters) SetVolumeRampFromStartVolumeToEndVolumeTimeRange(startVolume float32, endVolume float32, timeRange coremedia.CMTimeRange)

type AVMutableCaption ¶

type AVMutableCaption struct {
	AVCaption
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablecaption

func AVMutableCaptionFromID ¶

func AVMutableCaptionFromID(id objc.ID) *AVMutableCaption

func (*AVMutableCaption) RemoveBackgroundColorInRange ¶

func (o *AVMutableCaption) RemoveBackgroundColorInRange(range_ foundation.NSRange)

@method removeBackgroundColorInRange: @abstract Remove background color for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) RemoveDecorationInRange ¶

func (o *AVMutableCaption) RemoveDecorationInRange(range_ foundation.NSRange)

@method removeDecorationInRange: @abstract Remove text decoration for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) RemoveFontStyleInRange ¶

func (o *AVMutableCaption) RemoveFontStyleInRange(range_ foundation.NSRange)

@method removeFontStyleInRange: @abstract Remove font style for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) RemoveFontWeightInRange ¶

func (o *AVMutableCaption) RemoveFontWeightInRange(range_ foundation.NSRange)

@method removeFontWeightInRange: @abstract Remove font weight for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) RemoveRubyInRange ¶

func (o *AVMutableCaption) RemoveRubyInRange(range_ foundation.NSRange)

@method removeRubyInRange: @abstract Remove ruby text for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) RemoveTextColorInRange ¶

func (o *AVMutableCaption) RemoveTextColorInRange(range_ foundation.NSRange)

@method removeTextColorInRange: @abstract Remove text color for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) RemoveTextCombineInRange ¶

func (o *AVMutableCaption) RemoveTextCombineInRange(range_ foundation.NSRange)

@method removeTextCombineInRange: @abstract Remove text combine for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetAnimation ¶

func (o *AVMutableCaption) SetAnimation(animation AVCaptionAnimation)

func (*AVMutableCaption) SetBackgroundColorInRange ¶

func (o *AVMutableCaption) SetBackgroundColorInRange(color unsafe.Pointer, range_ foundation.NSRange)

@method setBackgroundColor:inRange: @abstract Set background color for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetDecorationInRange ¶

func (o *AVMutableCaption) SetDecorationInRange(decoration AVCaptionDecoration, range_ foundation.NSRange)

@method setDecoration:inRange: @abstract Set text decoration for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetFontStyleInRange ¶

func (o *AVMutableCaption) SetFontStyleInRange(fontStyle AVCaptionFontStyle, range_ foundation.NSRange)

@method setFontStyle:inRange: @abstract Set font style for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetFontWeightInRange ¶

func (o *AVMutableCaption) SetFontWeightInRange(fontWeight AVCaptionFontWeight, range_ foundation.NSRange)

@method setFontWeight:inRange: @abstract Set font weight for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetRegion ¶

func (o *AVMutableCaption) SetRegion(region *AVCaptionRegion)

func (*AVMutableCaption) SetRubyInRange ¶

func (o *AVMutableCaption) SetRubyInRange(ruby *AVCaptionRuby, range_ foundation.NSRange)

@method setRuby:inRange: @abstract Set ruby text for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetText ¶

func (o *AVMutableCaption) SetText(text *foundation.NSString)

func (*AVMutableCaption) SetTextAlignment ¶

func (o *AVMutableCaption) SetTextAlignment(textAlignment AVCaptionTextAlignment)

func (*AVMutableCaption) SetTextColorInRange ¶

func (o *AVMutableCaption) SetTextColorInRange(color unsafe.Pointer, range_ foundation.NSRange)

@method setTextColor:inRange: @abstract Set text color for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetTextCombineInRange ¶

func (o *AVMutableCaption) SetTextCombineInRange(textCombine AVCaptionTextCombine, range_ foundation.NSRange)

@method setTextCombine:inRange: @abstract Set text combine for the range. @discussion The range parameter uses UTF-16 code unit index range.

func (*AVMutableCaption) SetTimeRange ¶

func (o *AVMutableCaption) SetTimeRange(timeRange coremedia.CMTimeRange)

type AVMutableCaptionRegion ¶

type AVMutableCaptionRegion struct {
	AVCaptionRegion
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablecaptionregion

func AVMutableCaptionRegionFromID ¶

func AVMutableCaptionRegionFromID(id objc.ID) *AVMutableCaptionRegion

func (*AVMutableCaptionRegion) Init ¶

@method init @abstract Create a region object without any properties.

func (*AVMutableCaptionRegion) InitWithIdentifier ¶

func (o *AVMutableCaptionRegion) InitWithIdentifier(identifier *foundation.NSString) *AVMutableCaptionRegion

@method initWithIdentifier: @abstract Create a region object with the identifier.

func (*AVMutableCaptionRegion) SetDisplayAlignment ¶

func (o *AVMutableCaptionRegion) SetDisplayAlignment(displayAlignment AVCaptionRegionDisplayAlignment)

func (*AVMutableCaptionRegion) SetOrigin ¶

func (o *AVMutableCaptionRegion) SetOrigin(origin AVCaptionPoint)

func (*AVMutableCaptionRegion) SetScroll ¶

func (o *AVMutableCaptionRegion) SetScroll(scroll AVCaptionRegionScroll)

func (*AVMutableCaptionRegion) SetSize ¶

func (o *AVMutableCaptionRegion) SetSize(size AVCaptionSize)

func (*AVMutableCaptionRegion) SetWritingMode ¶

func (o *AVMutableCaptionRegion) SetWritingMode(writingMode AVCaptionRegionWritingMode)

type AVMutableComposition ¶

type AVMutableComposition struct {
	AVComposition
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablecomposition

func AVMutableCompositionComposition ¶

func AVMutableCompositionComposition() *AVMutableComposition

@method composition @abstract Returns an empty AVMutableComposition.

func AVMutableCompositionCompositionWithURLAssetInitializationOptions ¶

func AVMutableCompositionCompositionWithURLAssetInitializationOptions(uRLAssetInitializationOptions *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVMutableComposition

@method compositionWithURLAssetInitializationOptions: @abstract Returns an empty AVMutableComposition. @param URLAssetInitializationOptions Specifies the initialization options that the receiver should use when creating AVURLAssets internally, e.g. AVURLAssetPreferPreciseDurationAndTimingKey. The default behavior for creation of AVURLAssets by an AVMutableComposition is equivalent to the behavior of +[AVURLAsset URLAssetWithURL:options:] when specifying no initialization options. @discussion AVMutableCompositions create AVURLAssets internally for URLs specified by AVCompositionTrackSegments of AVMutableCompositionTracks, as needed, whenever AVCompositionTrackSegments are added to tracks via -[AVMutableCompositionTrack setSegments:] rather than by inserting timeranges of already existing AVAssets or AVAssetTracks.

func AVMutableCompositionFromID ¶

func AVMutableCompositionFromID(id objc.ID) *AVMutableComposition

func (*AVMutableComposition) AddMutableTrackWithMediaTypePreferredTrackID ¶

func (o *AVMutableComposition) AddMutableTrackWithMediaTypePreferredTrackID(mediaType *foundation.NSString, preferredTrackID int32) *AVMutableCompositionTrack

@method addMutableTrackWithMediaType:preferredTrackID: @abstract Adds an empty track to a mutable composition. @param mediaType The media type of the new track. @param preferredTrackID Specifies the preferred track ID for the new track. If you do not need to specify a preferred track ID, pass kCMPersistentTrackID_Invalid. Otherwise the preferred track ID will be used for the new track, provided that it is not currently in use and has not previously been used. @result An instance of AVMutableCompositionTrack representing the new track. Its actual trackID is available via its @"trackID" key. @discussion If the specified preferred track ID is not available, or kCMPersistentTrackID_Invalid was passed in, a unique track ID will be generated.

func (*AVMutableComposition) InsertEmptyTimeRange ¶

func (o *AVMutableComposition) InsertEmptyTimeRange(timeRange coremedia.CMTimeRange)

@method insertEmptyTimeRange: @abstract Adds or extends an empty timeRange within all tracks of the composition. @param timeRange Specifies the empty timeRange to be inserted. @discussion If you insert an empty timeRange into the composition, any media that was presented during that interval prior to the insertion will be presented instead immediately afterward. You can use this method to reserve an interval in which you want a subsequently created track to present its media. Note that you cannot add empty time ranges to the end of a composition.

func (*AVMutableComposition) InsertTimeRangeOfAssetAtTimeCompletionHandler ¶

func (o *AVMutableComposition) InsertTimeRangeOfAssetAtTimeCompletionHandler(timeRange coremedia.CMTimeRange, asset *AVAsset, startTime coremedia.CMTime, completionHandler func(unsafe.Pointer))

@method insertTimeRange:ofAsset:atTime:completionHandler: @abstract Inserts all the tracks of a timeRange of an asset into a composition. @param timeRange Specifies the timeRange of the asset to be inserted. @param asset Specifies the asset that contains the tracks that are to be inserted. Only instances of AVURLAsset and AVComposition are supported (AVComposition starting in macOS 10.10 and iOS 8.0). @param startTime Specifies the time at which the inserted tracks are to be presented by the composition. @param completionHandler A block that is invoked when the insertion is complete. If the error parameter is non-nil, it describes a failure that may be reported to the user, e.g. the asset that was selected for insertion in the composition is restricted by copy-protection. @discussion You provide a reference to an AVAsset and the timeRange within it that you want to insert. You specify the start time in the destination composition at which the timeRange should be inserted. This method may add new tracks to ensure that all tracks of the asset are represented in the inserted timeRange. Note that the media data for the inserted timeRange will be presented at its natural duration and rate. It can be scaled to a different duration and presented at a different rate via -scaleTimeRange:toDuration:. Existing content at the specified startTime will be pushed out by the duration of timeRange. Note that this operation only inserts one or more track segments into affected AVMutableCompositionTracks; it does not affect the values of other track properties, either to match the corresponding values of tracks in the source asset or for any other purpose.

func (*AVMutableComposition) InsertTimeRangeOfAssetAtTimeError ¶

func (o *AVMutableComposition) InsertTimeRangeOfAssetAtTimeError(timeRange coremedia.CMTimeRange, asset *AVAsset, startTime coremedia.CMTime) (bool, error)

@method insertTimeRange:ofAsset:atTime:error: @abstract Inserts all the tracks of a timeRange of an asset into a composition. @param timeRange Specifies the timeRange of the asset to be inserted. @param asset Specifies the asset that contains the tracks that are to be inserted. Only instances of AVURLAsset and AVComposition are supported (AVComposition starting in macOS 10.10 and iOS 8.0). The asset should have its tracks loaded, and the tracks should have their formatDescriptions loaded before invoking this method to avoid blocking. @param startTime Specifies the time at which the inserted tracks are to be presented by the composition. @param outError Describes failures that may be reported to the user, e.g. the asset that was selected for insertion in the composition is restricted by copy-protection. @result A BOOL value indicating the success of the insertion. @discussion You provide a reference to an AVAsset and the timeRange within it that you want to insert. You specify the start time in the destination composition at which the timeRange should be inserted. This method may add new tracks to ensure that all tracks of the asset are represented in the inserted timeRange. Note that the media data for the inserted timeRange will be presented at its natural duration and rate. It can be scaled to a different duration and presented at a different rate via -scaleTimeRange:toDuration:. Existing content at the specified startTime will be pushed out by the duration of timeRange. Note that this operation only inserts one or more track segments into affected AVMutableCompositionTracks; it does not affect the values of other track properties, either to match the corresponding values of tracks in the source asset or for any other purpose. Deprecated: since macOS 15.0.

func (*AVMutableComposition) MutableTrackCompatibleWithTrack ¶

func (o *AVMutableComposition) MutableTrackCompatibleWithTrack(track *AVAssetTrack) *AVMutableCompositionTrack

@method mutableTrackCompatibleWithTrack: @abstract Provides a reference to a track of a mutable composition into which any timeRange of an AVAssetTrack can be inserted (via -[AVMutableCompositionTrack insertTimeRange:ofTrack:atTime:error:]). @param track A reference to the AVAssetTrack from which a timeRange may be inserted. @result An AVMutableCompositionTrack that can accommodate the insertion, or, if no such track is available, nil. @discussion If a compatible track is desired but the result of this method is nil, a new track of the same mediaType as the AVAssetTrack can be created via -addMutableTrackWithMediaType:preferredTrackID:, and this new track will be compatible. For best performance, the number of tracks of a composition should be kept to a minimum, corresponding to the number for which media data must be presented in parallel. If media data of the same type is to be presented serially, even from multiple assets, a single track of that media type should be used. This method, -mutableTrackCompatibleWithTrack:, can help the client to identify an existing target track for an insertion. Similar to -[AVAsset compatibleTrackForCompositionTrack:].

func (*AVMutableComposition) RemoveTimeRange ¶

func (o *AVMutableComposition) RemoveTimeRange(timeRange coremedia.CMTimeRange)

@method removeTimeRange: @abstract Removes a specified timeRange from all tracks of the composition. @param timeRange Specifies the timeRange to be removed. @discussion Removal of a time range does not cause any existing tracks to be removed from the composition, even if removing timeRange results in an empty track. Instead, it removes or truncates track segments that intersect with the timeRange. After removing, existing content after timeRange will be pulled in.

func (*AVMutableComposition) RemoveTrack ¶

func (o *AVMutableComposition) RemoveTrack(track *AVCompositionTrack)

@method removeTrack: @abstract Removes a track of a mutable composition. @param track A reference to the AVCompositionTrack to be removed. @discussion If you retain a reference to the removed track, note that its @"composition" key will have the value nil, and the values of its other properties are undefined.

func (*AVMutableComposition) ScaleTimeRangeToDuration ¶

func (o *AVMutableComposition) ScaleTimeRangeToDuration(timeRange coremedia.CMTimeRange, duration coremedia.CMTime)

@method scaleTimeRange:toDuration: @abstract Changes the duration of a timeRange of all tracks. @param timeRange Specifies the timeRange of the composition to be scaled. @param duration Specifies the new duration of the timeRange. @discussion Each trackSegment affected by the scaling operation will be presented at a rate equal to source.duration / target.duration of its resulting timeMapping.

func (*AVMutableComposition) SetNaturalSize ¶

func (o *AVMutableComposition) SetNaturalSize(naturalSize corefoundation.CGSize)

type AVMutableCompositionTrack ¶

type AVMutableCompositionTrack struct {
	AVCompositionTrack
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablecompositiontrack

func AVMutableCompositionTrackFromID ¶

func AVMutableCompositionTrackFromID(id objc.ID) *AVMutableCompositionTrack

func (*AVMutableCompositionTrack) AddTrackAssociationToTrackType ¶

func (o *AVMutableCompositionTrack) AddTrackAssociationToTrackType(compositionTrack *AVCompositionTrack, trackAssociationType *foundation.NSString)

@method addTrackAssociationToTrack:type: @abstract Establishes a track association of a specific type between two tracks. @param compositionTrack An AVCompositionTrack object that is to be associated with the receiver. @param trackAssociationType The type of track association to add between the receiver and the specified compositionTrack (for instance, AVTrackAssociationTypeChapterList).

func (*AVMutableCompositionTrack) InsertEmptyTimeRange ¶

func (o *AVMutableCompositionTrack) InsertEmptyTimeRange(timeRange coremedia.CMTimeRange)

@method insertEmptyTimeRange: @abstract Adds or extends an empty timeRange within the composition track. @param timeRange Specifies the empty timeRange to be inserted. @discussion If you insert an empty timeRange into the track, any media that was presented during that interval prior to the insertion will be presented instead immediately afterward. The exact meaning of the term "empty timeRange" depends upon the mediaType of the track. For example, an empty timeRange in a sound track presents silence. Note that you cannot add empty time ranges to the end of a composition track.

func (*AVMutableCompositionTrack) InsertTimeRangeOfTrackAtTimeError ¶

func (o *AVMutableCompositionTrack) InsertTimeRangeOfTrackAtTimeError(timeRange coremedia.CMTimeRange, track *AVAssetTrack, startTime coremedia.CMTime) (bool, error)

@method insertTimeRange:ofTrack:atTime:error: @abstract Inserts a timeRange of a source track into a track of a composition. @param timeRange Specifies the timeRange of the track to be inserted. @param track Specifies the source track to be inserted. Only AVAssetTracks of AVURLAssets and AVCompositions are supported (AVCompositions starting in macOS 10.10 and iOS 8.0). @param startTime Specifies the time at which the inserted track is to be presented by the composition track. You may pass kCMTimeInvalid for startTime to indicate that the timeRange should be appended to the end of the track. @param error Describes failures that may be reported to the user, e.g. the asset that was selected for insertion in the composition is restricted by copy-protection. @result A BOOL value indicating the success of the insertion. @discussion You provide a reference to an AVAssetTrack and the timeRange within it that you want to insert. You specify the start time in the target composition track at which the timeRange should be inserted. Note that the inserted track timeRange will be presented at its natural duration and rate. It can be scaled to a different duration (and presented at a different rate) via -scaleTimeRange:toDuration:.

func (*AVMutableCompositionTrack) InsertTimeRangesOfTracksAtTimeError ¶

func (o *AVMutableCompositionTrack) InsertTimeRangesOfTracksAtTimeError(timeRanges *foundation.NSArray[*foundation.NSValue], tracks *foundation.NSArray[*AVAssetTrack], startTime coremedia.CMTime) (bool, error)

@method insertTimeRanges:ofTracks:atTime:error: @abstract Inserts the timeRanges of multiple source tracks into a track of a composition. @param timeRanges Specifies the timeRanges to be inserted. An NSArray of NSValues containing CMTimeRange. (See +[NSValue valueWithCMTimeRange:] in AVTime.h.) @param tracks Specifies the source tracks to be inserted. Only AVAssetTracks of AVURLAssets and AVCompositions are supported (AVCompositions starting in macOS 10.10 and iOS 8.0). @param startTime Specifies the time at which the inserted tracks are to be presented by the composition track. You may pass kCMTimeInvalid for startTime to indicate that the timeRanges should be appended to the end of the track. @param error Describes failures that may be reported to the user, e.g. the asset that was selected for insertion in the composition is restricted by copy-protection. @result A BOOL value indicating the success of the insertion. @discussion This method is equivalent to (but more efficient than) calling -insertTimeRange:ofTrack:atTime:error: for each timeRange/track pair. If this method returns an error, none of the time ranges will be inserted into the composition track. To specify an empty time range, pass NSNull for the track and a time range of starting at kCMTimeInvalid with a duration of the desired empty edit. This method throws an exception if time ranges and tracks to not have the same array count.

func (*AVMutableCompositionTrack) RemoveTimeRange ¶

func (o *AVMutableCompositionTrack) RemoveTimeRange(timeRange coremedia.CMTimeRange)

@method removeTimeRange: @abstract Removes a specified timeRange from the track. @param timeRange Specifies the timeRange to be removed. @discussion Removal of a timeRange does not cause the track to be removed from the composition. Instead it removes or truncates track segments that intersect with the timeRange.

func (*AVMutableCompositionTrack) RemoveTrackAssociationToTrackType ¶

func (o *AVMutableCompositionTrack) RemoveTrackAssociationToTrackType(compositionTrack *AVCompositionTrack, trackAssociationType *foundation.NSString)

@method removeTrackAssociationToTrack:type: @abstract Removes a track association of a specific type between two tracks. @param compositionTrack An AVCompositionTrack object that is associated with the receiver. @param trackAssociationType The type of track association to remove between the receiver and the specified compositionTrack (for instance, AVTrackAssociationTypeChapterList).

func (*AVMutableCompositionTrack) ReplaceFormatDescriptionWithFormatDescription ¶

func (o *AVMutableCompositionTrack) ReplaceFormatDescriptionWithFormatDescription(originalFormatDescription unsafe.Pointer, replacementFormatDescription unsafe.Pointer)

@method replaceFormatDescription:withFormatDescription: @abstract Replaces one of the receiver's format descriptions with another format description or cancels a previous replacement. @param originalFormatDescription A CMFormatDescription occurring in the underlying asset track. @param replacementFormatDescription A CMFormatDescription to replace the specified format description or NULL to indicate that a previous replacement of originalFormatDescription should be cancelled. @discussion You can use this method to make surgical changes to a track's format descriptions, such as adding format description extensions to a format description or changing the audio channel layout of an audio track. You should note that a format description can have extensions of type kCMFormatDescriptionExtension_VerbatimSampleDescription and kCMFormatDescriptionExtension_VerbatimISOSampleEntry; if you modify a copy of a format description, you should delete those extensions from the copy or your changes might be ignored. Also note that format description replacements are not transferred when performing editing operations on AVMutableCompositionTrack objects; for instance, inserting a range of a composition track into another composition track does not transfer any replacement format descriptions. This method throws an exception if the media type of the replacement does not match the original format description.

func (*AVMutableCompositionTrack) ScaleTimeRangeToDuration ¶

func (o *AVMutableCompositionTrack) ScaleTimeRangeToDuration(timeRange coremedia.CMTimeRange, duration coremedia.CMTime)

@method scaleTimeRange:toDuration: @abstract Changes the duration of a timeRange of the track. @param timeRange Specifies the timeRange of the track to be scaled. @param duration Specifies the new duration of the timeRange. @discussion Each trackSegment affected by the scaling operation will be presented at a rate equal to source.duration / target.duration of its resulting timeMapping.

func (*AVMutableCompositionTrack) SetEnabled ¶

func (o *AVMutableCompositionTrack) SetEnabled(enabled bool)

func (*AVMutableCompositionTrack) SetExtendedLanguageTag ¶

func (o *AVMutableCompositionTrack) SetExtendedLanguageTag(extendedLanguageTag *foundation.NSString)

func (*AVMutableCompositionTrack) SetLanguageCode ¶

func (o *AVMutableCompositionTrack) SetLanguageCode(languageCode *foundation.NSString)

func (*AVMutableCompositionTrack) SetNaturalTimeScale ¶

func (o *AVMutableCompositionTrack) SetNaturalTimeScale(naturalTimeScale int32)

func (*AVMutableCompositionTrack) SetPreferredTransform ¶

func (o *AVMutableCompositionTrack) SetPreferredTransform(preferredTransform corefoundation.CGAffineTransform)

func (*AVMutableCompositionTrack) SetPreferredVolume ¶

func (o *AVMutableCompositionTrack) SetPreferredVolume(preferredVolume float32)

func (*AVMutableCompositionTrack) SetSegments ¶

func (*AVMutableCompositionTrack) ValidateTrackSegmentsError ¶

func (o *AVMutableCompositionTrack) ValidateTrackSegmentsError(trackSegments *foundation.NSArray[*AVCompositionTrackSegment]) (bool, error)

@method validateTrackSegments:error: @abstract Tests an array of AVCompositionTrackSegments to determine whether they conform to the timing rules noted above (see the property key @"trackSegments"). @param trackSegments The array of AVCompositionTrackSegments to be validated. @param error If validation fais, returns information about the failure. @result YES if validation suceeds, otherwise NO. @discussion The array is tested for suitability for setting as the value of the trackSegments property. If a portion of an existing trackSegments array is to be modified, the modification can be made via an instance of NSMutableArray, and the resulting array can be tested via -validateTrackSegments:error:.

type AVMutableDateRangeMetadataGroup ¶

type AVMutableDateRangeMetadataGroup struct {
	AVDateRangeMetadataGroup
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutabledaterangemetadatagroup

func AVMutableDateRangeMetadataGroupFromID ¶

func AVMutableDateRangeMetadataGroupFromID(id objc.ID) *AVMutableDateRangeMetadataGroup

func (*AVMutableDateRangeMetadataGroup) SetEndDate ¶

func (o *AVMutableDateRangeMetadataGroup) SetEndDate(endDate *foundation.NSDate)

func (*AVMutableDateRangeMetadataGroup) SetItems ¶

func (*AVMutableDateRangeMetadataGroup) SetStartDate ¶

func (o *AVMutableDateRangeMetadataGroup) SetStartDate(startDate *foundation.NSDate)

type AVMutableMediaSelection ¶

type AVMutableMediaSelection struct {
	AVMediaSelection
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablemediaselection

func AVMutableMediaSelectionFromID ¶

func AVMutableMediaSelectionFromID(id objc.ID) *AVMutableMediaSelection

func (*AVMutableMediaSelection) SelectMediaOptionInMediaSelectionGroup ¶

func (o *AVMutableMediaSelection) SelectMediaOptionInMediaSelectionGroup(mediaSelectionOption *AVMediaSelectionOption, mediaSelectionGroup *AVMediaSelectionGroup)

@method selectMediaOption:inMediaSelectionGroup: @abstract Selects the media option described by the specified instance of AVMediaSelectionOption in the specified AVMediaSelectionGroup and deselects all other options in that group. @param mediaSelectionOption The option to select. @param mediaSelectionGroup The media selection group, obtained from the receiver's asset, that contains the specified option. @discussion If the specified media selection option isn't a member of the specified media selection group, no change in presentation state will result. If the value of the property allowsEmptySelection of the AVMediaSelectionGroup is YES, you can pass nil for mediaSelectionOption to deselect all media selection options in the group.

type AVMutableMetadataItem ¶

type AVMutableMetadataItem struct {
	AVMetadataItem
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablemetadataitem

func AVMutableMetadataItemFromID ¶

func AVMutableMetadataItemFromID(id objc.ID) *AVMutableMetadataItem

func AVMutableMetadataItemMetadataItem ¶

func AVMutableMetadataItemMetadataItem() *AVMutableMetadataItem

@method metadataItem @abstract Returns an instance of AVMutableMetadataItem.

func (*AVMutableMetadataItem) SetDataType ¶

func (o *AVMutableMetadataItem) SetDataType(dataType *foundation.NSString)

func (*AVMutableMetadataItem) SetDuration ¶

func (o *AVMutableMetadataItem) SetDuration(duration coremedia.CMTime)

func (*AVMutableMetadataItem) SetExtendedLanguageTag ¶

func (o *AVMutableMetadataItem) SetExtendedLanguageTag(extendedLanguageTag *foundation.NSString)

func (*AVMutableMetadataItem) SetExtraAttributes ¶

func (o *AVMutableMetadataItem) SetExtraAttributes(extraAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID])

func (*AVMutableMetadataItem) SetIdentifier ¶

func (o *AVMutableMetadataItem) SetIdentifier(identifier *foundation.NSString)

func (*AVMutableMetadataItem) SetKey ¶

func (o *AVMutableMetadataItem) SetKey(key objc.ID)

func (*AVMutableMetadataItem) SetKeySpace ¶

func (o *AVMutableMetadataItem) SetKeySpace(keySpace *foundation.NSString)

func (*AVMutableMetadataItem) SetLocale ¶

func (o *AVMutableMetadataItem) SetLocale(locale *foundation.NSLocale)

func (*AVMutableMetadataItem) SetStartDate ¶

func (o *AVMutableMetadataItem) SetStartDate(startDate *foundation.NSDate)

func (*AVMutableMetadataItem) SetTime ¶

func (o *AVMutableMetadataItem) SetTime(time_ coremedia.CMTime)

func (*AVMutableMetadataItem) SetValue ¶

func (o *AVMutableMetadataItem) SetValue(value objc.ID)

type AVMutableMovie ¶

type AVMutableMovie struct {
	AVMovie
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablemovie

func AVMutableMovieFromID ¶

func AVMutableMovieFromID(id objc.ID) *AVMutableMovie

func AVMutableMovieMovieWithDataOptionsError ¶

func AVMutableMovieMovieWithDataOptionsError(data *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*AVMutableMovie, error)

@method movieWithData:options:error: @abstract Creates an AVMutableMovie object from a movie header stored in an NSData object. @param data An NSData object containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMutableMovie object. @param outError If an error occurs creating a movie, describes the nature of the failure. @result An AVMutableMovie object @discussion You can use this method to operate on movie headers that are not stored in files. In general you should avoid loading an entire movie file with its media data into an instance of NSData! By default, the defaultMediaDataStorage property will be nil and each associated AVMutableMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from an NSData object and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func AVMutableMovieMovieWithSettingsFromMovieOptionsError ¶

func AVMutableMovieMovieWithSettingsFromMovieOptionsError(movie *AVMovie, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*AVMutableMovie, error)

@method movieWithSettingsFromMovie:options:error: @abstract Creates an AVMutableMovie object without tracks (and therefore without media). @param movie If you wish to transfer settings from an existing movie (including movie userdata and metadata, preferred rate, preferred volume, etc.), pass a reference to an AVMovie object representing that movie. Otherwise pass nil. The userdata and metadata from the source movie may need to be converted if the format of that movie differs from fileType; you may wish to inspect the userdata or metadata of the receiver to ensure that important data was copied. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMutableMovie object. Pass nil for default initialization behavior. @param outError If an error occurs creating a movie, describes the nature of the failure. @result An AVMutableMovie object @discussion By default, the defaultMediaDataStorage property will be nil and each associated AVMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from an NSData object and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func AVMutableMovieMovieWithURLOptionsError ¶

func AVMutableMovieMovieWithURLOptionsError(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*AVMutableMovie, error)

@method movieWithURL:options:error: @abstract Creates an AVMutableMovie object from a movie header stored in a QuickTime movie file or ISO base media file. @param URL An NSURL object that specifies a file containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMutableMovie object. @param outError If an error occurs creating a movie, describes the nature of the failure. @result An AVMutableMovie object @discussion By default, the defaultMediaDataStorage property will be nil and each associated AVMutableMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from a file and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMutableMovie) AddMutableTrackWithMediaTypeCopySettingsFromTrackOptions ¶

func (o *AVMutableMovie) AddMutableTrackWithMediaTypeCopySettingsFromTrackOptions(mediaType *foundation.NSString, track *AVAssetTrack, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVMutableMovieTrack

@method addMutableTrackWithMediaType:copySettingsFromTrack:options: @abstract Adds an empty track to the target movie. @param mediaType The media type of the new track (e.g. AVMediaTypeVideo for a video track). @param track If you wish to transfer settings from an existing track, including width, height, preferred volume, etc., pass a reference to an AVAssetTrack representing that track. Otherwise pass nil. @param options An NSDictionary object that contains keys for specifying options for the initialization of the new AVMutableMovieTrack object. Pass nil for default initialization behavior. @result An AVMutableMovieTrack object @discussion The trackID of the newly added track is a property of the returned instance of AVMutableMovieTrack. This method throws an exception if media type is not equal to the track's media type, or if any option is invalid. Note that metadata will not be automatically copied.

func (*AVMutableMovie) AddMutableTracksCopyingSettingsFromTracksOptions ¶

func (o *AVMutableMovie) AddMutableTracksCopyingSettingsFromTracksOptions(existingTracks *foundation.NSArray[*AVAssetTrack], options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *foundation.NSArray[*AVMutableMovieTrack]

@method addMutableTracksCopyingSettingsFromTracks:options: @abstract Adds one or more empty tracks to the target movie, copying track settings from the source tracks. @param existingTracks An array of AVAssetTrack objects. @param options An NSDictionary object that contains keys for specifying options for the initialization of the new AVMutableMovieTrack objects. Pass nil for default initialization behavior. @result An array of AVMutableMovieTrack objects; the index of a track in this array is the same as the index of its source track in the existingTracks array. @discussion This method creates one or more empty tracks in the target movie and configures those tracks with settings (such as track userdata and metadata, width, height, and preferred volume) copied from the source tracks in the existingTracks array. Also, properties involving pairs of tracks (such as track references) are copied from the source tracks to the target tracks. This method throws an exception if any option is invalid.

func (*AVMutableMovie) InitWithDataOptionsError ¶

func (o *AVMutableMovie) InitWithDataOptionsError(data *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*AVMutableMovie, error)

@method initWithData:options:error: @abstract Creates an AVMutableMovie object from a movie header stored in an NSData object. @param data An NSData object containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMutableMovie object. @param outError If an error occurs creating a movie, describes the nature of the failure. @result An AVMutableMovie object @discussion You can use this method to operate on movie headers that are not stored in files. In general you should avoid loading an entire movie file with its media data into an instance of NSData! By default, the defaultMediaDataStorage property will be nil and each associated AVMutableMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from an NSData object and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMutableMovie) InitWithSettingsFromMovieOptionsError ¶

func (o *AVMutableMovie) InitWithSettingsFromMovieOptionsError(movie *AVMovie, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*AVMutableMovie, error)

@method initWithSettingsFromMovie:options:error: @abstract Creates an AVMutableMovie object without tracks (and therefore without media). @param movie If you wish to transfer settings from an existing movie (including movie userdata and metadata, preferred rate, preferred volume, etc.), pass a reference to an AVMovie object representing that movie. Otherwise pass nil. The userdata and metadata from the source movie may need to be converted if the format of that movie differs from fileType; you may wish to inspect the userdata or metadata of the receiver to ensure that important data was copied. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMutableMovie object. Pass nil for default initialization behavior. @param outError If an error occurs creating a movie, describes the nature of the failure. @result An AVMutableMovie object @discussion By default, the defaultMediaDataStorage property will be nil and each associated AVMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from an NSData object and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMutableMovie) InitWithURLOptionsError ¶

func (o *AVMutableMovie) InitWithURLOptionsError(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*AVMutableMovie, error)

@method initWithURL:options:error: @abstract Creates an AVMutableMovie object from a movie header stored in a QuickTime movie file or ISO base media file. @param URL An NSURL object that specifies a file containing a movie header. @param options An NSDictionary object that contains keys for specifying options for the initialization of the AVMutableMovie object. @param outError If an error occurs creating a movie, describes the nature of the failure. @result An AVMutableMovie object @discussion By default, the defaultMediaDataStorage property will be nil and each associated AVMutableMovieTrack's mediaDataStorage property will be nil. If you want to create an AVMutableMovie from a file and then append sample buffers to any of its tracks, you must first set one of these properties to indicate where the sample data should be written.

func (*AVMutableMovie) InsertEmptyTimeRange ¶

func (o *AVMutableMovie) InsertEmptyTimeRange(timeRange coremedia.CMTimeRange)

@method insertEmptyTimeRange: @abstract Adds an empty time range to the target movie. @param timeRange The time range to be made empty. Note that you cannot add empty time ranges to the end of a movie.

func (*AVMutableMovie) InsertTimeRangeOfAssetAtTimeCopySampleDataError ¶

func (o *AVMutableMovie) InsertTimeRangeOfAssetAtTimeCopySampleDataError(timeRange coremedia.CMTimeRange, asset *AVAsset, startTime coremedia.CMTime, copySampleData bool) (bool, error)

@method insertTimeRange:ofAsset:atTime:copySampleData:error: @abstract Inserts all the tracks of a timeRange of an asset into a movie. @param timeRange The time range of the asset to be inserted. @param asset An AVAsset object indicating the source of the inserted media. Only instances of AVURLAsset and AVComposition are supported. Must not be nil. @param startTime The time in the target movie at which the media is to be inserted. @param copySampleData A BOOL value that indicates whether sample data is to be copied from the source to the destination during edits. If YES, the sample data is written to the location specified by the track property mediaDataStorage if non-nil, or else by the movie property defaultMediaDataStorage if non-nil; if both are nil, the method will fail and return NO. If NO, sample data will not be written and sample references to the samples in their original container will be added as necessary. Note that in this case, this method will fail if the source AVAsset is not able to provide sample reference information for the original container. @param outError If the insertion fails, an NSError object that describes the nature of the failure. @result A BOOL value that indicates the success of the insertion. @discussion This method may add new tracks to the target movie to ensure that all tracks of the asset are represented in the inserted timeRange. Existing content at the specified startTime will be pushed out by the duration of timeRange. Note that metadata will not be automatically copied.

func (*AVMutableMovie) InterleavingPeriod ¶

func (o *AVMutableMovie) InterleavingPeriod() coremedia.CMTime

@property interleavingPeriod @abstract A CMTime that indicates the duration for interleaving runs of samples of each track. @discussion The default interleaving period is 0.5 seconds.

func (*AVMutableMovie) IsModified ¶

func (o *AVMutableMovie) IsModified() bool

@property modified @abstract Whether a movie has been modified. @discussion The value of this property is a BOOL that indicates whether the AVMutableMovie object has been modified since it was created, was last written, or had its modified state cleared via a call to setModified:NO.

func (*AVMutableMovie) MutableTrackCompatibleWithTrack ¶

func (o *AVMutableMovie) MutableTrackCompatibleWithTrack(track *AVAssetTrack) *AVMutableMovieTrack

@method mutableTrackCompatibleWithTrack: @abstract Provides a reference to a track of a mutable movie into which any time range of an AVAssetTrack can be inserted (via -[AVMutableMovieTrack insertTimeRange:ofTrack:atTime:copySampleData:error:]). @param track A reference to the AVAssetTrack from which a time range may be inserted. @result An AVMutableMovieTrack that can accommodate the insertion. If no such track is available, the result is nil. A new track of the same media type as the AVAssetTrack can be created via -addMutableTrackWithMediaType:copySettingsFromTrack:options:, and this new track will be compatible. @discussion For best performance, the number of tracks in a movie should be kept to a minimum, corresponding to the number for which media data must be presented in parallel. If media data of the same type is to be presented serially, even from multiple assets, a single track of that media type should be used. This method, -mutableTrackCompatibleWithTrack:, can help the client to identify an existing target track for an insertion.

func (*AVMutableMovie) RemoveTimeRange ¶

func (o *AVMutableMovie) RemoveTimeRange(timeRange coremedia.CMTimeRange)

@method removeTimeRange: @abstract Removes a specified time range from a movie. @param timeRange The time range to be removed.

func (*AVMutableMovie) RemoveTrack ¶

func (o *AVMutableMovie) RemoveTrack(track *AVMovieTrack)

@method removeTrack: @abstract Removes a track from the target movie. @param track The track to be removed.

func (*AVMutableMovie) ScaleTimeRangeToDuration ¶

func (o *AVMutableMovie) ScaleTimeRangeToDuration(timeRange coremedia.CMTimeRange, duration coremedia.CMTime)

@method scaleTimeRange:toDuration: @abstract Changes the duration of a time range of a movie. @param timeRange The time range to be scaled. @param duration The new duration of the time range.

func (*AVMutableMovie) SetDefaultMediaDataStorage ¶

func (o *AVMutableMovie) SetDefaultMediaDataStorage(defaultMediaDataStorage *AVMediaDataStorage)

func (*AVMutableMovie) SetInterleavingPeriod ¶

func (o *AVMutableMovie) SetInterleavingPeriod(interleavingPeriod coremedia.CMTime)

func (*AVMutableMovie) SetMetadata ¶

func (o *AVMutableMovie) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVMutableMovie) SetModified ¶

func (o *AVMutableMovie) SetModified(modified bool)

func (*AVMutableMovie) SetPreferredRate ¶

func (o *AVMutableMovie) SetPreferredRate(preferredRate float32)

func (*AVMutableMovie) SetPreferredTransform ¶

func (o *AVMutableMovie) SetPreferredTransform(preferredTransform corefoundation.CGAffineTransform)

func (*AVMutableMovie) SetPreferredVolume ¶

func (o *AVMutableMovie) SetPreferredVolume(preferredVolume float32)

func (*AVMutableMovie) SetTimescale ¶

func (o *AVMutableMovie) SetTimescale(timescale int32)

func (*AVMutableMovie) Timescale ¶

func (o *AVMutableMovie) Timescale() int32

@property timescale @abstract For file types that contain a 'moov' atom, such as QuickTime Movie files, specifies the time scale of the movie. @discussion The default movie time scale is 600. In certain cases, you may want to set this to a different value. For instance, a movie that contains a single audio track should typically have the movie time scale set to the media time scale of that track. This property should be set on a new empty movie before any edits are performed on the movie.

type AVMutableMovieTrack ¶

type AVMutableMovieTrack struct {
	AVMovieTrack
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablemovietrack

func AVMutableMovieTrackFromID ¶

func AVMutableMovieTrackFromID(id objc.ID) *AVMutableMovieTrack

func (*AVMutableMovieTrack) AddTrackAssociationToTrackType ¶

func (o *AVMutableMovieTrack) AddTrackAssociationToTrackType(movieTrack *AVMovieTrack, trackAssociationType *foundation.NSString)

@method addTrackAssociationToTrack:type: @abstract Establishes a track association of a specific type between two tracks. @param movieTrack An AVMovieTrack object that is to be associated with the receiver. @param trackAssociationType The type of track association to add between the receiver and the specified movieTrack (for instance, AVTrackAssociationTypeChapterList). @discussion This method throws an exception if the movie track belongs to a different movie.

func (*AVMutableMovieTrack) AppendSampleBufferDecodeTimePresentationTimeError ¶

func (o *AVMutableMovieTrack) AppendSampleBufferDecodeTimePresentationTimeError(sampleBuffer unsafe.Pointer, outDecodeTime *coremedia.CMTime, outPresentationTime *coremedia.CMTime) (bool, error)

@method appendSampleBuffer:decodeTime:presentationTime:error: @abstract Appends sample data to a media file and adds sample references for the added data to a track's media sample tables. @param sampleBuffer The CMSampleBuffer to be appended; this may be obtained from an instance of AVAssetReader. @param outDecodeTime A pointer to a CMTime structure to receive the decode time in the media of the first sample appended from the sample buffer. Pass NULL if you do not need this information. @param outPresentationTime A pointer to a CMTime structure to receive the presentation time in the media of the first sample appended from the sample buffer. Pass NULL if you do not need this information. @param outError If the appending fails, describes the nature of the failure. For example, if the device containing the track's media data storage is full, AVErrorDiskFull is returned. @result A BOOL value indicating the success of the operation. @discussion If the sample buffer carries sample data, the sample data is written to the container specified by the track property mediaDataStorage if non-nil, or else by the movie property defaultMediaDataStorage if non-nil, and sample references will be appended to the track's media. If both media data storage properties are nil, the method will fail and return NO. If the sample buffer carries sample references only, sample data will not be written and sample references to the samples in their original container will be appended to the track's media as necessary. Note regarding sample timing: in a track's media, the first sample's decode timestamp must always be zero. For an audio track, each sample buffer's duration is used as the sample decode duration. For other track types, difference between a sample's decode timestamp and the following sample's decode timestamp is used as the first sample's decode duration, so as to preserve the relative timing. Note that this method does not modify the track's sourceTimeMappings but only appends sample references and sample data to the track's media. To make the new samples appear in the track's timeline, invoke -insertMediaTimeRange:intoTimeRange:. You can retrieve the mediaPresentationTimeRange property before and after appending a sequence of samples, using CMTimeRangeGetEnd on each to calculate the media TimeRange for -insertMediaTimeRange:intoTimeRange:. It's safe for multiple threads to call this method on different tracks at once. This method throws an exception for any of the following reasons: - the sample buffer's media type does not match the track's media type - the sample buffer contains image buffers (must contain encoded video) - the sample buffer contains caption groups (must contain encoded media data)

func (*AVMutableMovieTrack) CleanApertureDimensions ¶

func (o *AVMutableMovieTrack) CleanApertureDimensions() corefoundation.CGSize

@property cleanApertureDimensions @abstract A CGSize indicating the clean aperture dimensions of the track.

func (*AVMutableMovieTrack) EncodedPixelsDimensions ¶

func (o *AVMutableMovieTrack) EncodedPixelsDimensions() corefoundation.CGSize

@property encodedPixelsDimensions @abstract A CGSize indicating the dimensions encoded pixels dimensions of the track.

func (*AVMutableMovieTrack) HasProtectedContent ¶

func (o *AVMutableMovieTrack) HasProtectedContent() bool

@property hasProtectedContent @abstract Whether a track contains protected content. @discussion The value of this property is a BOOL that indicates whether the track contains protected content.

func (*AVMutableMovieTrack) InsertEmptyTimeRange ¶

func (o *AVMutableMovieTrack) InsertEmptyTimeRange(timeRange coremedia.CMTimeRange)

@method insertEmptyTimeRange: @abstract Adds an empty time range to the target track. @param timeRange The time range to be made empty. Note that you cannot add empty time ranges to the end of a track.

func (*AVMutableMovieTrack) InsertMediaTimeRangeIntoTimeRange ¶

func (o *AVMutableMovieTrack) InsertMediaTimeRangeIntoTimeRange(mediaTimeRange coremedia.CMTimeRange, trackTimeRange coremedia.CMTimeRange) bool

@method insertMediaTimeRange:intoTimeRange: @abstract Inserts a reference to a media time range into a track. @param mediaTimeRange The presentation time range of the media to be inserted. @param trackTimeRange The time range of the track into which the media is to be inserted. @result A BOOL value indicating the success of the operation. @discussion Use this method after you have appended samples or sample references to a track's media. To specify that the media time range be played at its natural rate, pass mediaTimeRange.duration == trackTimeRange.duration; otherwise, the ratio between these is used to determine the playback rate. Pass kCMTimeInvalid for trackTimeRange.start to indicate that the segment should be appended to the end of the track.

func (*AVMutableMovieTrack) InsertTimeRangeOfTrackAtTimeCopySampleDataError ¶

func (o *AVMutableMovieTrack) InsertTimeRangeOfTrackAtTimeCopySampleDataError(timeRange coremedia.CMTimeRange, track *AVAssetTrack, startTime coremedia.CMTime, copySampleData bool) (bool, error)

@method insertTimeRange:ofTrack:atTime:copySampleData:error: @abstract Inserts a portion of an AVAssetTrack object into the target movie. @param timeRange The time range from the track from which media is to be inserted. @param track An AVAssetTrack object indicating the source of the inserted media. Only AVAssetTracks of AVURLAssets and AVCompositions are supported. Must not be nil. @param startTime The time in the target track at which the media is to be inserted. @param copySampleData A BOOL value that indicates whether sample data is to be copied from the source to the destination during edits. If YES, the sample data is written to the file specified by the track property mediaDataStorage if non-nil, or else by the movie property defaultMediaDataStorage if non-nil; if both are nil, the method will fail and return NO. If NO, sample data will not be written and sample references to the samples in their original container will be added as necessary. Note that in this case, this method will fail if the original samples are fragmented. @param outError If the insertion fails, describes the nature of the failure. @result A BOOL value that indicates the success of the insertion.

func (*AVMutableMovieTrack) IsModified ¶

func (o *AVMutableMovieTrack) IsModified() bool

@property modified @abstract Whether a track has been modified. @discussion The value of this property is a BOOL that indicates whether the AVMutableMovieTrack object has been modified since it was created, was last written, or had its modified state cleared via a call to setModified:NO.

func (*AVMutableMovieTrack) Layer ¶

func (o *AVMutableMovieTrack) Layer() int

@property layer @abstract The layer level of the visual media data of the track.

func (*AVMutableMovieTrack) PreferredMediaChunkAlignment ¶

func (o *AVMutableMovieTrack) PreferredMediaChunkAlignment() int

@property preferredMediaChunkAlignment @abstract For file types that support media chunk alignment, the boundary for media chunk alignment (in bytes). @discussion The default value is 0, which means that no padding should be used to achieve chunk alignment. It is an error to set a negative value for chunk alignment.

func (*AVMutableMovieTrack) PreferredMediaChunkDuration ¶

func (o *AVMutableMovieTrack) PreferredMediaChunkDuration() coremedia.CMTime

@property preferredMediaChunkDuration @abstract For file types that support media chunk durations, the maximum duration to be used for each chunk of sample data written to the file. @discussion The total duration of the samples in a chunk will be no greater than this preferred chunk duration, or the duration of a single sample if the sample's duration is greater than this preferred chunk duration. The default media chunk duration is 1.0 second. It is an error to set a chunk duration that is negative or non-numeric.

func (*AVMutableMovieTrack) PreferredMediaChunkSize ¶

func (o *AVMutableMovieTrack) PreferredMediaChunkSize() int

@property preferredMediaChunkSize @abstract For file types that support media chunk sizes, the maximum size (in bytes) to be used for each chunk of sample data written to the file. @discussion The total size of the samples in a chunk will be no larger than this preferred chunk size, or the size of a single sample if the sample is larger than this preferred chunk size. The default media chunk size is 1024 * 1024 bytes. It is an error to set a negative chunk size.

func (*AVMutableMovieTrack) ProductionApertureDimensions ¶

func (o *AVMutableMovieTrack) ProductionApertureDimensions() corefoundation.CGSize

@property productionApertureDimensions @abstract A CGSize indicating the production aperture dimensions of the track.

func (*AVMutableMovieTrack) RemoveTimeRange ¶

func (o *AVMutableMovieTrack) RemoveTimeRange(timeRange coremedia.CMTimeRange)

@method removeTimeRange: @abstract Removes a specified time range from a track. @param timeRange The time range to be removed.

func (*AVMutableMovieTrack) RemoveTrackAssociationToTrackType ¶

func (o *AVMutableMovieTrack) RemoveTrackAssociationToTrackType(movieTrack *AVMovieTrack, trackAssociationType *foundation.NSString)

@method removeTrackAssociationToTrack:type: @abstract Removes a track association of a specific type between two tracks. @param movieTrack An AVMovieTrack object that is associated with the receiver. @param trackAssociationType The type of track association to remove between the receiver and the specified movieTrack (for instance, AVTrackAssociationTypeChapterList). @discussion This method throws an exception if the movie track belongs to a different movie.

func (*AVMutableMovieTrack) ReplaceFormatDescriptionWithFormatDescription ¶

func (o *AVMutableMovieTrack) ReplaceFormatDescriptionWithFormatDescription(formatDescription unsafe.Pointer, newFormatDescription unsafe.Pointer)

@method replaceFormatDescription:withFormatDescription: @abstract Replaces one of the receiver's format descriptions with another format description @param formatDescription A CMFormatDescription occurring in the array returned by the -formatDescriptions method. @param newFormatDescription A CMFormatDescription to replace the specified format description. @discussion You can use this method to make surgical changes to a track's format descriptions, such as adding format description extensions to a format description or changing the audio channel layout of an audio track. You should note that a format description can have extensions of type kCMFormatDescriptionExtension_VerbatimSampleDescription and kCMFormatDescriptionExtension_VerbatimISOSampleEntry; if you modify a copy of a format description, you should delete those extensions from the copy or your changes might be ignored. This method throws an exception if the media type of the new format description does not match the media type of the receiver.

func (*AVMutableMovieTrack) SampleReferenceBaseURL ¶

func (o *AVMutableMovieTrack) SampleReferenceBaseURL() *foundation.NSURL

@property sampleReferenceBaseURL @abstract For file types that support writing sample references, such as QuickTime Movie files, specifies the base URL that sample references are relative to; may be nil. @discussion If the value of this property can be resolved as an absolute URL, the sample locations written to the file when appending sample references to this track will be relative to this URL. The URL must point to a location contained by any common parent directory of the locations that will be referenced. For example, setting the sampleReferenceBaseURL property to "file:///Users/johnappleseed/Movies/" and appending sample buffers that refer to "file:///Users/johnappleseed/Movies/data/movie1.mov" will cause the sample reference "data/movie1.mov" to be written to the movie file. If the value of the property cannot be resolved as an absolute URL or if it points to a location that is not contained by any common parent directory of the locations that will be referenced, the location will be written unmodified. The default value is nil, which means that the location will be written unmodified.

func (*AVMutableMovieTrack) ScaleTimeRangeToDuration ¶

func (o *AVMutableMovieTrack) ScaleTimeRangeToDuration(timeRange coremedia.CMTimeRange, duration coremedia.CMTime)

@method scaleTimeRange:toDuration: @abstract Changes the duration of a time range of a track. @param timeRange The time range to be scaled. @param duration The new duration of the time range.

func (*AVMutableMovieTrack) SetAlternateGroupID ¶

func (o *AVMutableMovieTrack) SetAlternateGroupID(alternateGroupID int)

func (*AVMutableMovieTrack) SetCleanApertureDimensions ¶

func (o *AVMutableMovieTrack) SetCleanApertureDimensions(cleanApertureDimensions corefoundation.CGSize)

func (*AVMutableMovieTrack) SetEnabled ¶

func (o *AVMutableMovieTrack) SetEnabled(enabled bool)

func (*AVMutableMovieTrack) SetEncodedPixelsDimensions ¶

func (o *AVMutableMovieTrack) SetEncodedPixelsDimensions(encodedPixelsDimensions corefoundation.CGSize)

func (*AVMutableMovieTrack) SetExtendedLanguageTag ¶

func (o *AVMutableMovieTrack) SetExtendedLanguageTag(extendedLanguageTag *foundation.NSString)

func (*AVMutableMovieTrack) SetLanguageCode ¶

func (o *AVMutableMovieTrack) SetLanguageCode(languageCode *foundation.NSString)

func (*AVMutableMovieTrack) SetLayer ¶

func (o *AVMutableMovieTrack) SetLayer(layer int)

func (*AVMutableMovieTrack) SetMediaDataStorage ¶

func (o *AVMutableMovieTrack) SetMediaDataStorage(mediaDataStorage *AVMediaDataStorage)

func (*AVMutableMovieTrack) SetMetadata ¶

func (o *AVMutableMovieTrack) SetMetadata(metadata *foundation.NSArray[*AVMetadataItem])

func (*AVMutableMovieTrack) SetModified ¶

func (o *AVMutableMovieTrack) SetModified(modified bool)

func (*AVMutableMovieTrack) SetNaturalSize ¶

func (o *AVMutableMovieTrack) SetNaturalSize(naturalSize corefoundation.CGSize)

func (*AVMutableMovieTrack) SetPreferredMediaChunkAlignment ¶

func (o *AVMutableMovieTrack) SetPreferredMediaChunkAlignment(preferredMediaChunkAlignment int)

func (*AVMutableMovieTrack) SetPreferredMediaChunkDuration ¶

func (o *AVMutableMovieTrack) SetPreferredMediaChunkDuration(preferredMediaChunkDuration coremedia.CMTime)

func (*AVMutableMovieTrack) SetPreferredMediaChunkSize ¶

func (o *AVMutableMovieTrack) SetPreferredMediaChunkSize(preferredMediaChunkSize int)

func (*AVMutableMovieTrack) SetPreferredTransform ¶

func (o *AVMutableMovieTrack) SetPreferredTransform(preferredTransform corefoundation.CGAffineTransform)

func (*AVMutableMovieTrack) SetPreferredVolume ¶

func (o *AVMutableMovieTrack) SetPreferredVolume(preferredVolume float32)

func (*AVMutableMovieTrack) SetProductionApertureDimensions ¶

func (o *AVMutableMovieTrack) SetProductionApertureDimensions(productionApertureDimensions corefoundation.CGSize)

func (*AVMutableMovieTrack) SetSampleReferenceBaseURL ¶

func (o *AVMutableMovieTrack) SetSampleReferenceBaseURL(sampleReferenceBaseURL *foundation.NSURL)

func (*AVMutableMovieTrack) SetTimescale ¶

func (o *AVMutableMovieTrack) SetTimescale(timescale int32)

func (*AVMutableMovieTrack) Timescale ¶

func (o *AVMutableMovieTrack) Timescale() int32

@property timescale @abstract For file types that contain a 'moov' atom, such as QuickTime Movie files, specifies the time scale of the track's media. @discussion The default media time scale is 0. This property should be set on a new empty track before any edits are performed on the track.

type AVMutableTimedMetadataGroup ¶

type AVMutableTimedMetadataGroup struct {
	AVTimedMetadataGroup
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutabletimedmetadatagroup

func AVMutableTimedMetadataGroupFromID ¶

func AVMutableTimedMetadataGroupFromID(id objc.ID) *AVMutableTimedMetadataGroup

func (*AVMutableTimedMetadataGroup) SetItems ¶

func (*AVMutableTimedMetadataGroup) SetTimeRange ¶

func (o *AVMutableTimedMetadataGroup) SetTimeRange(timeRange coremedia.CMTimeRange)

type AVMutableVideoComposition ¶

type AVMutableVideoComposition struct {
	AVVideoComposition
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablevideocomposition

func AVMutableVideoCompositionFromID ¶

func AVMutableVideoCompositionFromID(id objc.ID) *AVMutableVideoComposition

func AVMutableVideoCompositionVideoComposition ¶

func AVMutableVideoCompositionVideoComposition() *AVMutableVideoComposition

Returns a new instance of AVMutableVideoComposition. The returned AVMutableVideoComposition will have a frameDuration of kCMTimeZero, a renderSize of {0.0, 0.0}, a nil array of instructions, and a nil animationTool.

func AVMutableVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandler ¶

func AVMutableVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandler(asset *AVAsset, applier func(*AVAsynchronousCIImageFilteringRequest)) *AVMutableVideoComposition

Returns a new instance of AVMutableVideoComposition with values and instructions that will apply the specified handler block to video frames represented as instances of CIImage. The returned AVMutableVideoComposition will cause the specified handler block to be called to filter each frame of the asset's first enabled video track. The handler block should use the properties of the provided AVAsynchronousCIImageFilteringRequest and respond using finishWithImage:context: with a "filtered" new CIImage (or the provided source image for no affect). In the event of an error, respond to the request using finishWithError:. The error can be observed via AVPlayerItemFailedToPlayToEndTimeNotification, see AVPlayerItemFailedToPlayToEndTimeErrorKey in notification payload. The client can set sourceTrackIDForFrameTiming to kCMPersistentTrackID_Invalid and frameDuration to an appropriate value in order to specify the maximum output frame rate independent of the source track timing. The video composition will also have the following values for its properties: - The original timing of the asset's first enabled video track will be used. - A renderSize that encompasses the asset's first enabled video track respecting the track's preferredTransform. - A renderScale of 1.0. The default CIContext has the following properties: - iOS: Device RGB color space - macOS: sRGB color space Example usage: ```objc playerItem.videoComposition = [AVMutableVideoComposition videoCompositionWithAsset:srcAsset applyingCIFiltersWithHandler: ^(AVAsynchronousCIImageFilteringRequest *request) { NSError *err = nil; CIImage *filtered = myRenderer(request, &err); if (filtered) [request finishWithImage:filtered context:nil]; else [request finishWithError:err]; }]; ``` - Parameter asset: An instance of AVAsset. For best performance, ensure that the duration and tracks properties of the asset are already loaded before invoking this method. - Returns: An instance of AVMutableVideoComposition. Deprecated: Use videoCompositionWithAsset:applyingCIFiltersWithHandler:completionHandler: instead

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAsset ¶

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAsset(asset *AVAsset) *AVMutableVideoComposition

Returns a new instance of AVMutableVideoComposition with values and instructions suitable for presenting the video tracks of the specified asset according to its temporal and geometric properties and those of its tracks. The returned AVMutableVideoComposition will have instructions that respect the spatial properties and timeRanges of the specified asset's video tracks. The client can set sourceTrackIDForFrameTiming to kCMPersistentTrackID_Invalid and frameDuration to an appropriate value in order to specify the maximum output frame rate independent of the source track timing. It will also have the following values for its properties: - If the asset has exactly one video track, the original timing of the source video track will be used. If the asset has more than one video track, and the nominal frame rate of any of video tracks is known, the reciprocal of the greatest known nominalFrameRate will be used as the value of frameDuration. Otherwise, a default framerate of 30fps is used. - If the specified asset is an instance of AVComposition, the renderSize will be set to the naturalSize of the AVComposition; otherwise the renderSize will be set to a value that encompasses all of the asset's video tracks. - A renderScale of 1.0. - A nil animationTool. If the specified asset has no video tracks, this method will return an AVMutableVideoComposition instance with an empty collection of instructions. - Parameter asset: An instance of AVAsset. For best performance, ensure that the duration and tracks properties of the asset are already loaded before invoking this method. - Returns: An instance of AVMutableVideoComposition. Deprecated: Use videoCompositionWithPropertiesOfAsset:completionHandler: instead

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAssetPrototypeInstruction ¶

func AVMutableVideoCompositionVideoCompositionWithPropertiesOfAssetPrototypeInstruction(asset *AVAsset, prototypeInstruction *AVVideoCompositionInstruction) *AVMutableVideoComposition

Returns a new instance of AVMutableVideoComposition with values and instructions suitable for presenting the video tracks of the specified asset according to its temporal and geometric properties and those of its tracks, and also overrides default properties with those from a prototypeInstruction. Also see videoCompositionWithPropertiesOfAsset:. The returned AVVideoComposition will have instructions that respect the spatial properties and timeRanges of the specified asset's video tracks. Anything not pertaining to spatial layout and timing, such as background color for their composition or post-processing behaviors, is eligible to be specified via a prototype instruction. Example: To add a background color, ```objc myPrototypeInstruction = [[AVMutableVideoCompositionInstruction alloc] init]; myPrototypeInstruction.backgroundColor = myCGColorRef; // Do not use constant CGColorRef colors here. myVideoComposition = [AVVideoComposition videoCompositionWithPropertiesOfAsset:myAsset prototypeInstruction:myPrototypeInstruction]; ``` - Parameter asset: An instance of AVAsset. For best performance, ensure that the duration and tracks properties of the asset are already loaded before invoking this method. - Parameter prototypeInstruction: Custom instructions that the client can choose to override. - Returns: An instance of AVMutableVideoComposition. Deprecated: Use videoCompositionWithPropertiesOfAsset:prototypeInstruction:completionHandler: instead

func (*AVMutableVideoComposition) SetAnimationTool ¶

func (o *AVMutableVideoComposition) SetAnimationTool(animationTool *AVVideoCompositionCoreAnimationTool)

func (*AVMutableVideoComposition) SetColorPrimaries ¶

func (o *AVMutableVideoComposition) SetColorPrimaries(colorPrimaries *foundation.NSString)

func (*AVMutableVideoComposition) SetColorTransferFunction ¶

func (o *AVMutableVideoComposition) SetColorTransferFunction(colorTransferFunction *foundation.NSString)

func (*AVMutableVideoComposition) SetColorYCbCrMatrix ¶

func (o *AVMutableVideoComposition) SetColorYCbCrMatrix(colorYCbCrMatrix *foundation.NSString)

func (*AVMutableVideoComposition) SetCustomVideoCompositorClass ¶

func (o *AVMutableVideoComposition) SetCustomVideoCompositorClass(customVideoCompositorClass unsafe.Pointer)

func (*AVMutableVideoComposition) SetFrameDuration ¶

func (o *AVMutableVideoComposition) SetFrameDuration(frameDuration coremedia.CMTime)

func (*AVMutableVideoComposition) SetInstructions ¶

func (*AVMutableVideoComposition) SetOutputBufferDescription ¶

func (o *AVMutableVideoComposition) SetOutputBufferDescription(outputBufferDescription *foundation.NSArray[objc.ID])

func (*AVMutableVideoComposition) SetPerFrameHDRDisplayMetadataPolicy ¶

func (o *AVMutableVideoComposition) SetPerFrameHDRDisplayMetadataPolicy(perFrameHDRDisplayMetadataPolicy *foundation.NSString)

func (*AVMutableVideoComposition) SetRenderScale ¶

func (o *AVMutableVideoComposition) SetRenderScale(renderScale float32)

func (*AVMutableVideoComposition) SetRenderSize ¶

func (o *AVMutableVideoComposition) SetRenderSize(renderSize corefoundation.CGSize)

func (*AVMutableVideoComposition) SetSourceSampleDataTrackIDs ¶

func (o *AVMutableVideoComposition) SetSourceSampleDataTrackIDs(sourceSampleDataTrackIDs *foundation.NSArray[*foundation.NSNumber])

func (*AVMutableVideoComposition) SetSourceTrackIDForFrameTiming ¶

func (o *AVMutableVideoComposition) SetSourceTrackIDForFrameTiming(sourceTrackIDForFrameTiming int32)

type AVMutableVideoCompositionInstruction ¶

type AVMutableVideoCompositionInstruction struct {
	AVVideoCompositionInstruction
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablevideocompositioninstruction

func AVMutableVideoCompositionInstructionFromID ¶

func AVMutableVideoCompositionInstructionFromID(id objc.ID) *AVMutableVideoCompositionInstruction

func AVMutableVideoCompositionInstructionVideoCompositionInstruction ¶

func AVMutableVideoCompositionInstructionVideoCompositionInstruction() *AVMutableVideoCompositionInstruction

Returns a new instance of AVMutableVideoCompositionInstruction. The returned AVMutableVideoCompositionInstruction will have a timeRange of kCMTimeRangeInvalid, a NULL backgroundColor, and a nil array of layerInstructions.

func (*AVMutableVideoCompositionInstruction) SetBackgroundColor ¶

func (o *AVMutableVideoCompositionInstruction) SetBackgroundColor(backgroundColor unsafe.Pointer)

func (*AVMutableVideoCompositionInstruction) SetEnablePostProcessing ¶

func (o *AVMutableVideoCompositionInstruction) SetEnablePostProcessing(enablePostProcessing bool)

func (*AVMutableVideoCompositionInstruction) SetLayerInstructions ¶

func (o *AVMutableVideoCompositionInstruction) SetLayerInstructions(layerInstructions *foundation.NSArray[*AVVideoCompositionLayerInstruction])

func (*AVMutableVideoCompositionInstruction) SetRequiredSourceSampleDataTrackIDs ¶

func (o *AVMutableVideoCompositionInstruction) SetRequiredSourceSampleDataTrackIDs(requiredSourceSampleDataTrackIDs *foundation.NSArray[*foundation.NSNumber])

func (*AVMutableVideoCompositionInstruction) SetTimeRange ¶

func (o *AVMutableVideoCompositionInstruction) SetTimeRange(timeRange coremedia.CMTimeRange)

func (*AVMutableVideoCompositionInstruction) TimeRange ¶

Indicates the timeRange during which the instruction is effective. Note requirements for the timeRanges of instructions described in connection with AVVideoComposition's instructions key above.

type AVMutableVideoCompositionLayerInstruction ¶

type AVMutableVideoCompositionLayerInstruction struct {
	AVVideoCompositionLayerInstruction
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avmutablevideocompositionlayerinstruction

func AVMutableVideoCompositionLayerInstructionFromID ¶

func AVMutableVideoCompositionLayerInstructionFromID(id objc.ID) *AVMutableVideoCompositionLayerInstruction

func AVMutableVideoCompositionLayerInstructionVideoCompositionLayerInstruction ¶

func AVMutableVideoCompositionLayerInstructionVideoCompositionLayerInstruction() *AVMutableVideoCompositionLayerInstruction

Returns a new instance of AVMutableVideoCompositionLayerInstruction with no transform or opacity ramps and a trackID initialized to kCMPersistentTrackID_Invalid.

func AVMutableVideoCompositionLayerInstructionVideoCompositionLayerInstructionWithAssetTrack ¶

func AVMutableVideoCompositionLayerInstructionVideoCompositionLayerInstructionWithAssetTrack(track *AVAssetTrack) *AVMutableVideoCompositionLayerInstruction

Returns a new instance of AVMutableVideoCompositionLayerInstruction with no transform or opacity ramps and a trackID set to the specified track's trackID. - Parameter track: A reference to an AVAssetTrack.

func (*AVMutableVideoCompositionLayerInstruction) SetCropRectangleAtTime ¶

func (o *AVMutableVideoCompositionLayerInstruction) SetCropRectangleAtTime(cropRectangle corefoundation.CGRect, time_ coremedia.CMTime)

Sets a value of the crop rectangle at a time within the timeRange of the instruction. The origin of the crop rectangle is the top-left corner of the buffer clean aperture rectangle. The crop rectangle is defined in square pixel space, i.e. without taking the pixel aspect ratio into account. Crop rectangles extending outside of the clean aperture, are cropped to the clean aperture. Sets a fixed crop rectangle to apply from the specified time until the next time at which a crop rectangle is set; this is the same as setting a flat ramp for that time range. Before the first specified time for which a crop rectangle is set, the crop rectangle is held constant to CGRectInfinite after the last time for which a crop rectangle is set, the crop rectangle is held constant at that last value. This method throws an exception if time is not numeric. - Parameter cropRectangle: The crop rectangle to be applied at the specified time. See the discussion below of how crop rectangles are applied to video frames. - Parameter time: A time value within the timeRange of the composition instruction.

func (*AVMutableVideoCompositionLayerInstruction) SetCropRectangleRampFromStartCropRectangleToEndCropRectangleTimeRange ¶

func (o *AVMutableVideoCompositionLayerInstruction) SetCropRectangleRampFromStartCropRectangleToEndCropRectangleTimeRange(startCropRectangle corefoundation.CGRect, endCropRectangle corefoundation.CGRect, timeRange coremedia.CMTimeRange)

Sets an crop rectangle ramp to apply during the specified timerange. The origin of the crop rectangle is the top-left corner of the buffer clean aperture rectangle. The crop rectangle is defined in square pixel space, i.e. without taking the pixel aspect ratio into account. Crop rectangles extending outside of the clean aperture, are cropped to the clean aperture. During a crop rectangle ramp, the rectangle is interpolated between the values set at the ramp's start time and end time. When the starting or ending rectangle is empty, interpolations take into account the origin and size of the empty rectangle. Before the first specified time for which a crop rectangle is set, the crop rectangle is held constant to CGRectInfinite after the last time for which a crop rectangle is set, the crop rectangle is held constant at that last value. This method throws an exception if the time range overlaps the time range of an existing crop rectangle ramp, or if the time range does not have a numeric start time and duration. - Parameter startCropRectangle: The crop rectangle to be applied at the starting time of the timeRange. See the discussion below of how crop rectangles are applied to video frames. - Parameter endCropRectangle: The crop rectangle to be applied at the end time of the timeRange. - Parameter timeRange: The timeRange over which the value of the opacity will be interpolated between startCropRectangle and endCropRectangle.

func (*AVMutableVideoCompositionLayerInstruction) SetOpacityAtTime ¶

func (o *AVMutableVideoCompositionLayerInstruction) SetOpacityAtTime(opacity float32, time_ coremedia.CMTime)

Sets a value of the opacity at a time within the timeRange of the instruction. Sets a fixed opacity to apply from the specified time until the next time at which an opacity is set; this is the same as setting a flat ramp for that time range. Before the first time for which an opacity is set, the opacity is held constant at 1.0; after the last specified time, the opacity is held constant at the last value. This method throws an exception if time is not numeric. - Parameter opacity: The opacity to be applied at the specified time. The value must be between 0.0 and 1.0. - Parameter time: A time value within the timeRange of the composition instruction.

func (*AVMutableVideoCompositionLayerInstruction) SetOpacityRampFromStartOpacityToEndOpacityTimeRange ¶

func (o *AVMutableVideoCompositionLayerInstruction) SetOpacityRampFromStartOpacityToEndOpacityTimeRange(startOpacity float32, endOpacity float32, timeRange coremedia.CMTimeRange)

Sets an opacity ramp to apply during the specified timerange. During an opacity ramp, opacity is computed using a linear interpolation. Before the first time for which an opacity is set, the opacity is held constant at 1.0; after the last specified time, the opacity is held constant at the last value This method throws an exception if the time range of a does not have a numeric start time and duration. - Parameter startOpacity: The opacity to be applied at the starting time of the timeRange. The value must be between 0.0 and 1.0. - Parameter endOpacity: The opacity to be applied at the end time of the timeRange. The value must be between 0.0 and 1.0. - Parameter timeRange: The timeRange over which the value of the opacity will be interpolated between startOpacity and endOpacity.

func (*AVMutableVideoCompositionLayerInstruction) SetTrackID ¶

func (o *AVMutableVideoCompositionLayerInstruction) SetTrackID(trackID int32)

func (*AVMutableVideoCompositionLayerInstruction) SetTransformAtTime ¶

Sets a value of the transform at a time within the timeRange of the instruction. For purposes of spatial positioning of video frames, the origin is in the top-left corner, so (a) positive translation values in an affine transform move a video frame right and down; and (b) with an identity transform a video frame is positioned with its top-left corner in the top-left corner of the composited frame. Video frames shall be interpreted at their display sizes (as described by CVImageBufferGetDisplaySize, ie, taking pixel aspect ratio attachments into account) before any affine transform is applied. Sets a fixed transform to apply from the specified time until the next time at which a transform is set; this is the same as setting a flat ramp for that time range. Before the first specified time for which a transform is set, the affine transform is held constant at the value of CGAffineTransformIdentity; after the last time for which a transform is set, the affine transform is held constant at that last value; This method throws an exception if time is not numeric. - Parameter transform: The transform to be applied at the specified time. See the discussion below of how transforms are applied to video frames. - Parameter time: A time value within the timeRange of the composition instruction.

func (*AVMutableVideoCompositionLayerInstruction) SetTransformRampFromStartTransformToEndTransformTimeRange ¶

func (o *AVMutableVideoCompositionLayerInstruction) SetTransformRampFromStartTransformToEndTransformTimeRange(startTransform corefoundation.CGAffineTransform, endTransform corefoundation.CGAffineTransform, timeRange coremedia.CMTimeRange)

Sets a transform ramp to apply during the specified timerange. For purposes of spatial positioning of video frames, the origin is in the top-left corner, so (a) positive translation values in an affine transform move a video frame right and down; and (b) with an identity transform a video frame is positioned with its top-left corner in the top-left corner of the composited frame. Video frames shall be interpreted at their display sizes (as described by CVImageBufferGetDisplaySize, ie, taking pixel aspect ratio attachments into account) before any affine transform is applied. During a transform ramp, the affine transform is interpolated between the values set at the ramp's start time and end time. Before the first specified time for which a transform is set, the affine transform is held constant at the value of CGAffineTransformIdentity; after the last time for which a transform is set, the affine transform is held constant at that last value; This method throws an exception if the time range overlaps the time range of an existing transform ramp or if the time range of a does not have a numeric start time and duration. - Parameter startTransform: The transform to be applied at the starting time of the timeRange. See the discussion below of how transforms are applied to video frames. - Parameter endTransform: The transform to be applied at the end time of the timeRange. - Parameter timeRange: The timeRange over which the value of the transform will be interpolated between startTransform and endTransform.

func (*AVMutableVideoCompositionLayerInstruction) TrackID ¶

Indicates the trackID of the source track to which the compositor will apply the instruction.

type AVOutputSettingsAssistant ¶

type AVOutputSettingsAssistant struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avoutputsettingsassistant

func AVOutputSettingsAssistantFromID ¶

func AVOutputSettingsAssistantFromID(id objc.ID) *AVOutputSettingsAssistant

func AVOutputSettingsAssistantOutputSettingsAssistantWithPreset ¶

func AVOutputSettingsAssistantOutputSettingsAssistantWithPreset(presetIdentifier *foundation.NSString) *AVOutputSettingsAssistant

@method outputSettingsAssistantWithPreset: @abstract Returns an instance of AVOutputSettingsAssistant corresponding to the given preset @param presetIdentifier The string identifier, for example AVOutputSettingsPreset1280x720, for the desired preset @result An instance of AVOutputSettingsAssistant with properties corresponding to the given preset, or nil if there is no such available preset. @discussion The properties of the returned object can be used as a guide for creating and configuring an AVAssetWriter object and one or more AVAssetWriterInput objects. If all the suggested properties are respected in creating the AVAssetWriter, the resulting media file will conform to the criteria implied by the preset. Use +availableOutputSettingsPresets to get a list of presets identifiers that can be used with this method.

func (*AVOutputSettingsAssistant) AudioSettings ¶

@property audioSettings @abstract A dictionary of key/value pairs, as specified in AVAudioSettings.h, to be used when e.g. creating an instance of AVAssetWriterInput @discussion The value of this property may change as a result of setting a new value for the sourceAudioFormat property.

func (*AVOutputSettingsAssistant) OutputFileType ¶

func (o *AVOutputSettingsAssistant) OutputFileType() *foundation.NSString

@property outputFileType @abstract A UTI indicating the type of file to be written, to be used when e.g. creating an instance of AVAssetWriter @discussion Use [[UTType typeWithIdentifier:outputFileType] preferredFilenameExtension] to get a suitable file extension for a given file type.

func (*AVOutputSettingsAssistant) SetSourceAudioFormat ¶

func (o *AVOutputSettingsAssistant) SetSourceAudioFormat(sourceAudioFormat unsafe.Pointer)

func (*AVOutputSettingsAssistant) SetSourceVideoAverageFrameDuration ¶

func (o *AVOutputSettingsAssistant) SetSourceVideoAverageFrameDuration(sourceVideoAverageFrameDuration coremedia.CMTime)

func (*AVOutputSettingsAssistant) SetSourceVideoFormat ¶

func (o *AVOutputSettingsAssistant) SetSourceVideoFormat(sourceVideoFormat unsafe.Pointer)

func (*AVOutputSettingsAssistant) SetSourceVideoMinFrameDuration ¶

func (o *AVOutputSettingsAssistant) SetSourceVideoMinFrameDuration(sourceVideoMinFrameDuration coremedia.CMTime)

func (*AVOutputSettingsAssistant) SourceAudioFormat ¶

func (o *AVOutputSettingsAssistant) SourceAudioFormat() unsafe.Pointer

@property sourceAudioFormat @abstract A CMAudioFormatDescription object describing the format of you audio data @discussion Setting this property will allow the receiver to make a more informed recommendation for the audio settings that should be used. After setting this property, you should re-query the audioSettings property to get the new recommendation. The default value is NULL, which means that the receiver does not know anything about the format of your audio data. If you set a non-NULL value for this property, and are using the receiver to initialize an AVAssetWriterInput, the same format description should be used to initialize the AVAssetWriterInput, along with the dictionary from the audioSettings property.

func (*AVOutputSettingsAssistant) SourceVideoAverageFrameDuration ¶

func (o *AVOutputSettingsAssistant) SourceVideoAverageFrameDuration() coremedia.CMTime

@property sourceVideoAverageFrameDuration @abstract A CMTime describing the average frame duration (reciprocal of average frame rate) of your video data @discussion Setting this property will allow the receiver to make a more informed recommendation for the video settings that should be used. After setting this property, you should re-query the videoSettings property to get the new recommendation. The default value is 1/30, which means that the receiver is assuming that your source video has an average frame rate of 30fps. It is an error to set this property to a value that is not positive or not numeric. See CMTIME_IS_NUMERIC.

func (*AVOutputSettingsAssistant) SourceVideoFormat ¶

func (o *AVOutputSettingsAssistant) SourceVideoFormat() unsafe.Pointer

@property sourceVideoFormat @abstract A CMVideoFormatDescription object describing the format of your video data @discussion Setting this property will allow the receiver to make a more informed recommendation for the video settings that should be used. After setting this property, you should re-query the videoSettings property to get the new recommendation. The default value is NULL, which means that the receiver does not know anything about the format of your video data. If you set a non-NULL value for this property, and are using the receiver to initialize an AVAssetWriterInput, the same format description should be used to initialize the AVAssetWriterInput, along with the dictionary from the videoSettings property.

func (*AVOutputSettingsAssistant) SourceVideoMinFrameDuration ¶

func (o *AVOutputSettingsAssistant) SourceVideoMinFrameDuration() coremedia.CMTime

@property sourceVideoMinFrameDuration @abstract A CMTime describing the minimum frame duration (reciprocal of the maximum frame rate) of your video data @discussion Setting this property will allow the receiver to make a more informed recommendation for the video settings that should be used. After setting this property, you should re-query the videoSettings property to get the new recommendation. If your source of video data is an instance of AVAssetReaderOutput, you can discover the minimum frame duration of your source asset using the AVAssetTrack.minFrameDuration property. The default value is 1/30, which means that the receiver is assuming that your source video has a maximum frame rate of 30fps. It is an error to set this property to a value that is not positive or not numeric. See CMTIME_IS_NUMERIC.

func (*AVOutputSettingsAssistant) VideoSettings ¶

@property videoSettings @abstract A dictionary of key/value pairs, as specified in AVVideoSettings.h, to be used when e.g. creating an instance of AVAssetWriterInput @discussion The value of this property may change as a result of setting a new value for the sourceVideoFormat property.

type AVPersistableContentKeyRequest ¶

type AVPersistableContentKeyRequest struct {
	AVContentKeyRequest
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avpersistablecontentkeyrequest

func AVPersistableContentKeyRequestFromID ¶

func AVPersistableContentKeyRequestFromID(id objc.ID) *AVPersistableContentKeyRequest

func (*AVPersistableContentKeyRequest) PersistableContentKeyFromKeyVendorResponseOptionsError ¶

func (o *AVPersistableContentKeyRequest) PersistableContentKeyFromKeyVendorResponseOptionsError(keyVendorResponse *foundation.NSData, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) (*foundation.NSData, error)

Obtains a persistable content key from a context. The data returned from this method may be used to immediately satisfy an AVPersistableContentKeyRequest, as well as any subsequent requests for the same key url using processContentKeyResponse: method. When you receive an AVContentKeyRequest via -contentKeySession:didProvideContentKeyRequest: and you want to use existing persistent content key from storage, you must invoke -respondByRequestingPersistableContentKeyRequest on that AVContentKeyRequest in order to signal that you want to process an AVPersistableContentKeyRequest instead. If the underlying protocol supports persistable content keys, in response your delegate will receive an AVPersistableContentKeyRequest via -contentKeySession:didProvidePersistableContentKeyRequest:. You can set the persistent key from storage on the AVPersistableContentKeyRequest using processContentKeyResponse:. - Parameter keyVendorResponse: The response returned from the key vendor as a result of a request generated from makeStreamingContentKeyRequestDataForApp:contentIdentifier:options:completionHandler:. - Parameter options: Additional information necessary to obtain the persistable content key, or nil if none. - Parameter outError: If obtaining the persistable content key fails, will be set to an instance of NSError describing the failure. - Returns: The persistable content key data that may be stored offline to answer future loading requests of the same content key.

type AVPixelAspectRatio ¶

type AVPixelAspectRatio struct {
	HorizontalSpacing int
	VerticalSpacing   int
}

type AVPlaybackCoordinationMedium ¶

type AVPlaybackCoordinationMedium struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplaybackcoordinationmedium

func AVPlaybackCoordinationMediumFromID ¶

func AVPlaybackCoordinationMediumFromID(id objc.ID) *AVPlaybackCoordinationMedium

func (*AVPlaybackCoordinationMedium) ConnectedPlaybackCoordinators ¶

func (o *AVPlaybackCoordinationMedium) ConnectedPlaybackCoordinators() *foundation.NSArray[*AVPlayerPlaybackCoordinator]

func (*AVPlaybackCoordinationMedium) Init ¶

Initializes an AVPlaybackCoordinationMedium

type AVPlaybackCoordinator ¶

type AVPlaybackCoordinator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplaybackcoordinator

func AVPlaybackCoordinatorFromID ¶

func AVPlaybackCoordinatorFromID(id objc.ID) *AVPlaybackCoordinator

func (*AVPlaybackCoordinator) BeginSuspensionForReason ¶

func (o *AVPlaybackCoordinator) BeginSuspensionForReason(suspensionReason *foundation.NSString) *AVCoordinatedPlaybackSuspension

Informs the coordinator that its playback object is detached from the group for some reason and should not receive any playback commands from the coordinator. Use this to tell the coordinator that its player cannot, or should not, participate in coordinated playback temporarily. The coordinator will not respond to playback commands coming from the group and it will also not send any commands to the group. To resume in group playback, end a suspension by calling one of the suspension's end methods. - Parameter suspensionReason: Indicates the reason for the suspension that is shared with other participants. Can be a system-defined reason (see AVCoordinatedPlaybackSuspensionReason*) or a custom string. - NOTE: See the description of AVPlaybackCoordinator subclasses for suspensions automatically begun on behalf of their playback objects, if any.

func (*AVPlaybackCoordinator) ExpectedItemTimeAtHostTime ¶

func (o *AVPlaybackCoordinator) ExpectedItemTimeAtHostTime(hostClockTime coremedia.CMTime) coremedia.CMTime

Returns the item time (for the current item) that the coordinator expects to be playing at a given host clock time. This method is useful to decide if it is appropriate to end a suspension, e.g. a suspension with AVCoordinatedPlaybackSuspensionReasonStallRecovery, while other participants are continuing playback.

func (*AVPlaybackCoordinator) OtherParticipants ¶

The playback states of the other participants in the group. Use this property to create UI informing the local user about the state of other participants in the group. - NOTE: The coordinator posts AVPlaybackCoordinatorOtherParticipantsDidChangeNotification when the contents of the array changes.

func (*AVPlaybackCoordinator) ParticipantLimitForWaitingOutSuspensionsWithReason ¶

func (o *AVPlaybackCoordinator) ParticipantLimitForWaitingOutSuspensionsWithReason(reason *foundation.NSString) int

Returns the maximum number of participants that can be in a group before the coordinator stops waiting out this particular suspensions reason. Default value is NSIntegerMax.

func (*AVPlaybackCoordinator) PauseSnapsToMediaTimeOfOriginator ¶

func (o *AVPlaybackCoordinator) PauseSnapsToMediaTimeOfOriginator() bool

Determines if participants should mirror the originator's stop time when pausing. If YES, all participants will seek to the originator's stop time after they pause. Use this if it is desirable to counteract any network delay incurred by communicating the originator's pause to the other participants. If NO, it's acceptable for participants to stop at slightly different offsets and a pause will not cause other participants' time to jump back.

func (*AVPlaybackCoordinator) SetParticipantLimitForWaitingOutSuspensionsWithReason ¶

func (o *AVPlaybackCoordinator) SetParticipantLimitForWaitingOutSuspensionsWithReason(participantLimit int, reason *foundation.NSString)

Sets the amount of participants that can join a group before the coordinator stops waiting for this particular suspension reason. This allows additional configuration for suspension reasons in the suspensionReasonsThatTriggerWaiting array. When the coordinator decides whether one participant's suspensions should cause others to wait, it will also consider this limit of participants currently in the group.

func (*AVPlaybackCoordinator) SetPauseSnapsToMediaTimeOfOriginator ¶

func (o *AVPlaybackCoordinator) SetPauseSnapsToMediaTimeOfOriginator(pauseSnapsToMediaTimeOfOriginator bool)

func (*AVPlaybackCoordinator) SetSuspensionReasonsThatTriggerWaiting ¶

func (o *AVPlaybackCoordinator) SetSuspensionReasonsThatTriggerWaiting(suspensionReasonsThatTriggerWaiting *foundation.NSArray[*foundation.NSString])

func (*AVPlaybackCoordinator) SuspensionReasons ¶

func (o *AVPlaybackCoordinator) SuspensionReasons() *foundation.NSArray[*foundation.NSString]

Describes why the coordinator is currently not able to participate in group playback. If the list of reasons is non-empty, the coordinator will not react to any changes of group playback state.

func (*AVPlaybackCoordinator) SuspensionReasonsThatTriggerWaiting ¶

func (o *AVPlaybackCoordinator) SuspensionReasonsThatTriggerWaiting() *foundation.NSArray[*foundation.NSString]

If the coordinator decides to delay playback to wait for others, it will wait out these reasons, but not others.

type AVPlaybackCoordinatorPlaybackControlDelegate ¶

type AVPlaybackCoordinatorPlaybackControlDelegate interface {
	PlaybackCoordinatorDidIssuePlayCommandCompletionHandler(coordinator *AVDelegatingPlaybackCoordinator, playCommand *AVDelegatingPlaybackCoordinatorPlayCommand, completionHandler func())
	PlaybackCoordinatorDidIssuePauseCommandCompletionHandler(coordinator *AVDelegatingPlaybackCoordinator, pauseCommand *AVDelegatingPlaybackCoordinatorPauseCommand, completionHandler func())
	PlaybackCoordinatorDidIssueSeekCommandCompletionHandler(coordinator *AVDelegatingPlaybackCoordinator, seekCommand *AVDelegatingPlaybackCoordinatorSeekCommand, completionHandler func())
	PlaybackCoordinatorDidIssueBufferingCommandCompletionHandler(coordinator *AVDelegatingPlaybackCoordinator, bufferingCommand *AVDelegatingPlaybackCoordinatorBufferingCommand, completionHandler func())
}

AVPlaybackCoordinatorPlaybackControlDelegate wraps the ObjC protocol AVPlaybackCoordinatorPlaybackControlDelegate.

type AVPlayer ¶

type AVPlayer struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayer

func AVPlayerFromID ¶

func AVPlayerFromID(id objc.ID) *AVPlayer

func AVPlayerPlayerWithPlayerItem ¶

func AVPlayerPlayerWithPlayerItem(item *AVPlayerItem) *AVPlayer

Create an AVPlayer that plays a single audiovisual item. Useful in order to play items for which an AVAsset has previously been created. See -[AVPlayerItem initWithAsset:]. - Parameter item: - Returns: An instance of AVPlayer

func AVPlayerPlayerWithURL ¶

func AVPlayerPlayerWithURL(uRL *foundation.NSURL) *AVPlayer

Returns an instance of AVPlayer that plays a single audiovisual resource referenced by URL. Implicitly creates an AVPlayerItem. Clients can obtain the AVPlayerItem as it becomes the player's currentItem. - Parameter URL: - Returns: An instance of AVPlayer

func (*AVPlayer) ActionAtItemEnd ¶

func (o *AVPlayer) ActionAtItemEnd() AVPlayerActionAtItemEnd

Indicates the action that the player should perform when playback of an item reaches its end time. This property throws an exception if set to AVPlayerActionAtItemEndAdvance on an AVPlayer which is not an AVQueuePlayer.

func (*AVPlayer) AddBoundaryTimeObserverForTimesQueueUsing ¶

func (o *AVPlayer) AddBoundaryTimeObserverForTimesQueueUsing(times *foundation.NSArray[*foundation.NSValue], queue *foundation.NSObject, block func()) objc.ID

Requests invocation of a block when specified times are traversed during normal playback. Each call to -addPeriodicTimeObserverForInterval:queue:usingBlock: should be paired with a corresponding call to -removeTimeObserver:. Releasing the observer object without a call to -removeTimeObserver: will result in undefined behavior. - Parameter times: The times for which the observer requests notification, supplied as an array of NSValues carrying CMTimes. - Parameter queue: The serial queue onto which block should be enqueued. If you pass NULL, the main queue (obtained using dispatch_get_main_queue()) will be used. Passing a concurrent queue to this method will result in undefined behavior. - Parameter block: The block to be invoked when any of the specified times is crossed during normal playback. - Returns: An object conforming to the NSObject protocol. You must retain this returned value as long as you want the time observer to be invoked by the player. Pass this object to -removeTimeObserver: to cancel time observation.

func (*AVPlayer) AddPeriodicTimeObserverForIntervalQueueUsing ¶

func (o *AVPlayer) AddPeriodicTimeObserverForIntervalQueueUsing(interval coremedia.CMTime, queue *foundation.NSObject, block objc.Block) objc.ID

Requests invocation of a block during playback to report changing time. The block is invoked periodically at the interval specified, interpreted according to the timeline of the current item. The block is also invoked whenever time jumps and whenever playback starts or stops. If the interval corresponds to a very short interval in real time, the player may invoke the block less frequently than requested. Even so, the player will invoke the block sufficiently often for the client to update indications of the current time appropriately in its end-user interface. Each call to -addPeriodicTimeObserverForInterval:queue:usingBlock: should be paired with a corresponding call to -removeTimeObserver:. Releasing the observer object without a call to -removeTimeObserver: will result in undefined behavior. - Parameter interval: The interval of invocation of the block during normal playback, according to progress of the current time of the player. - Parameter queue: The serial queue onto which block should be enqueued. If you pass NULL, the main queue (obtained using dispatch_get_main_queue()) will be used. Passing a concurrent queue to this method will result in undefined behavior. - Parameter block: The block to be invoked periodically. - Returns: An object conforming to the NSObject protocol. You must retain this returned value as long as you want the time observer to be invoked by the player. Pass this object to -removeTimeObserver: to cancel time observation.

func (*AVPlayer) AllowsCaptureOfClearKeyVideo ¶

func (o *AVPlayer) AllowsCaptureOfClearKeyVideo() bool

func (*AVPlayer) AllowsExternalPlayback ¶

func (o *AVPlayer) AllowsExternalPlayback() bool

Indicates whether the player allows switching to "external playback" mode. The default value is YES.

func (*AVPlayer) AppliesMediaSelectionCriteriaAutomatically ¶

func (o *AVPlayer) AppliesMediaSelectionCriteriaAutomatically() bool

Indicates whether the receiver should apply the current selection criteria automatically to AVPlayerItems. For clients linked against the iOS 7 SDK or later or against the macOS 10.9 SDK or later, the default is YES. For all others, the default is NO. By default, AVPlayer applies selection criteria based on system preferences. To override the default criteria for any media selection group, use -[AVPlayer setMediaSelectionCriteria:forMediaCharacteristic:].

func (*AVPlayer) AudioOutputDeviceUniqueID ¶

func (o *AVPlayer) AudioOutputDeviceUniqueID() *foundation.NSString

func (*AVPlayer) AudiovisualBackgroundPlaybackPolicy ¶

func (o *AVPlayer) AudiovisualBackgroundPlaybackPolicy() AVPlayerAudiovisualBackgroundPlaybackPolicy

func (*AVPlayer) AutomaticallyWaitsToMinimizeStalling ¶

func (o *AVPlayer) AutomaticallyWaitsToMinimizeStalling() bool

Indicates that the player is allowed to delay playback at the specified rate in order to minimize stalling When this property is YES, whenever 1) the rate is set from zero to non-zero or 2) the playback buffer becomes empty and playback stalls, the player will attempt to determine if, at the specified rate, its currentItem will play to the end without interruptions. Should it determine that such interruptions would occur and these interruptions can be avoided by delaying the start or resumption of playback, the value of timeControlStatus will become AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate and playback will start automatically when the likelihood of stalling has been minimized. You may want to set this property to NO when you need precise control over playback start times, e.g., when synchronizing multiple instances of AVPlayer, and you should set it to NO if you use an AVAssetResourceLoader delegate to load media data (more on this below). If the value of this property is NO, reasonForWaitingToPlay cannot assume a value of AVPlayerWaitingToMinimizeStallsReason. This implies that setting rate to a non-zero value in AVPlayerTimeControlStatusPaused will cause playback to start immediately as long as the playback buffer is not empty. When the playback buffer becomes empty during AVPlayerTimeControlStatusPlaying and playback stalls, playback state will switch to AVPlayerTimeControlStatusPaused and the rate will become 0.0. Changing the value of this property to NO while the value of timeControlStatus is AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate with a reasonForWaitingToPlay of AVPlayerWaitingToMinimizeStallsReason will cause the player to attempt playback at the specified rate immediately. For clients linked against iOS 10.0 and running on that version or later or linked against macOS 10.12 and running on that version or later, the default value of this property is YES. In versions of iOS prior to iOS 10.0 and versions of macOS prior to 10.12, this property is unavailable, and the behavior of the AVPlayer corresponds to the type of content being played. For streaming content, including HTTP Live Streaming, the AVPlayer acts as if automaticallyWaitsToMinimizeStalling is YES. For file-based content, including file-based content accessed via progressive http download, the AVPlayer acts as if automaticallyWaitsToMinimizeStalling is NO. If you employ an AVAssetResourceLoader delegate that loads media data for playback, you should set the value of your AVPlayer’s automaticallyWaitsToMinimizeStalling property to NO. Allowing the value of automaticallyWaitsToMinimizeStalling to remain YES when an AVAssetResourceLoader delegate is used for the loading of media data can result in poor start-up times for playback and poor recovery from stalls, because the behaviors provided by AVPlayer when automaticallyWaitsToMinimizeStalling has a value of YES depend on predictions of the future availability of media data that that do not function as expected when data is loaded via a client-controlled means, using the AVAssetResourceLoader delegate interface. You can allow the value of automaticallyWaitsToMinimizeStalling to remain YES if you use an AVAssetResourceLoader delegate to manage content keys for FairPlay Streaming, to provide dynamically-generated master playlists for HTTP Live Streaming, or to respond to authentication challenges, but not to load media data for playback. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayer) CancelPendingPrerolls ¶

func (o *AVPlayer) CancelPendingPrerolls()

Cancel any pending preroll requests and invoke the corresponding completion handlers if present. Use this method to cancel and release the completion handlers for pending prerolls. The finished parameter of the completion handlers will be set to NO.

func (*AVPlayer) CurrentItem ¶

func (o *AVPlayer) CurrentItem() *AVPlayerItem

Indicates the current item of the player

func (*AVPlayer) CurrentTime ¶

func (o *AVPlayer) CurrentTime() coremedia.CMTime

Returns the current time of the current item. Returns the current time of the current item. Not key-value observable; use -addPeriodicTimeObserverForInterval:queue:usingBlock: instead. - Returns: A CMTime

func (*AVPlayer) DefaultRate ¶

func (o *AVPlayer) DefaultRate() float32

Indicates the rate at which to start playback when play is called; defaults to 1.0. Setting this property does not imply playback starts automatically at this rate. Clients still have to kick off playback using `play`. Note that using setRate to start playback will skip using the value in this property nor would it update this property. Therefore, `setRate:1.0` is no longer recommended as a means to start playback. Use `play` instead. Use `setRate` for operations like scanning where the rate is to be updated instantaneously. Invoking `play` again would restore playback at the rate set in this property. The effective rate of playback may still differ from the default rate subject to restrictions imposed by the system. See documentation for the rate property for a discussion on when the desired rate does not translate to effective rate.

func (*AVPlayer) Error ¶

func (o *AVPlayer) Error() unsafe.Pointer

If the receiver's status is AVPlayerStatusFailed, this describes the error that caused the failure. The value of this property is an NSError that describes what caused the receiver to no longer be able to play items. If the receiver's status is not AVPlayerStatusFailed, the value of this property is nil.

func (*AVPlayer) Init ¶

func (o *AVPlayer) Init() *AVPlayer

Initializes an AVPlayer with no player items.

func (*AVPlayer) InitWithPlayerItem ¶

func (o *AVPlayer) InitWithPlayerItem(item *AVPlayerItem) *AVPlayer

Create an AVPlayer that plays a single audiovisual item. Useful in order to play items for which an AVAsset has previously been created. See -[AVPlayerItem initWithAsset:]. This method throws an exception if the item is not an AVPlayerItem, or if the item is associated with another AVPlayer. - Parameter item: - Returns: An instance of AVPlayer

func (*AVPlayer) InitWithURL ¶

func (o *AVPlayer) InitWithURL(uRL *foundation.NSURL) *AVPlayer

Initializes an AVPlayer that plays a single audiovisual resource referenced by URL. Implicitly creates an AVPlayerItem. Clients can obtain the AVPlayerItem as it becomes the player's currentItem. - Parameter URL: - Returns: An instance of AVPlayer

func (*AVPlayer) IntendedSpatialAudioExperience ¶

func (o *AVPlayer) IntendedSpatialAudioExperience() unsafe.Pointer

func (*AVPlayer) IsClosedCaptionDisplayEnabled ¶

func (o *AVPlayer) IsClosedCaptionDisplayEnabled() bool

Indicates whether display of closed captions is enabled. This property is deprecated. When the value of appliesMediaSelectionCriteriaAutomatically is YES, the receiver will enable closed captions automatically either according to user preferences or, if you provide them, according to AVPlayerMediaSelectionCriteria for the media characteristic AVMediaCharacteristicLegible. If you want to determine whether closed captions may be available for a given AVPlayerItem, you can examine the AVMediaSelectionOptions in the AVMediaSelectionGroup for the characteristic AVMediaCharacteristicLegible, as vended by -[AVAsset mediaSelectionGroupForMediaCharacteristic:]. See AVMediaCharacteristicTranscribesSpokenDialogForAccessibility and AVMediaCharacteristicDescribesMusicAndSoundForAccessibility as documented in AVMediaFormat.h for information about how to identify legible media selection options that offer the features of closed captions for accessibility purposes. You can select or deselect a specific AVMediaSelectionOption via -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:]. For further information about Media Accessibility preferences, see MediaAccessibility framework documentation. Deprecated: Allow AVPlayer to enable closed captions automatically according to user preferences by ensuring that the value of appliesMediaSelectionCriteriaAutomatically is YES.

func (*AVPlayer) IsExternalPlaybackActive ¶

func (o *AVPlayer) IsExternalPlaybackActive() bool

Indicates whether the player is currently playing video in "external playback" mode.

func (*AVPlayer) IsMuted ¶

func (o *AVPlayer) IsMuted() bool

Indicates whether or not audio output of the player is muted. Only affects audio muting for the player instance and not for the device.

func (*AVPlayer) MasterClock ¶

func (o *AVPlayer) MasterClock() unsafe.Pointer

Use sourceClock instead. Deprecated: since macOS 15.0.

func (*AVPlayer) MediaSelectionCriteriaForMediaCharacteristic ¶

func (o *AVPlayer) MediaSelectionCriteriaForMediaCharacteristic(mediaCharacteristic *foundation.NSString) *AVPlayerMediaSelectionCriteria

Returns the automatic selection criteria for media that has the specified media characteristic. - Parameter mediaCharacteristic: The media characteristic for which the selection criteria is to be returned. Supported values include AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, and AVMediaCharacteristicVisual. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue.

func (*AVPlayer) NetworkResourcePriority ¶

func (o *AVPlayer) NetworkResourcePriority() AVPlayerNetworkResourcePriority

func (*AVPlayer) OutputObscuredDueToInsufficientExternalProtection ¶

func (o *AVPlayer) OutputObscuredDueToInsufficientExternalProtection() bool

func (*AVPlayer) Pause ¶

func (o *AVPlayer) Pause()

Pauses playback. Equivalent to setting the value of rate to 0.0. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue.

func (*AVPlayer) Play ¶

func (o *AVPlayer) Play()

Signals the desire to begin playback at the rate set in the defaultRate. For releases up to iOS version 16.0, macOS versions 13.0, tvOS 16.0 and watchOS 9.0, this is equivalent to setting the value of rate to `1.0`. Starting from iOS version 16.0, macOS versions 13.0, tvOS 16.0 and watchOS 9.0, this will attempt to use the rate set in the `defaultRate` property. The effective rate of playback may differ from the `defaultRate` due to the reasons mentioned in the documentation of the `rate` property. Clients interested in knowing the effective rate can listen for `AVPlayerRateDidChangeNotification` notification. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue.

func (*AVPlayer) PlayImmediatelyAtRate ¶

func (o *AVPlayer) PlayImmediatelyAtRate(rate float32)

Immediately plays the available media data at the specified rate. When the player's currentItem has a value of NO for playbackBufferEmpty, this method causes the value of rate to change to the specified rate, the value of timeControlStatus to change to AVPlayerTimeControlStatusPlaying, and the receiver to play the available media immediately, whether or not prior buffering of media data is sufficient to ensure smooth playback. If insufficient media data is buffered for playback to start (e.g. if the current item has a value of YES for playbackBufferEmpty), the receiver will act as if the buffer became empty during playback, except that no AVPlayerItemPlaybackStalledNotification will be posted. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue.

func (*AVPlayer) PlaybackCoordinator ¶

func (o *AVPlayer) PlaybackCoordinator() *AVPlayerPlaybackCoordinator

The playback coordinator for this player. If the playback coordinator is connected to other participants, rate changes and seeks on the current item will be automatically mirrored to all connected participants. Depending on policies, the coordinator may also intercept rate changes to non-zero to coordinate playback start with the rest of the group. Use [AVPlayer playImmediatelyAtRate:] to override the coordinated startup behavior and start playback immediately. This is useful to give users an opportunity to override waiting caused by other participants' suspensions. Player configuration other than rate and seeks are not communicated to other participants and can be configured independently by each participant. A player with a connected playbackCoordinator will change behavior in situations that require the player to pause for internal reasons, such as a route change or a stall. When resuming after these events, the player will not resume at the stop time. Instead, it will attempt to rejoin the group, potentially seeking to match the other participant's progress. It is left to the owner of the AVPlayer to ensure that all participants are playing the same item. See the discussion of AVPlaybackCoordinator for considerations about item transitions.

func (*AVPlayer) PreferredVideoDecoderGPURegistryID ¶

func (o *AVPlayer) PreferredVideoDecoderGPURegistryID() uint64

func (*AVPlayer) PrerollAtRateCompletionHandler ¶

func (o *AVPlayer) PrerollAtRateCompletionHandler(rate float32, completionHandler func(bool))

Begins loading media data to prime the render pipelines for playback from the current time with the given rate. Once the completion handler is called with YES, the player's rate can be set with minimal latency. The completion handler will be called with NO if the preroll is interrupted by a time change or incompatible rate change, or if preroll is not possible for some other reason. Call this method only when the rate is currently zero and only after the AVPlayer's status has become AVPlayerStatusReadyToPlay. This method throws an exception if the status is not AVPlayerStatusReadyToPlay. - Parameter rate: The intended rate for subsequent playback. - Parameter completionHandler: The block that will be called when the preroll is either completed or is interrupted.

func (*AVPlayer) PreventsDisplaySleepDuringVideoPlayback ¶

func (o *AVPlayer) PreventsDisplaySleepDuringVideoPlayback() bool

Indicates whether video playback prevents display and device sleep. Default is YES on iOS, tvOS and in Mac Catalyst apps. Default is NO on macOS. Setting this property to NO does not force the display to sleep, it simply stops preventing display sleep. Other apps or frameworks within your app may still be preventing display sleep for various reasons. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayer) Rate ¶

func (o *AVPlayer) Rate() float32

Indicates the desired rate of playback; 0.0 means "paused", 1.0 indicates a desire to play at the natural rate of the current item. Setting the value of rate to 0.0 pauses playback, causing the value of timeControlStatus to change to AVPlayerTimeControlStatusPaused. Setting the rate to a non-zero value causes the value of timeControlStatus to become either AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate or AVPlayerTimeControlStatusPlaying, depending on whether sufficient media data has been buffered for playback to occur and whether the player's default behavior of waiting in order to minimize stalling is permitted. See discussion of AVPlayerTimeControlStatus for more details. AVPlayer can reset the desired rate to 0.0 when a change in overall state requires playback to be halted, such as when an interruption occurs on iOS, as announced by AVAudioSession, or when the playback buffer becomes empty and playback stalls while automaticallyWaitsToMinimizeStalling is NO. The effective rate of playback may differ from the desired rate even while timeControlStatus is AVPlayerTimeControlStatusPlaying, if the processing algorithm in use for managing audio pitch requires quantization of playback rate. For information about quantization of rates for audio processing, see AVAudioProcessingSettings.h. You can always obtain the effective rate of playback from the currentItem's timebase; see the timebase property of AVPlayerItem. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayer) ReasonForWaitingToPlay ¶

func (o *AVPlayer) ReasonForWaitingToPlay() *foundation.NSString

Indicates the reason for waiting when the value of timeControlStatus is AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate When the value of timeControlStatus is AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate, this property describes why the player is currently waiting. It is nil otherwise. You can use the value of reasonForWaitingToPlay to show UI indicating the player's waiting state conditionally. This property is key value observable. Possible values are AVPlayerWaitingWithNoItemToPlayReason, AVPlayerWaitingWhileEvaluatingBufferingRateReason, and AVPlayerWaitingToMinimizeStallsReason.

func (*AVPlayer) RemoveTimeObserver ¶

func (o *AVPlayer) RemoveTimeObserver(observer objc.ID)

Cancels a previously registered time observer. Upon return, the caller is guaranteed that no new time observer blocks will begin executing. Depending on the calling thread and the queue used to add the time observer, an in-flight block may continue to execute after this method returns. You can guarantee synchronous time observer removal by enqueuing the call to -removeTimeObserver: on that queue. Alternatively, call dispatch_sync(queue, ^{}) after -removeTimeObserver: to wait for any in-flight blocks to finish executing. -removeTimeObserver: should be used to explicitly cancel each time observer added using -addPeriodicTimeObserverForInterval:queue:usingBlock: and -addBoundaryTimeObserverForTimes:queue:usingBlock:. This method throws an exception for any of the following reasons: - observer was added by a different instance of AVPlayer - observer was not returned by -addPeriodicTimeObserverForInterval:queue:usingBlock: - observer was not returned by -addBoundaryTimeObserverForTimes:queue:usingBlock: - Parameter observer: An object returned by a previous call to -addPeriodicTimeObserverForInterval:queue:usingBlock: or -addBoundaryTimeObserverForTimes:queue:usingBlock:.

func (*AVPlayer) ReplaceCurrentItemWithPlayerItem ¶

func (o *AVPlayer) ReplaceCurrentItemWithPlayerItem(item *AVPlayerItem)

Replaces the player's current item with the specified player item. In all releases of iOS 4, invoking replaceCurrentItemWithPlayerItem: with an AVPlayerItem that's already the receiver's currentItem results in an exception being raised. Starting with iOS 5, it's a no-op. This method throws an exception if the item already exists in the play queue. - Parameter item: The AVPlayerItem that will become the player's current item.

func (*AVPlayer) SeekToDate ¶

func (o *AVPlayer) SeekToDate(date *foundation.NSDate)

Moves the playback cursor. Use this method to seek to a specified time for the current player item. The time seeked to may differ from the specified time for efficiency. For sample accurate seeking see seekToTime:toleranceBefore:toleranceAfter:. - Parameter date:

func (*AVPlayer) SeekToDateCompletionHandler ¶

func (o *AVPlayer) SeekToDateCompletionHandler(date *foundation.NSDate, completionHandler func(bool))

Moves the playback cursor and invokes the specified block when the seek operation has either been completed or been interrupted. Use this method to seek to a specified time for the current player item and to be notified when the seek operation is complete. The completion handler for any prior seek request that is still in process will be invoked immediately with the finished parameter set to NO. If the new request completes without being interrupted by another seek request or by any other operation the specified completion handler will be invoked with the finished parameter set to YES. If no item is attached, the completion handler will be invoked immediately with the finished parameter set to NO. - Parameter date: - Parameter completionHandler:

func (*AVPlayer) SeekToTime ¶

func (o *AVPlayer) SeekToTime(time_ coremedia.CMTime)

Moves the playback cursor. Use this method to seek to a specified time for the current player item. The time seeked to may differ from the specified time for efficiency. For sample accurate seeking see seekToTime:toleranceBefore:toleranceAfter:. - Parameter time:

func (*AVPlayer) SeekToTimeCompletionHandler ¶

func (o *AVPlayer) SeekToTimeCompletionHandler(time_ coremedia.CMTime, completionHandler func(bool))

Moves the playback cursor and invokes the specified block when the seek operation has either been completed or been interrupted. Use this method to seek to a specified time for the current player item and to be notified when the seek operation is complete. The completion handler for any prior seek request that is still in process will be invoked immediately with the finished parameter set to NO. If the new request completes without being interrupted by another seek request or by any other operation the specified completion handler will be invoked with the finished parameter set to YES. If no item is attached, the completion handler will be invoked immediately with the finished parameter set to NO. - Parameter time: - Parameter completionHandler:

func (*AVPlayer) SeekToTimeToleranceBeforeToleranceAfter ¶

func (o *AVPlayer) SeekToTimeToleranceBeforeToleranceAfter(time_ coremedia.CMTime, toleranceBefore coremedia.CMTime, toleranceAfter coremedia.CMTime)

Moves the playback cursor within a specified time bound. Use this method to seek to a specified time for the current player item. The time seeked to will be within the range [time-toleranceBefore, time+toleranceAfter] and may differ from the specified time for efficiency. Pass kCMTimeZero for both toleranceBefore and toleranceAfter to request sample accurate seeking which may incur additional decoding delay. Messaging this method with beforeTolerance:kCMTimePositiveInfinity and afterTolerance:kCMTimePositiveInfinity is the same as messaging seekToTime: directly. - Parameter time: - Parameter toleranceBefore: - Parameter toleranceAfter:

func (*AVPlayer) SeekToTimeToleranceBeforeToleranceAfterCompletionHandler ¶

func (o *AVPlayer) SeekToTimeToleranceBeforeToleranceAfterCompletionHandler(time_ coremedia.CMTime, toleranceBefore coremedia.CMTime, toleranceAfter coremedia.CMTime, completionHandler func(bool))

Moves the playback cursor within a specified time bound and invokes the specified block when the seek operation has either been completed or been interrupted. Use this method to seek to a specified time for the current player item and to be notified when the seek operation is complete. The time seeked to will be within the range [time-toleranceBefore, time+toleranceAfter] and may differ from the specified time for efficiency. Pass kCMTimeZero for both toleranceBefore and toleranceAfter to request sample accurate seeking which may incur additional decoding delay. Messaging this method with beforeTolerance:kCMTimePositiveInfinity and afterTolerance:kCMTimePositiveInfinity is the same as messaging seekToTime: directly. The completion handler for any prior seek request that is still in process will be invoked immediately with the finished parameter set to NO. If the new request completes without being interrupted by another seek request or by any other operation the specified completion handler will be invoked with the finished parameter set to YES. If no item is attached, the completion handler will be invoked immediately with the finished parameter set to NO. - Parameter time: - Parameter toleranceBefore: - Parameter toleranceAfter:

func (*AVPlayer) SetActionAtItemEnd ¶

func (o *AVPlayer) SetActionAtItemEnd(actionAtItemEnd AVPlayerActionAtItemEnd)

func (*AVPlayer) SetAllowsCaptureOfClearKeyVideo ¶

func (o *AVPlayer) SetAllowsCaptureOfClearKeyVideo(allowsCaptureOfClearKeyVideo bool)

func (*AVPlayer) SetAllowsExternalPlayback ¶

func (o *AVPlayer) SetAllowsExternalPlayback(allowsExternalPlayback bool)

func (*AVPlayer) SetAppliesMediaSelectionCriteriaAutomatically ¶

func (o *AVPlayer) SetAppliesMediaSelectionCriteriaAutomatically(appliesMediaSelectionCriteriaAutomatically bool)

func (*AVPlayer) SetAudioOutputDeviceUniqueID ¶

func (o *AVPlayer) SetAudioOutputDeviceUniqueID(audioOutputDeviceUniqueID *foundation.NSString)

func (*AVPlayer) SetAudiovisualBackgroundPlaybackPolicy ¶

func (o *AVPlayer) SetAudiovisualBackgroundPlaybackPolicy(audiovisualBackgroundPlaybackPolicy AVPlayerAudiovisualBackgroundPlaybackPolicy)

func (*AVPlayer) SetAutomaticallyWaitsToMinimizeStalling ¶

func (o *AVPlayer) SetAutomaticallyWaitsToMinimizeStalling(automaticallyWaitsToMinimizeStalling bool)

Indicates that the player is allowed to delay playback at the specified rate in order to minimize stalling When this property is YES, whenever 1) the rate is set from zero to non-zero or 2) the playback buffer becomes empty and playback stalls, the player will attempt to determine if, at the specified rate, its currentItem will play to the end without interruptions. Should it determine that such interruptions would occur and these interruptions can be avoided by delaying the start or resumption of playback, the value of timeControlStatus will become AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate and playback will start automatically when the likelihood of stalling has been minimized. You may want to set this property to NO when you need precise control over playback start times, e.g., when synchronizing multiple instances of AVPlayer, and you should set it to NO if you use an AVAssetResourceLoader delegate to load media data (more on this below). If the value of this property is NO, reasonForWaitingToPlay cannot assume a value of AVPlayerWaitingToMinimizeStallsReason. This implies that setting rate to a non-zero value in AVPlayerTimeControlStatusPaused will cause playback to start immediately as long as the playback buffer is not empty. When the playback buffer becomes empty during AVPlayerTimeControlStatusPlaying and playback stalls, playback state will switch to AVPlayerTimeControlStatusPaused and the rate will become 0.0. Changing the value of this property to NO while the value of timeControlStatus is AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate with a reasonForWaitingToPlay of AVPlayerWaitingToMinimizeStallsReason will cause the player to attempt playback at the specified rate immediately. For clients linked against iOS 10.0 and running on that version or later or linked against macOS 10.12 and running on that version or later, the default value of this property is YES. In versions of iOS prior to iOS 10.0 and versions of macOS prior to 10.12, this property is unavailable, and the behavior of the AVPlayer corresponds to the type of content being played. For streaming content, including HTTP Live Streaming, the AVPlayer acts as if automaticallyWaitsToMinimizeStalling is YES. For file-based content, including file-based content accessed via progressive http download, the AVPlayer acts as if automaticallyWaitsToMinimizeStalling is NO. If you employ an AVAssetResourceLoader delegate that loads media data for playback, you should set the value of your AVPlayer’s automaticallyWaitsToMinimizeStalling property to NO. Allowing the value of automaticallyWaitsToMinimizeStalling to remain YES when an AVAssetResourceLoader delegate is used for the loading of media data can result in poor start-up times for playback and poor recovery from stalls, because the behaviors provided by AVPlayer when automaticallyWaitsToMinimizeStalling has a value of YES depend on predictions of the future availability of media data that that do not function as expected when data is loaded via a client-controlled means, using the AVAssetResourceLoader delegate interface. You can allow the value of automaticallyWaitsToMinimizeStalling to remain YES if you use an AVAssetResourceLoader delegate to manage content keys for FairPlay Streaming, to provide dynamically-generated master playlists for HTTP Live Streaming, or to respond to authentication challenges, but not to load media data for playback. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayer) SetClosedCaptionDisplayEnabled deprecated

func (o *AVPlayer) SetClosedCaptionDisplayEnabled(closedCaptionDisplayEnabled bool)

Deprecated: Allow AVPlayer to enable closed captions automatically according to user preferences by ensuring that the value of appliesMediaSelectionCriteriaAutomatically is YES.

func (*AVPlayer) SetDefaultRate ¶

func (o *AVPlayer) SetDefaultRate(defaultRate float32)

func (*AVPlayer) SetIntendedSpatialAudioExperience ¶

func (o *AVPlayer) SetIntendedSpatialAudioExperience(intendedSpatialAudioExperience unsafe.Pointer)

func (*AVPlayer) SetMasterClock deprecated

func (o *AVPlayer) SetMasterClock(masterClock unsafe.Pointer)

Deprecated: since macOS 15.0.

func (*AVPlayer) SetMediaSelectionCriteriaForMediaCharacteristic ¶

func (o *AVPlayer) SetMediaSelectionCriteriaForMediaCharacteristic(criteria *AVPlayerMediaSelectionCriteria, mediaCharacteristic *foundation.NSString)

Applies automatic selection criteria for media that has the specified media characteristic. Criteria will be applied to an AVPlayerItem when: a) It is made ready to play b) Specific media selections are made by -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:] in a different group. The automatic choice in one group may be influenced by a specific selection in another group. c) Underlying system preferences change, e.g. system language, accessibility captions. Specific selections made by -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:] within any group will override automatic selection in that group until -[AVPlayerItem selectMediaOptionAutomaticallyInMediaSelectionGroup:] is received. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue. - Parameter criteria: An instance of AVPlayerMediaSelectionCriteria. - Parameter mediaCharacteristic: The media characteristic for which the selection criteria are to be applied. Supported values include AVMediaCharacteristicAudible, AVMediaCharacteristicLegible, and AVMediaCharacteristicVisual.

func (*AVPlayer) SetMuted ¶

func (o *AVPlayer) SetMuted(muted bool)

func (*AVPlayer) SetNetworkResourcePriority ¶

func (o *AVPlayer) SetNetworkResourcePriority(networkResourcePriority AVPlayerNetworkResourcePriority)

func (*AVPlayer) SetPreferredVideoDecoderGPURegistryID ¶

func (o *AVPlayer) SetPreferredVideoDecoderGPURegistryID(preferredVideoDecoderGPURegistryID uint64)

func (*AVPlayer) SetPreventsDisplaySleepDuringVideoPlayback ¶

func (o *AVPlayer) SetPreventsDisplaySleepDuringVideoPlayback(preventsDisplaySleepDuringVideoPlayback bool)

Indicates whether video playback prevents display and device sleep. Default is YES on iOS, tvOS and in Mac Catalyst apps. Default is NO on macOS. Setting this property to NO does not force the display to sleep, it simply stops preventing display sleep. Other apps or frameworks within your app may still be preventing display sleep for various reasons. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayer) SetRate ¶

func (o *AVPlayer) SetRate(rate float32)

func (*AVPlayer) SetRateTimeAtHostTime ¶

func (o *AVPlayer) SetRateTimeAtHostTime(rate float32, itemTime coremedia.CMTime, hostClockTime coremedia.CMTime)

Simultaneously sets the playback rate and the relationship between the current item's current time and host time. You can use this function to synchronize playback with an external activity. The current item's timebase is adjusted so that its time will be (or was) itemTime when host time is (or was) hostClockTime. In other words: if hostClockTime is in the past, the timebase's time will be interpolated as though the timebase has been running at the requested rate since that time. If hostClockTime is in the future, the timebase will immediately start running at the requested rate from an earlier time so that it will reach the requested itemTime at the requested hostClockTime. (Note that the item's time will not jump backwards, but instead will sit at itemTime until the timebase reaches that time.) Note that setRate:time:atHostTime: is not supported when automaticallyWaitsToMinimizeStalling is YES. For clients linked against iOS 10.0 and later or macOS 12.0 and later, invoking setRate:time:atHostTime: when automaticallyWaitsToMinimizeStalling is YES will raise an NSInvalidArgument exception. Support for HTTP Live Streaming content requires iOS 11, tvOS 11, macOS 10.13 or later. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue. - Parameter itemTime: The time to start playback from, specified precisely (i.e., with zero tolerance). Pass kCMTimeInvalid to use the current item's current time. - Parameter hostClockTime: The host time at which to start playback. If hostClockTime is specified, the player will not ensure that media data is loaded before the timebase starts moving. If hostClockTime is kCMTimeInvalid, the rate and time will be set together, but without external synchronization; a host time in the near future will be used, allowing some time for media data loading.

func (*AVPlayer) SetSourceClock ¶

func (o *AVPlayer) SetSourceClock(sourceClock unsafe.Pointer)

func (*AVPlayer) SetVideoOutput ¶

func (o *AVPlayer) SetVideoOutput(videoOutput *AVPlayerVideoOutput)

func (*AVPlayer) SetVolume ¶

func (o *AVPlayer) SetVolume(volume float32)

func (*AVPlayer) SourceClock ¶

func (o *AVPlayer) SourceClock() unsafe.Pointer

Set to override the automatic choice of source clock for item timebases. NULL by default. This is most useful for synchronizing video-only movies with audio played via other means. IMPORTANT NOTE: If you specify a source clock other than the appropriate audio device clock, audio may drift out of sync.

func (*AVPlayer) Status ¶

func (o *AVPlayer) Status() AVPlayerStatus

The ability of the receiver to be used for playback. The value of this property is an AVPlayerStatus that indicates whether the receiver can be used for playback. When the value of this property is AVPlayerStatusFailed, the receiver can no longer be used for playback and a new instance needs to be created in its place. When this happens, clients can check the value of the error property to determine the nature of the failure. This property is key value observable.

func (*AVPlayer) TimeControlStatus ¶

func (o *AVPlayer) TimeControlStatus() AVPlayerTimeControlStatus

Indicates whether playback is currently paused indefinitely, suspended while waiting for appropriate conditions, or in progress. For possible values and discussion, see AVPlayerTimeControlStatus. When automaticallyWaitsToMinimizeStalling is YES, absent intervention in the form of invocations of -setRate: or -pause or, on iOS, an interruption that requires user intervention before playback can resume, the value of the property timeControlStatus automatically changes between AVPlayerTimeControlStatusPlaying and AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate depending on whether sufficient media data is available to continue playback. This property is key value observable.

func (*AVPlayer) VideoOutput ¶

func (o *AVPlayer) VideoOutput() *AVPlayerVideoOutput

func (*AVPlayer) Volume ¶

func (o *AVPlayer) Volume() float32

Indicates the current audio volume of the player; 0.0 means "silence all audio", 1.0 means "play at the full volume of the current item". iOS note: Do not use this property to implement a volume slider for media playback. For that purpose, use MPVolumeView, which is customizable in appearance and provides standard media playback behaviors that users expect. This property is most useful on iOS to control the volume of the AVPlayer relative to other audio output, not for volume control by end users.

type AVPlayerActionAtItemEnd ¶

type AVPlayerActionAtItemEnd int64
const (
	// Indicates that when an AVPlayerItem reaches its end time the player will automatically advance to the next item in its queue. This value is supported only for players of class AVQueuePlayer. An AVPlayer that's not an AVQueuePlayer will raise an NSInvalidArgumentException if an attempt is made to set its actionAtItemEnd to AVPlayerActionAtItemEndAdvance.
	AVPlayerActionAtItemEndAdvance AVPlayerActionAtItemEnd = 0
	// Indicates that when an AVPlayerItem reaches its end time the player will automatically pause (which is to say, the player's rate will automatically be set to 0).
	AVPlayerActionAtItemEndPause AVPlayerActionAtItemEnd = 1
	// Indicates that when an AVPlayerItem reaches its end time the player will take no action (which is to say, the player's rate will not change, its currentItem will not change, and its currentTime will continue to be incremented or decremented as time elapses, according to its rate). After this, if the player's actionAtItemEnd is set to a value other than AVPlayerActionAtItemEndNone, the player will immediately take the action appropriate to that value.
	AVPlayerActionAtItemEndNone AVPlayerActionAtItemEnd = 2
)

func (AVPlayerActionAtItemEnd) String ¶

func (e AVPlayerActionAtItemEnd) String() string

type AVPlayerAudiovisualBackgroundPlaybackPolicy ¶

type AVPlayerAudiovisualBackgroundPlaybackPolicy int64
const (
	// Indicates that the system is free to decide. This is the default policy.
	AVPlayerAudiovisualBackgroundPlaybackPolicyAutomatic AVPlayerAudiovisualBackgroundPlaybackPolicy = 1
	// Indicates that the player must be paused on going to background.
	AVPlayerAudiovisualBackgroundPlaybackPolicyPauses AVPlayerAudiovisualBackgroundPlaybackPolicy = 2
	// Indicates that the player continues to play if possible in background.
	AVPlayerAudiovisualBackgroundPlaybackPolicyContinuesIfPossible AVPlayerAudiovisualBackgroundPlaybackPolicy = 3
)

func (AVPlayerAudiovisualBackgroundPlaybackPolicy) String ¶

type AVPlayerInterstitialEvent ¶

type AVPlayerInterstitialEvent struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayerinterstitialevent

func AVPlayerInterstitialEventFromID ¶

func AVPlayerInterstitialEventFromID(id objc.ID) *AVPlayerInterstitialEvent

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemDate ¶

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemDate(primaryItem *AVPlayerItem, date *foundation.NSDate) *AVPlayerInterstitialEvent

Returns an instance of AVPlayerInterstitialEvent for use in scheduling interstitial playback. - Parameter primaryItem: An AVPlayerItem representing the primary content during the playback of which the interstitial event should occur. The primaryItem must have an AVAsset that provides an intrinsic mapping from its timeline to real-time dates. - Parameter date: The date within the date range of the primary item at which playback of the primary content should be temporarily suspended and the interstitial items played. - Returns: An instance of AVPlayerInterstitialEvent.

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemIdentifierDateTemplateItemsRestrictionsResumptionOffsetPlayoutLimitUserDefinedAttributes ¶

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemIdentifierDateTemplateItemsRestrictionsResumptionOffsetPlayoutLimitUserDefinedAttributes(primaryItem *AVPlayerItem, identifier *foundation.NSString, date *foundation.NSDate, templateItems *foundation.NSArray[*AVPlayerItem], restrictions AVPlayerInterstitialEventRestrictions, resumptionOffset coremedia.CMTime, playoutLimit coremedia.CMTime, userDefinedAttributes *foundation.NSDictionary[objc.ID, objc.ID]) *AVPlayerInterstitialEvent

Returns an instance of AVPlayerInterstitialEvent for use in scheduling interstitial playback. - Parameter primaryItem: An AVPlayerItem representing the primary content during the playback of which the interstitial event should occur. The primaryItem must have an AVAsset that provides an intrinsic mapping from its timeline to real-time dates. - Parameter identifier: An external identifier for the event. - Parameter date: The date within the date range of the primary item at which playback of the primary content should be temporarily suspended and the interstitial items played. - Parameter templateItems: An array of AVPlayerItems with configurations that will be reproduced for the playback of interstitial content. An NSInvalidArgumentException will be raised if any of the template items employs an AVAsset that lacks a URL, such as an AVComposition. - Parameter restrictions: Indicates restrictions on the use of end user playback controls that are imposed by the event. - Parameter resumptionOffset: Specifies the offset in time at which playback of the primary item should resume after interstitial playback has finished. Definite numeric values are supported. The value kCMTimeIndefinite can also be used, in order to specify that the effective resumption time offset should accord with the wallclock time elapsed during interstitial playback. - Parameter playoutLimit: Specifies the offset from the beginning of the interstitial at which interstitial playback should end, if the interstitial asset(s) are longer. Pass a positive numeric value, or kCMTimeInvalid to indicate no playout limit. - Parameter userDefinedAttributes: Storage for attributes defined by the client or the content vendor. Attribute names should begin with X- for uniformity with server insertion. - Returns: An instance of AVPlayerInterstitialEvent. Deprecated: Use interstitialEventWithPrimaryItem:date: instead

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemIdentifierTimeTemplateItemsRestrictionsResumptionOffsetPlayoutLimitUserDefinedAttributes ¶

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemIdentifierTimeTemplateItemsRestrictionsResumptionOffsetPlayoutLimitUserDefinedAttributes(primaryItem *AVPlayerItem, identifier *foundation.NSString, time_ coremedia.CMTime, templateItems *foundation.NSArray[*AVPlayerItem], restrictions AVPlayerInterstitialEventRestrictions, resumptionOffset coremedia.CMTime, playoutLimit coremedia.CMTime, userDefinedAttributes *foundation.NSDictionary[objc.ID, objc.ID]) *AVPlayerInterstitialEvent

Returns an instance of AVPlayerInterstitialEvent for use in scheduling interstitial playback. - Parameter primaryItem: An AVPlayerItem representing the primary content during the playback of which the interstitial event should occur. The primaryItem must have an AVAsset that provides an intrinsic mapping from its timeline to real-time dates. - Parameter identifier: An external identifier for the event. - Parameter time: The time within the duration of the primary item at which playback of the primary content should be temporarily suspended and the interstitial items played. - Parameter templateItems: An array of AVPlayerItems with configurations that will be reproduced for the playback of interstitial content. An NSInvalidArgumentException will be raised if any of the template items employs an AVAsset that lacks a URL, such as an AVComposition. - Parameter restrictions: Indicates restrictions on the use of end user playback controls that are imposed by the event. - Parameter resumptionOffset: Specifies the offset in time at which playback of the primary item should resume after interstitial playback has finished. Definite numeric values are supported. The value kCMTimeIndefinite can also be used, in order to specify that the effective resumption time offset should accord with the wallclock time elapsed during interstitial playback. - Parameter playoutLimit: Specifies the offset from the beginning of the interstitial at which interstitial playback should end, if the interstitial asset(s) are longer. Pass a positive numeric value, or kCMTimeInvalid to indicate no playout limit. - Parameter userDefinedAttributes: Storage for attributes defined by the client or the content vendor. Attribute names should begin with X- for uniformity with server insertion. - Returns: An instance of AVPlayerInterstitialEvent. Deprecated: Use interstitialEventWithPrimaryItem:time: instead

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemTime ¶

func AVPlayerInterstitialEventInterstitialEventWithPrimaryItemTime(primaryItem *AVPlayerItem, time_ coremedia.CMTime) *AVPlayerInterstitialEvent

Returns an instance of AVPlayerInterstitialEvent for use in scheduling interstitial playback. - Parameter primaryItem: An AVPlayerItem representing the primary content during the playback of which the interstitial event should occur. The primaryItem must have an AVAsset that provides an intrinsic mapping from its timeline to real-time dates. - Parameter time: The time within the duration of the primary item at which playback of the primary content should be temporarily suspended and the interstitial items played. - Returns: An instance of AVPlayerInterstitialEvent.

func (*AVPlayerInterstitialEvent) AlignsResumptionWithPrimarySegmentBoundary ¶

func (o *AVPlayerInterstitialEvent) AlignsResumptionWithPrimarySegmentBoundary() bool

Specifies that the resumption time of primary playback should be snapped to a segment boundary of the primary asset If true, the resumption time of primary playback following an interstitial will be adjusted to the nearest segment boundary when the primary player is playing an HTTP Live Streaming asset.

func (*AVPlayerInterstitialEvent) AlignsStartWithPrimarySegmentBoundary ¶

func (o *AVPlayerInterstitialEvent) AlignsStartWithPrimarySegmentBoundary() bool

Specifies that the start time of interstitial playback should be snapped to a segment boundary of the primary asset If true, the start time or date of the interstitial will be adjusted to the nearest segment boundary when the primary player is playing an HTTP Live Streaming asset.

func (*AVPlayerInterstitialEvent) AssetListResponse ¶

func (o *AVPlayerInterstitialEvent) AssetListResponse() *foundation.NSDictionary[objc.ID, objc.ID]

The asset list JSON response as a dictionary, or nil if no asset list response has been loaded for the event. If the AVPlayerInterstitialEvent's templateItems is empty and the assetListResponse is nil, then an asset list read is expected. If the AVPlayerInterstitialEvent's templateItems is not empty and the assetListResponse is nil, then an asset list read is not expected.

func (*AVPlayerInterstitialEvent) ContentMayVary ¶

func (o *AVPlayerInterstitialEvent) ContentMayVary() bool

Indicates this event's content is dynamic and server may respond with different interstitial assets for other particpants in coordinated playback. Indicates this event's content is dynamic and server may respond with different interstitial assets for other particpants in coordinated playback. If this value is set to NO and the primary asset is particpating in coordinated playback, this event will participate in coordinated playback as well. The default value is YES.

func (*AVPlayerInterstitialEvent) Cue ¶

The cue property is used to schedule event playback at a predefined position of primary playback.

func (*AVPlayerInterstitialEvent) Date ¶

The date within the date range of the primary item at which playback of the primary content should be temporarily suspended and the interstitial items played. Will have a value of nil if the event was initialized with a time instead of a date.

func (*AVPlayerInterstitialEvent) Identifier ¶

An external identifier for the event. If an event is set on an AVPlayerInterstitialEventController that already has an event with the same identifier, the old event will be replaced by the new one.

func (*AVPlayerInterstitialEvent) PlannedDuration ¶

func (o *AVPlayerInterstitialEvent) PlannedDuration() coremedia.CMTime

Indicates the event's planned duration. The default value is kCMTimeInvalid.

func (*AVPlayerInterstitialEvent) PlayoutLimit ¶

func (o *AVPlayerInterstitialEvent) PlayoutLimit() coremedia.CMTime

Specifies the offset in time at which playback of the interstitial event should end. Can be any positive numeric value, or invalid. The default value is kCMTimeInvalid, which means there is no limit.

func (*AVPlayerInterstitialEvent) PrimaryItem ¶

func (o *AVPlayerInterstitialEvent) PrimaryItem() *AVPlayerItem

An AVPlayerItem representing the primary content during the playback of which the interstitial event should occur. The primaryItem must have an AVAsset that provides an intrinsic mapping from its timeline to real-time dates.

func (*AVPlayerInterstitialEvent) Restrictions ¶

Indicates restrictions on the use of end user playback controls that are imposed by the event.

func (*AVPlayerInterstitialEvent) ResumptionOffset ¶

func (o *AVPlayerInterstitialEvent) ResumptionOffset() coremedia.CMTime

Specifies the offset in time at which playback of the primary item should resume after interstitial playback has finished. Definite numeric values are supported. The value kCMTimeIndefinite can also be used, in order to specify that the effective resumption time offset should accord with the wallclock time elapsed during interstitial playback; this value is typically suitable for live broadcasts. The default value is kCMTimeZero.

func (*AVPlayerInterstitialEvent) ScheduleIdentifier ¶

func (o *AVPlayerInterstitialEvent) ScheduleIdentifier() *foundation.NSString

The identifier of the daterange-schedule that produced this event. nil if the event was not a product of a daterange-schedule.

func (*AVPlayerInterstitialEvent) SetAlignsResumptionWithPrimarySegmentBoundary ¶

func (o *AVPlayerInterstitialEvent) SetAlignsResumptionWithPrimarySegmentBoundary(alignsResumptionWithPrimarySegmentBoundary bool)

func (*AVPlayerInterstitialEvent) SetAlignsStartWithPrimarySegmentBoundary ¶

func (o *AVPlayerInterstitialEvent) SetAlignsStartWithPrimarySegmentBoundary(alignsStartWithPrimarySegmentBoundary bool)

func (*AVPlayerInterstitialEvent) SetContentMayVary ¶

func (o *AVPlayerInterstitialEvent) SetContentMayVary(contentMayVary bool)

func (*AVPlayerInterstitialEvent) SetCue ¶

func (*AVPlayerInterstitialEvent) SetDate ¶

func (o *AVPlayerInterstitialEvent) SetDate(date *foundation.NSDate)

func (*AVPlayerInterstitialEvent) SetIdentifier ¶

func (o *AVPlayerInterstitialEvent) SetIdentifier(identifier *foundation.NSString)

func (*AVPlayerInterstitialEvent) SetPlannedDuration ¶

func (o *AVPlayerInterstitialEvent) SetPlannedDuration(plannedDuration coremedia.CMTime)

func (*AVPlayerInterstitialEvent) SetPlayoutLimit ¶

func (o *AVPlayerInterstitialEvent) SetPlayoutLimit(playoutLimit coremedia.CMTime)

func (*AVPlayerInterstitialEvent) SetPrimaryItem ¶

func (o *AVPlayerInterstitialEvent) SetPrimaryItem(primaryItem *AVPlayerItem)

func (*AVPlayerInterstitialEvent) SetRestrictions ¶

func (o *AVPlayerInterstitialEvent) SetRestrictions(restrictions AVPlayerInterstitialEventRestrictions)

func (*AVPlayerInterstitialEvent) SetResumptionOffset ¶

func (o *AVPlayerInterstitialEvent) SetResumptionOffset(resumptionOffset coremedia.CMTime)

func (*AVPlayerInterstitialEvent) SetSkipControlLocalizedLabelBundleKey ¶

func (o *AVPlayerInterstitialEvent) SetSkipControlLocalizedLabelBundleKey(skipControlLocalizedLabelBundleKey *foundation.NSString)

func (*AVPlayerInterstitialEvent) SetSkipControlTimeRange ¶

func (o *AVPlayerInterstitialEvent) SetSkipControlTimeRange(skipControlTimeRange coremedia.CMTimeRange)

func (*AVPlayerInterstitialEvent) SetSupplementsPrimaryContent ¶

func (o *AVPlayerInterstitialEvent) SetSupplementsPrimaryContent(supplementsPrimaryContent bool)

func (*AVPlayerInterstitialEvent) SetTemplateItems ¶

func (o *AVPlayerInterstitialEvent) SetTemplateItems(templateItems *foundation.NSArray[*AVPlayerItem])

func (*AVPlayerInterstitialEvent) SetTime ¶

func (o *AVPlayerInterstitialEvent) SetTime(time_ coremedia.CMTime)

func (*AVPlayerInterstitialEvent) SetTimelineOccupancy ¶

func (o *AVPlayerInterstitialEvent) SetTimelineOccupancy(timelineOccupancy AVPlayerInterstitialEventTimelineOccupancy)

func (*AVPlayerInterstitialEvent) SetUserDefinedAttributes ¶

func (o *AVPlayerInterstitialEvent) SetUserDefinedAttributes(userDefinedAttributes *foundation.NSDictionary[objc.ID, objc.ID])

func (*AVPlayerInterstitialEvent) SetWillPlayOnce ¶

func (o *AVPlayerInterstitialEvent) SetWillPlayOnce(willPlayOnce bool)

func (*AVPlayerInterstitialEvent) SkipControlLocalizedLabelBundleKey ¶

func (o *AVPlayerInterstitialEvent) SkipControlLocalizedLabelBundleKey() *foundation.NSString

The key defined in the AVPlayerInterstitialEventController's localizedStringsBundle that points to the localized label for the skip button. If the value of the property is nil, the skip button may contain a generic label depending on the implementation of the UI that's in use. To ensure the best available user experience in various playback configurations, including external playback, set a value for this property that provides localized translations of skip control labels.

func (*AVPlayerInterstitialEvent) SkipControlTimeRange ¶

func (o *AVPlayerInterstitialEvent) SkipControlTimeRange() coremedia.CMTimeRange

The time range within the duration of the interstitial event for which a skip button should be displayed. The start of the time range should indicate at which point the skip button should appear. The duration of the time range should indicate how long the skip button should be available. If this value is set to kCMTimePositiveInfinity, then the skip button will be available for the remainder of the interstitial's duration after appearing. If either the start or duration of the time range is kCMTimeInvalid, then the interstitial will NOT be eligible to be skipped.

func (*AVPlayerInterstitialEvent) SupplementsPrimaryContent ¶

func (o *AVPlayerInterstitialEvent) SupplementsPrimaryContent() bool

Indicates this event will supplement the primary content and should be presented unified with the primary item. The default value is NO.

func (*AVPlayerInterstitialEvent) TemplateItems ¶

An array of AVPlayerItems with configurations that will be reproduced for the playback of interstitial content. If you want the instances of AVURLAsset used during interstitial playback to be identical to the ones you specify for templateItems in AVPlayerInterstitialEvents that you set on an AVPlayerInterstitialEventController, rather than equivalent AVURLAssets with the same URL, you must create them with a value for the key AVURLAssetPrimarySessionIdentifierKey that's equal to the httpSessionIdentifier of the primary AVPlayerItem's asset. See AVAsset.h. This is especially useful if you require the use of a custom AVAssetResourceLoader delegate for interstitial assets. An NSInvalidArgumentException will be raised if any of the template items employs an AVAsset that lacks a URL, such as an AVComposition.

func (*AVPlayerInterstitialEvent) Time ¶

The time within the duration of the primary item at which playback of the primary content should be temporarily suspended and the interstitial items played. Will have a value equal to kCMTimeInvalid if the event was initialized with a date instead of a time.

func (*AVPlayerInterstitialEvent) TimelineOccupancy ¶

Indicates this event's occupancy on AVPlayerItemIntegratedTimeline. The default value is AVPlayerInterstitialEventTimelineSinglePointOccupancy.

func (*AVPlayerInterstitialEvent) UserDefinedAttributes ¶

func (o *AVPlayerInterstitialEvent) UserDefinedAttributes() *foundation.NSDictionary[objc.ID, objc.ID]

Attributes of the event defined by the content vendor or the client. Dictionary keys are attribute names. Dictionary values are attribute values.

func (*AVPlayerInterstitialEvent) WillPlayOnce ¶

func (o *AVPlayerInterstitialEvent) WillPlayOnce() bool

Specifies that the interstitial should be scheduled for playback once only, and suppressed for subsequent replay. The "once" provision takes effect at the start of interstitial playback. The interstitial will not be scheduled again even if the first playback is canceled before completion.

type AVPlayerInterstitialEventAssetListResponseStatus ¶

type AVPlayerInterstitialEventAssetListResponseStatus int64
const (
	// Indicates that the asset list response is now available and non-nil, meaning the asset list read was successful.
	AVPlayerInterstitialEventAssetListResponseStatusAvailable AVPlayerInterstitialEventAssetListResponseStatus = 0
	// Indicates that asset list response has been cleared and reverted to its original state of nil.
	AVPlayerInterstitialEventAssetListResponseStatusCleared AVPlayerInterstitialEventAssetListResponseStatus = 1
	// Indicates that the asset list response is unavailable, meaning the asset list read failed.
	AVPlayerInterstitialEventAssetListResponseStatusUnavailable AVPlayerInterstitialEventAssetListResponseStatus = 2
)

func (AVPlayerInterstitialEventAssetListResponseStatus) String ¶

type AVPlayerInterstitialEventController ¶

type AVPlayerInterstitialEventController struct {
	AVPlayerInterstitialEventMonitor
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayerinterstitialeventcontroller

func AVPlayerInterstitialEventControllerFromID ¶

func AVPlayerInterstitialEventControllerFromID(id objc.ID) *AVPlayerInterstitialEventController

func AVPlayerInterstitialEventControllerInterstitialEventControllerWithPrimaryPlayer ¶

func AVPlayerInterstitialEventControllerInterstitialEventControllerWithPrimaryPlayer(primaryPlayer *AVPlayer) *AVPlayerInterstitialEventController

Returns an instance of AVPlayerInterstitialEvent for use in observing and scheduling interstitial playback. This method throws an exception if the primary player is an interstitial player. - Parameter primaryPlayer: The AVPlayer that will play the primaryItems of the receiver's interstitial events. - Returns: An instance of AVPlayerInterstitialEventController.

func (*AVPlayerInterstitialEventController) CancelCurrentEventWithResumptionOffset ¶

func (o *AVPlayerInterstitialEventController) CancelCurrentEventWithResumptionOffset(resumptionOffset coremedia.CMTime)

Causes the playback of any and all interstitial content currently in progress to be abandoned and the playback of primary content to be resumed. If invoked during the handling of coinciding interstitial events, they will all be canceled. When you cancel interstitial events via the use of this method, the value of resumptionOffset that you pass overrides the events' resumptionOffset. Has no effect while currentEvent is nil. - Parameter resumptionOffset: Specifies the offset in time at which playback of the primary player's current item should resume after interstitial playback has finished. To specify that the effective resumption time offset should match with the wallclock time elapsed during interstitial playback, pass a value of kCMTimeIndefinite. To specify that the effective resumption time offset should match with the projected playback time, pass a value of kCMTimeInvalid.

func (*AVPlayerInterstitialEventController) InitWithPrimaryPlayer ¶

func (o *AVPlayerInterstitialEventController) InitWithPrimaryPlayer(primaryPlayer *AVPlayer) *AVPlayerInterstitialEventController

This method throws an exception if the primary player is an interstitial player.

func (*AVPlayerInterstitialEventController) LocalizedStringsBundle ¶

func (o *AVPlayerInterstitialEventController) LocalizedStringsBundle() *foundation.NSBundle

The bundle that contains the localized strings to be used by the AVPlayerInterstitialEventController. If the value of the property is nil, any UI elements triggered by the AVPlayerInterstitialEventController, such as the skip button, may contain a generic label based on the implementation of the UI that's in use. To ensure the best available user experience in various playback configurations, including external playback, set a value for this property that provides localized translations of skip control labels.

func (*AVPlayerInterstitialEventController) LocalizedStringsTableName ¶

func (o *AVPlayerInterstitialEventController) LocalizedStringsTableName() *foundation.NSString

The name of the table in the bundle that contains the localized strings to be used by the AVPlayerInterstitialEventController. If the value of the property is nil, it will default to "Localizable"

func (*AVPlayerInterstitialEventController) SetEvents ¶

func (*AVPlayerInterstitialEventController) SetLocalizedStringsBundle ¶

func (o *AVPlayerInterstitialEventController) SetLocalizedStringsBundle(localizedStringsBundle *foundation.NSBundle)

func (*AVPlayerInterstitialEventController) SetLocalizedStringsTableName ¶

func (o *AVPlayerInterstitialEventController) SetLocalizedStringsTableName(localizedStringsTableName *foundation.NSString)

func (*AVPlayerInterstitialEventController) SkipCurrentEvent ¶

func (o *AVPlayerInterstitialEventController) SkipCurrentEvent()

Causes the playback of the currently playing interstital event to be abandoned. Note that coinciding events will NOT be skipped. This results in AVPlayerInterstitialEventMonitorCurrentEventSkippedNotification being posted. Has no effect while the currentEvent is nil.

type AVPlayerInterstitialEventMonitor ¶

type AVPlayerInterstitialEventMonitor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayerinterstitialeventmonitor

func AVPlayerInterstitialEventMonitorFromID ¶

func AVPlayerInterstitialEventMonitorFromID(id objc.ID) *AVPlayerInterstitialEventMonitor

func AVPlayerInterstitialEventMonitorInterstitialEventMonitorWithPrimaryPlayer ¶

func AVPlayerInterstitialEventMonitorInterstitialEventMonitorWithPrimaryPlayer(primaryPlayer *AVPlayer) *AVPlayerInterstitialEventMonitor

Returns an instance of AVPlayerInterstitialEvent for use in observing and scheduling interstitial playback. - Parameter primaryPlayer: The AVPlayer that will play the primaryItems of the receiver's interstitial events. - Returns: An instance of AVPlayerInterstitialEventMonitor.

func (*AVPlayerInterstitialEventMonitor) CurrentEvent ¶

The current interstitial event. Has a value of nil during playback of primary content by the primary player.

func (*AVPlayerInterstitialEventMonitor) CurrentEventSkipControlLabel ¶

func (o *AVPlayerInterstitialEventMonitor) CurrentEventSkipControlLabel() *foundation.NSString

The skip control label for the currentEvent. If a localizedStringsBundle has been set on the AVPlayerInterstitialEventController, and a skipControlLocalizedLabelBundleKey is set on the currentEvent, then this value will be the localized string that was matched to the event's skipControlLocalizedLabelBundleKey for the corresponding system language in the supplied Bundle, if any. If currentEvent is nil, then the value will be nil.

func (*AVPlayerInterstitialEventMonitor) CurrentEventSkippableState ¶

The skippable event state for the currentEvent. If currentEvent is nil, then the value will be AVPlayerInterstitialEventSkippableEventStateNotSkippable.

func (*AVPlayerInterstitialEventMonitor) Events ¶

Provides the current schedule of interstitial events, specified either intrinsically within the content of primary items, such as via use of directives carried by HLS media playlists, or via use of an AVPlayerInterstitialEventController. When interstitial events follow a schedule specified intrinsically within the content of primary items, the value of this property will typically change whenever the currentItem of the primaryPlayer changes. For HLS content that specifies interstitials via the use of DATERANGE tags, the value of this property may also change whenever the set of DATERANGE tags in the currentItem's media playlist changes. When interstitial events follow a schedule specified via use of an AVPlayerInterstitialEventController, the value of this property changes only when a new schedule is set on the AVPlayerInterstitialEventController. The events returned in this array are immutable. Attempting to mutate them will trigger an exception. To alter an event, make a copy and mutate the copy.

func (*AVPlayerInterstitialEventMonitor) InitWithPrimaryPlayer ¶

func (o *AVPlayerInterstitialEventMonitor) InitWithPrimaryPlayer(primaryPlayer *AVPlayer) *AVPlayerInterstitialEventMonitor

func (*AVPlayerInterstitialEventMonitor) InterstitialPlayer ¶

func (o *AVPlayerInterstitialEventMonitor) InterstitialPlayer() *AVQueuePlayer

The AVQueuePlayer that will play interstitial items during suspension of playback of primary items.

func (*AVPlayerInterstitialEventMonitor) PrimaryPlayer ¶

func (o *AVPlayerInterstitialEventMonitor) PrimaryPlayer() *AVPlayer

The AVPlayer that will play the primaryItems of the receiver's interstitial events.

type AVPlayerInterstitialEventRestrictions ¶

type AVPlayerInterstitialEventRestrictions uint64
const (
	// Indicates that the user may freely employ playback controls, as available, both within the primary content and in the interstitial content specified for the event.
	AVPlayerInterstitialEventRestrictionNone AVPlayerInterstitialEventRestrictions = 0
	// Indicates that seeking within the primary content from a date prior to the date of the event to a date subsequent to the date of the event is not permitted.
	AVPlayerInterstitialEventRestrictionConstrainsSeekingForwardInPrimaryContent AVPlayerInterstitialEventRestrictions = 1
	// Indicates that advancing the currentTime within an interstitial item, either by seeking ahead or by setting the playback rate to a value greater than the item's asset's preferredRate, is not permitted.
	AVPlayerInterstitialEventRestrictionRequiresPlaybackAtPreferredRateForAdvancement AVPlayerInterstitialEventRestrictions = 4
	AVPlayerInterstitialEventRestrictionDefaultPolicy                                 AVPlayerInterstitialEventRestrictions = 0
)

func (AVPlayerInterstitialEventRestrictions) String ¶

type AVPlayerInterstitialEventSkippableEventState ¶

type AVPlayerInterstitialEventSkippableEventState int64
const (
	// Indicates that the interstitial event is not skippable.
	AVPlayerInterstitialEventSkippableEventStateNotSkippable AVPlayerInterstitialEventSkippableEventState = 0
	// Indicates that the interstitial event will eventually become eligible to be skipped.
	AVPlayerInterstitialEventSkippableEventStateNotYetEligible AVPlayerInterstitialEventSkippableEventState = 1
	// Indicates that the interstitial event is currently skippable.
	AVPlayerInterstitialEventSkippableEventStateEligible AVPlayerInterstitialEventSkippableEventState = 2
	// Indicates that the interstitial event is no longer eligible to be skipped.
	AVPlayerInterstitialEventSkippableEventStateNoLongerEligible AVPlayerInterstitialEventSkippableEventState = 3
)

func (AVPlayerInterstitialEventSkippableEventState) String ¶

type AVPlayerInterstitialEventTimelineOccupancy ¶

type AVPlayerInterstitialEventTimelineOccupancy int64
const (
	// Indicates this interstitial event occupies a single point on AVPlayerItemIntegratedTimeline.
	AVPlayerInterstitialEventTimelineOccupancySinglePoint AVPlayerInterstitialEventTimelineOccupancy = 0
	// Indicates this interstitial event fills AVPlayerItemIntegratedTimeline with the duration of this event.
	AVPlayerInterstitialEventTimelineOccupancyFill AVPlayerInterstitialEventTimelineOccupancy = 1
)

func (AVPlayerInterstitialEventTimelineOccupancy) String ¶

type AVPlayerItem ¶

type AVPlayerItem struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritem

func AVPlayerItemFromID ¶

func AVPlayerItemFromID(id objc.ID) *AVPlayerItem

func AVPlayerItemPlayerItemWithAsset ¶

func AVPlayerItemPlayerItemWithAsset(asset *AVAsset) *AVPlayerItem

Returns an instance of AVPlayerItem for playing an AVAsset. Equivalent to +playerItemWithAsset:automaticallyLoadedAssetKeys:, passing @[ @"duration" ] as the value of automaticallyLoadedAssetKeys. This method, along with the companion `asset` property, is MainActor-isolated for Swift clients because AVAsset is not Sendable. If you are using a Sendable subclass of AVAsset, such as AVURLAsset, an overload of this initializer will be chosen automatically to allow you to initialize an AVPlayerItem while not running on the main actor. - Parameter asset: - Returns: An instance of AVPlayerItem.

func AVPlayerItemPlayerItemWithAssetAutomaticallyLoadedAssetKeys ¶

func AVPlayerItemPlayerItemWithAssetAutomaticallyLoadedAssetKeys(asset *AVAsset, automaticallyLoadedAssetKeys *foundation.NSArray[*foundation.NSString]) *AVPlayerItem

Returns an instance of AVPlayerItem for playing an AVAsset. The value of each key in automaticallyLoadedAssetKeys will be automatically be loaded by the underlying AVAsset before the receiver achieves the status AVPlayerItemStatusReadyToPlay; i.e. when the item is ready to play, the value of -[[AVPlayerItem asset] statusOfValueForKey:error:] will be one of the terminal status values greater than AVKeyValueStatusLoading. This method, along with the companion `asset` property, is MainActor-isolated for Swift clients because AVAsset is not Sendable. If you are using a Sendable subclass of AVAsset, such as AVURLAsset, you can use `init(asset:automaticallyLoadedAssetKeys:)` to initialize an AVPlayerItem while not running on the main actor. - Parameter asset: - Parameter automaticallyLoadedAssetKeys: An NSArray of NSStrings, each representing a property key defined by AVAsset. See AVAsset.h for property keys, e.g. duration. - Returns: An instance of AVPlayerItem.

func AVPlayerItemPlayerItemWithURL ¶

func AVPlayerItemPlayerItemWithURL(uRL *foundation.NSURL) *AVPlayerItem

Returns an instance of AVPlayerItem for playing a resource at the specified location. Equivalent to +playerItemWithAsset:, passing [AVAsset assetWithURL:URL] as the value of asset. - Parameter URL: - Returns: An instance of AVPlayerItem.

func (*AVPlayerItem) AccessLog ¶

func (o *AVPlayerItem) AccessLog() *AVPlayerItemAccessLog

Returns an object that represents a snapshot of the network access log. Can be nil. An AVPlayerItemAccessLog provides methods to retrieve the network access log in a format suitable for serialization. If nil is returned then there is no logging information currently available for this AVPlayerItem. An AVPlayerItemNewAccessLogEntryNotification will be posted when new logging information becomes available. However, accessLog might already return a non-nil value even before the first notification is posted. In certain situations, this method may temporarily block the calling thread during the ongoing log collection process. It is strongly recommended that the caller take appropriate measures to prevent blocking essential services such as the user interface, for example, by avoiding calling this method in the main thread. - Returns: An autoreleased AVPlayerItemAccessLog instance.

func (*AVPlayerItem) AddMediaDataCollector ¶

func (o *AVPlayerItem) AddMediaDataCollector(collector *AVPlayerItemMediaDataCollector)

Adds the specified instance of AVPlayerItemMediaDataCollector to the receiver's collection of mediaDataCollectors. This method may incur additional I/O to collect the requested media data asynchronously. - Parameter collector: An instance of AVPlayerItemMediaDataCollector

func (*AVPlayerItem) AddOutput ¶

func (o *AVPlayerItem) AddOutput(output *AVPlayerItemOutput)

Adds the specified instance of AVPlayerItemOutput to the receiver's collection of outputs. The class of AVPlayerItemOutput provided dictates the data structure that decoded samples are vended in. When an AVPlayerItemOutput is associated with an AVPlayerItem, samples are provided for a media type in accordance with the rules for mixing, composition, or exclusion that the AVPlayer honors among multiple enabled tracks of that media type for its own rendering purposes. For example, video media will be composed according to the instructions provided via AVPlayerItem.videoComposition, if present. Audio media will be mixed according to the parameters provided via AVPlayerItem.audioMix, if present. - Parameter output: An instance of AVPlayerItemOutput

func (*AVPlayerItem) AllowedAudioSpatializationFormats ¶

func (o *AVPlayerItem) AllowedAudioSpatializationFormats() AVAudioSpatializationFormats

Indicates the source audio channel layouts allowed by the receiver for spatialization. Spatialization uses psychoacoustic methods to create a more immersive audio rendering when the content is played on specialized headphones and speaker arrangements. When an AVPlayerItem's allowedAudioSpatializationFormats property is set to AVAudioSpatializationFormatMonoAndStereo the AVPlayer will attempt to spatialize content tagged with a stereo channel layout, two-channel content with no layout specified as well as mono. It is considered incorrect to render a binaural recording with spatialization. A binaural recording is captured using two carefully placed microphones at each ear where the intent, when played on headphones, is to reproduce a naturally occurring spatial effect. Content tagged with a binaural channel layout will ignore this property value. When an AVPlayerItem's allowedAudioSpatializationFormats property is set to AVAudioSpatializationFormatMultichannel the AVPlayer will attempt to spatialize any decodable multichannel layout. Setting this property to AVAudioSpatializationFormatMonoStereoAndMultichannel indicates that the sender allows the AVPlayer to spatialize any decodable mono, stereo or multichannel layout. This property is not observable. The default value for this property with video content is AVAudioSpatializationFormatMonoStereoAndMultichannel. Otherwise, audio only content default value is AVAudioSpatializationFormatMultichannel.

func (*AVPlayerItem) AppliesPerFrameHDRDisplayMetadata ¶

func (o *AVPlayerItem) AppliesPerFrameHDRDisplayMetadata() bool

Controls whether or not to apply the per frame HDR display metadata of the source during playback.

func (*AVPlayerItem) Asset ¶

func (o *AVPlayerItem) Asset() *AVAsset

Accessor for underlying AVAsset.

func (*AVPlayerItem) AudioMix ¶

func (o *AVPlayerItem) AudioMix() *AVAudioMix

Indicates the audio mix parameters to be applied during playback The inputParameters of the AVAudioMix must have trackIDs that correspond to a track of the receiver's asset. Otherwise they will be ignored. (See AVAudioMix.h for the declaration of AVAudioMixInputParameters and AVPlayerItem's asset property.)

func (*AVPlayerItem) AudioTimePitchAlgorithm ¶

func (o *AVPlayerItem) AudioTimePitchAlgorithm() *foundation.NSString

Indicates the processing algorithm used to manage audio pitch at varying rates and for scaled audio edits. Constants for various time pitch algorithms, e.g. AVAudioTimePitchSpectral, are defined in AVAudioProcessingSettings.h. The default value for applications linked on or after iOS 15.0 or macOS 12.0 is AVAudioTimePitchAlgorithmTimeDomain. For iOS versions prior to 15.0 the default value is AVAudioTimePitchAlgorithmLowQualityZeroLatency. For macOS versions prior to 12.0 the default value is AVAudioTimePitchAlgorithmSpectral.

func (*AVPlayerItem) AutomaticallyHandlesInterstitialEvents ¶

func (o *AVPlayerItem) AutomaticallyHandlesInterstitialEvents() bool

Allows interstitials to be played according to a schedule that's specified by server-side directives. The default value is YES. A value of NO prevents automatic scheduling of future server-side interstitial events. Events specified by an AVPlayerInterstitialEventController override server-side events, regardless of the value of this property. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayerItem) AutomaticallyLoadedAssetKeys ¶

func (o *AVPlayerItem) AutomaticallyLoadedAssetKeys() *foundation.NSArray[*foundation.NSString]

An array of property keys defined on AVAsset. The value of each key in the array is automatically loaded while the receiver is being made ready to play. The value of each key in automaticallyLoadedAssetKeys will be automatically be loaded by the underlying AVAsset before the receiver achieves the status AVPlayerItemStatusReadyToPlay; i.e. when the item is ready to play, the value of -[[AVPlayerItem asset] statusOfValueForKey:error:] will be AVKeyValueStatusLoaded. If loading of any of the values fails, the status of the AVPlayerItem will change instead to AVPlayerItemStatusFailed..

func (*AVPlayerItem) AutomaticallyPreservesTimeOffsetFromLive ¶

func (o *AVPlayerItem) AutomaticallyPreservesTimeOffsetFromLive() bool

Indicates that after the player spends a period of time buffering media, it will skip forward if necessary to restore the playhead's distance from the live edge of the presentation to what it was when buffering began. If the value of this property is YES and the player must buffer media from the network in order to resume playback, the player will seek forward if necessary before resuming playback to restore the position that the playhead had when rebuffering began, relative to the end of the current AVPlayerItem's seekableTimeRange. This behavior applies to media buffering that occurs as a consequence of starting playback, seeking, and recovering from a playback stall. Note that if the network cannot deliver media quickly enough to maintain the playback rate, playback may stall interminably. This property value has no effect if the asset is not a live stream. The default value of this property is NO.

func (*AVPlayerItem) CanPlayFastForward ¶

func (o *AVPlayerItem) CanPlayFastForward() bool

For releases of macOS prior to 10.9 and releases of iOS prior to 7.0, indicates whether the item can be played at rates greater than 1.0. Starting with macOS 10.9 and iOS 7.0, all AVPlayerItems with status AVPlayerItemReadyToPlay can be played at rates between 1.0 and 2.0, inclusive, even if canPlayFastForward is NO; for those releases canPlayFastForward indicates whether the item can be played at rates greater than 2.0.

func (*AVPlayerItem) CanPlayFastReverse ¶

func (o *AVPlayerItem) CanPlayFastReverse() bool

Indicates whether the item can be played at rates less than -1.0

func (*AVPlayerItem) CanPlayReverse ¶

func (o *AVPlayerItem) CanPlayReverse() bool

Indicates whether the item can be played at rate -1.0

func (*AVPlayerItem) CanPlaySlowForward ¶

func (o *AVPlayerItem) CanPlaySlowForward() bool

Indicates whether the item can be played at rates between 0.0 and 1.0

func (*AVPlayerItem) CanPlaySlowReverse ¶

func (o *AVPlayerItem) CanPlaySlowReverse() bool

Indicates whether the item can be played at rates less between 0.0 and -1.0

func (*AVPlayerItem) CanStepBackward ¶

func (o *AVPlayerItem) CanStepBackward() bool

Indicates whether the item supports stepping backward; see -stepByCount:. Once the item has become ready to play, the value of canStepBackward does not change even when boundary conditions are reached, such as when the item's currentTime is equal to kCMTimeZero.

func (*AVPlayerItem) CanStepForward ¶

func (o *AVPlayerItem) CanStepForward() bool

Indicates whether the item supports stepping forward; see -stepByCount:. Once the item has become ready to play, the value of canStepForward does not change even when boundary conditions are reached, such as when the item's currentTime is its end time.

func (*AVPlayerItem) CanUseNetworkResourcesForLiveStreamingWhilePaused ¶

func (o *AVPlayerItem) CanUseNetworkResourcesForLiveStreamingWhilePaused() bool

Indicates whether the player item can use network resources to keep playback state up to date while paused For live streaming content, the player item may need to use extra networking and power resources to keep playback state up to date when paused. For example, when this property is set to YES, the seekableTimeRanges property will be periodically updated to reflect the current state of the live stream. For clients linked on or after macOS 10.11 or iOS 9.0, the default value is NO. To minimize power usage, avoid setting this property to YES when you do not need playback state to stay up to date while paused.

func (*AVPlayerItem) CancelContentAuthorizationRequest ¶

func (o *AVPlayerItem) CancelContentAuthorizationRequest()

@method cancelContentAuthorizationRequest @abstract Causes the currently outstanding content authorization request to be cancelled. @discussion Calling this method while a content authorization request is pending will cause that request to be cancelled and its completion handler to be invoked with a status of AVContentAuthorizationCancelled. This call does not block.

func (*AVPlayerItem) CancelPendingSeeks ¶

func (o *AVPlayerItem) CancelPendingSeeks()

Cancel any pending seek requests and invoke the corresponding completion handlers if present. Use this method to cancel and release the completion handlers of pending seeks. The finished parameter of the completion handlers will be set to NO.

func (*AVPlayerItem) ConfiguredTimeOffsetFromLive ¶

func (o *AVPlayerItem) ConfiguredTimeOffsetFromLive() coremedia.CMTime

Indicates how close to the latest content in a live stream playback will begin after a live start or a seek to kCMTimePositiveInfinity. For non-live assets this value is kCMTimeInvalid.

func (*AVPlayerItem) ContentAuthorizationRequestStatus ¶

func (o *AVPlayerItem) ContentAuthorizationRequestStatus() AVContentAuthorizationStatus

@property contentAuthorizationRequestStatus @abstract Indicates the status of the most recent call to requestContentAuthorizationAsynchronouslyWithTimeoutInterval:CompletionHandler: @discussion This property reports the authorization status as determined by the most recent call to requestContentAuthorizationAsynchronouslyWithTimeoutInterval:CompletionHandler:. The value will be AVContentAuthorizationUnknown before the first call and between the time a request call is made and just prior to the completion handler being executed (i.e. it is safe to query this property from the completion handler). This value is NOT key-value observable.

func (*AVPlayerItem) CurrentDate ¶

func (o *AVPlayerItem) CurrentDate() *foundation.NSDate

If currentTime is mapped to a particular (real-time) date, return that date. - Returns: Returns the date of current playback, or nil if playback is not mapped to any date.

func (*AVPlayerItem) CurrentMediaSelection ¶

func (o *AVPlayerItem) CurrentMediaSelection() *AVMediaSelection

func (*AVPlayerItem) CurrentTime ¶

func (o *AVPlayerItem) CurrentTime() coremedia.CMTime

Returns the current time of the item. Returns the current time of the item. Not key-value observable; use -[AVPlayer addPeriodicTimeObserverForInterval:queue:usingBlock:] instead. - Returns: A CMTime

func (*AVPlayerItem) CustomVideoCompositor ¶

func (o *AVPlayerItem) CustomVideoCompositor() AVVideoCompositing

Indicates the custom video compositor instance. This property is nil if there is no video compositor, or if the internal video compositor is in use. This reference can be used to provide extra context to the custom video compositor instance if required. The value of this property can change as a result of setting the `videoComposition` property. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayerItem) Duration ¶

func (o *AVPlayerItem) Duration() coremedia.CMTime

Indicates the duration of the item, not considering either its forwardPlaybackEndTime or reversePlaybackEndTime. This property is observable. The duration of an item can change dynamically during playback. Unless you omit @"duration" from the array of asset keys you pass to +playerItemWithAsset:automaticallyLoadedAssetKeys: or -initWithAsset:automaticallyLoadedAssetKeys:, the value of this property will accord with the properties of the underlying AVAsset and the current state of playback once the receiver becomes ready to play. Before the underlying duration has been loaded, the value of this property is kCMTimeIndefinite. Use key-value observation to obtain a valid duration as soon as it becomes available. (Note that the value of duration may remain kCMTimeIndefinite, e.g. for live streams.)

func (*AVPlayerItem) EffectiveMediaPresentationSettingsForMediaSelectionGroup ¶

func (o *AVPlayerItem) EffectiveMediaPresentationSettingsForMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *foundation.NSDictionary[*AVMediaPresentationSelector, objc.ID]

Indicates the media presentation settings with media characteristics that are possessed by the currently selected AVMediaSelectionOption in the specified AVMediaSelectionGroup. Effective media presentation settings can differ from the currently effective media presentation settings if no AVMediaSelectionOption of the specified AVMediaSelectionGroup with the currently selected media presentation language possesses all of the characteristics associated with the currently selected settings. A value of NSNull for an AVMediaPresentationSelector can occur if either the content is inappropriately authored for the use of the AVCustomMediaSelectionScheme or if the currently selected AVMediaSelectionOption has been selected by means other than through the use of AVMediaPresentationSettings. - Parameter mediaSelectionGroup: An AVMediaSelectionGroup obtained from the receiver's asset for which the currently effective media presentation settings are desired. - Returns: A dictionary with AVMediaPresentationSelectors as keys and AVMediaPresentationSettings as values, unless the AVMediaSelectionOption currently selected in the group possesses none of the characteristics associated with the selector's settings. In that case the dictionary value will be NSNull.

func (*AVPlayerItem) Error ¶

func (o *AVPlayerItem) Error() unsafe.Pointer

If the receiver's status is AVPlayerItemStatusFailed, this describes the error that caused the failure. The value of this property is an NSError that describes what caused the receiver to no longer be able to be played. If the receiver's status is not AVPlayerItemStatusFailed, the value of this property is nil.

func (*AVPlayerItem) ErrorLog ¶

func (o *AVPlayerItem) ErrorLog() *AVPlayerItemErrorLog

Returns an object that represents a snapshot of the error log. Can be nil. An AVPlayerItemErrorLog provides methods to retrieve the error log in a format suitable for serialization. If nil is returned then there is no logging information currently available for this AVPlayerItem. In certain situations, this method may temporarily block the calling thread during the ongoing log collection process. It is strongly recommended that the caller take appropriate measures to prevent blocking essential services such as the user interface, for example, by avoiding calling this method in the main thread. - Returns: An autoreleased AVPlayerItemErrorLog instance.

func (*AVPlayerItem) ForwardPlaybackEndTime ¶

func (o *AVPlayerItem) ForwardPlaybackEndTime() coremedia.CMTime

The end time for forward playback. Specifies the time at which playback should end when the playback rate is positive (see AVPlayer's rate property). The default value is kCMTimeInvalid, which indicates that no end time for forward playback is specified. In this case, the effective end time for forward playback is the receiver's duration. When the end time is reached, the receiver will post AVPlayerItemDidPlayToEndTimeNotification and the AVPlayer will take the action indicated by the value of its actionAtItemEnd property (see AVPlayerActionAtItemEnd in AVPlayer.h). The value of this property has no effect on playback when the rate is negative.

func (*AVPlayerItem) InitWithAsset ¶

func (o *AVPlayerItem) InitWithAsset(asset *AVAsset) *AVPlayerItem

Initializes an AVPlayerItem with an AVAsset. Equivalent to -initWithAsset:automaticallyLoadedAssetKeys:, passing @[ @"duration" ] as the value of automaticallyLoadedAssetKeys. This method, along with the companion `asset` property, is MainActor-isolated for Swift clients because AVAsset is not Sendable. If you are using a Sendable subclass of AVAsset, such as AVURLAsset, an overload of this initializer will be chosen automatically to allow you to initialize an AVPlayerItem while not running on the main actor. - Parameter asset: - Returns: An instance of AVPlayerItem

func (*AVPlayerItem) InitWithAssetAutomaticallyLoadedAssetKeys ¶

func (o *AVPlayerItem) InitWithAssetAutomaticallyLoadedAssetKeys(asset *AVAsset, automaticallyLoadedAssetKeys *foundation.NSArray[*foundation.NSString]) *AVPlayerItem

Initializes an AVPlayerItem with an AVAsset. The value of each key in automaticallyLoadedAssetKeys will be automatically be loaded by the underlying AVAsset before the receiver achieves the status AVPlayerItemStatusReadyToPlay; i.e. when the item is ready to play, the value of -[[AVPlayerItem asset] statusOfValueForKey:error:] will be one of the terminal status values greater than AVKeyValueStatusLoading. This method, along with the companion `asset` property, is MainActor-isolated for Swift clients because AVAsset is not Sendable. If you are using a Sendable subclass of AVAsset, such as AVURLAsset, you can use `init(asset:automaticallyLoadedAssetKeys:)` to initialize an AVPlayerItem while not running on the main actor. - Parameter asset: An instance of AVAsset. - Parameter automaticallyLoadedAssetKeys: An NSArray of NSStrings, each representing a property key defined by AVAsset. See AVAsset.h for property keys, e.g. duration. - Returns: An instance of AVPlayerItem

func (*AVPlayerItem) InitWithURL ¶

func (o *AVPlayerItem) InitWithURL(uRL *foundation.NSURL) *AVPlayerItem

Initializes an AVPlayerItem with an NSURL. Equivalent to -initWithAsset:, passing [AVAsset assetWithURL:URL] as the value of asset. - Parameter URL: - Returns: An instance of AVPlayerItem

func (*AVPlayerItem) IntegratedTimeline ¶

func (o *AVPlayerItem) IntegratedTimeline() *AVPlayerItemIntegratedTimeline

func (*AVPlayerItem) InterstitialEventIdentifier ¶

func (o *AVPlayerItem) InterstitialEventIdentifier() *foundation.NSString

The identifier of the AVPlayerInterstitialEvent that created this item, or nil if the item was not created from an interstitial event.

func (*AVPlayerItem) IsApplicationAuthorizedForPlayback ¶

func (o *AVPlayerItem) IsApplicationAuthorizedForPlayback() bool

@property applicationAuthorizedForPlayback @abstract Indicates whether the calling application can be used to play the content. @discussion This property reports whether or not the calling application is authorized to play the content associated with the receiver. Note that application authorization is independent of content authorization (see contentAuthorizedForPlayback) and that both must be granted in order for an application to be allowed to play protected content. Also, unlike content authorization, application authorization is not dependent on user credentials (i.e. if applicationAuthorizedForPlayback is NO, there are no means to obtain authorization). This value is NOT key-value observable.

func (*AVPlayerItem) IsAudioSpatializationAllowed ¶

func (o *AVPlayerItem) IsAudioSpatializationAllowed() bool

Indicates whether audio spatialization is allowed When audio spatialization is allowed for an AVPlayerItem, the AVPlayer may render multichannel audio if available even if the output device doesn't support multichannel audio on its own, via use of a synthetic channel layout. When audio spatialization is not allowed, the AVPlayer must render audio with a channel layout that best matches the capabilities of the output device. This property is not observable. Defaults to YES. Deprecated: Use allowedAudioSpatializationFormats instead

func (*AVPlayerItem) IsAuthorizationRequiredForPlayback ¶

func (o *AVPlayerItem) IsAuthorizationRequiredForPlayback() bool

@property authorizationRequiredForPlayback @abstract Indicates whether or not authorization is required to play the content. @discussion This property reports whether or not authorization is required for the receiver's content to be played. If it does not require authorization, then none of the other methods or properties in the AVPlayerItemProtectedContent category apply (though they will return sensible values where possible). This value is NOT key-value observable.

func (*AVPlayerItem) IsContentAuthorizedForPlayback ¶

func (o *AVPlayerItem) IsContentAuthorizedForPlayback() bool

@property contentAuthorizedForPlayback @abstract Indicates whether the content has been authorized by the user (e.g. by authorizing the content's associated account in iTunes). @discussion This property reports whether or not the user has provided the necessary credentials to the system in order for the content to be decrypted for playback. Note that content authorization is independent of application authorization (see applicationAuthorizedForPlayback) and that both must be granted in order for an application to be allowed to play protected content. This value is NOT key-value observable.

func (*AVPlayerItem) IsPlaybackBufferEmpty ¶

func (o *AVPlayerItem) IsPlaybackBufferEmpty() bool

func (*AVPlayerItem) IsPlaybackBufferFull ¶

func (o *AVPlayerItem) IsPlaybackBufferFull() bool

Indicates that the internal media buffer is full and that further I/O is suspended. This property reports that the data buffer used for playback has reach capacity. Despite the playback buffer reaching capacity there might not exist sufficient statistical data to support a playbackLikelyToKeepUp prediction of YES. See playbackLikelyToKeepUp above.

func (*AVPlayerItem) IsPlaybackLikelyToKeepUp ¶

func (o *AVPlayerItem) IsPlaybackLikelyToKeepUp() bool

Indicates whether the item will likely play through without stalling. This property communicates a prediction of playability. Factors considered in this prediction include I/O throughput and media decode performance. It is possible for playbackLikelyToKeepUp to indicate NO while the property playbackBufferFull indicates YES. In this event the playback buffer has reached capacity but there isn't the statistical data to support a prediction that playback is likely to keep up. It is left to the application programmer to decide to continue media playback or not. See playbackBufferFull below.

func (*AVPlayerItem) LoadedTimeRanges ¶

func (o *AVPlayerItem) LoadedTimeRanges() *foundation.NSArray[*foundation.NSValue]

This property provides a collection of time ranges for which the player has the media data readily available. The ranges provided might be discontinuous. Returns an NSArray of NSValues containing CMTimeRanges.

func (*AVPlayerItem) MediaDataCollectors ¶

func (o *AVPlayerItem) MediaDataCollectors() *foundation.NSArray[*AVPlayerItemMediaDataCollector]

func (*AVPlayerItem) Outputs ¶

func (*AVPlayerItem) PreferredCustomMediaSelectionSchemes ¶

func (o *AVPlayerItem) PreferredCustomMediaSelectionSchemes() *foundation.NSArray[*AVCustomMediaSelectionScheme]

Indicates the AVCustomMediaSelectionSchemes of AVMediaSelectionGroups of the receiver's asset with which an associated UI implementation should configure its interface for media selection. Recommended usage: if use of a custom media selection scheme is desired, set this property before either replacing an AVPlayer's current item with the receiver or adding the receiver to an AVQueuePlayer's play queue. This will satisfy requirements of UI implementations that commit to a configuration of UI elements as the receiver becomes ready to play.

func (*AVPlayerItem) PreferredForwardBufferDuration ¶

func (o *AVPlayerItem) PreferredForwardBufferDuration() float64

Indicates the media duration the caller prefers the player to buffer from the network ahead of the playhead to guard against playback disruption. The value is in seconds. If it is set to 0, the player will choose an appropriate level of buffering for most use cases. Note that setting this property to a low value will increase the chance that playback will stall and re-buffer, while setting it to a high value will increase demand on system resources. Note that the system may buffer less than the value of this property in order to manage resource consumption.

func (*AVPlayerItem) PreferredMaximumResolution ¶

func (o *AVPlayerItem) PreferredMaximumResolution() corefoundation.CGSize

Indicates a preferred upper limit on the resolution of the video to be downloaded (or otherwise transferred) and rendered by the player. The default value is CGSizeZero, which indicates that the client enforces no limit on video resolution. Other values indicate a preferred maximum video resolution. It only applies to HTTP Live Streaming asset.

func (*AVPlayerItem) PreferredMaximumResolutionForExpensiveNetworks ¶

func (o *AVPlayerItem) PreferredMaximumResolutionForExpensiveNetworks() corefoundation.CGSize

Indicates a preferred upper limit on the resolution of the video to be downloaded that applies only when the download occurs over expensive networks. The default value is CGSizeZero, which indicates that the client enforces no limit on video resolution. Other values indicate a preferred maximum video resolution. This limit applies only when streaming over an expensive network, such as when using a cellular data plan. (See -[NWPath isExpensive]) It only applies to HTTP Live Streaming asset. Note that preferredMaximumResolution still applies unconditionally. If preferredMaximumResolutionForExpensiveNetworks is less restrictive (higher resolution) than preferredMaximumResolution, preferredMaximumResolutionForExpensiveNetworks has no practical effect.

func (*AVPlayerItem) PreferredPeakBitRate ¶

func (o *AVPlayerItem) PreferredPeakBitRate() float64

Indicates the desired limit of network bandwidth consumption for this item. Set preferredPeakBitRate to non-zero to indicate that the player should attempt to limit item playback to that bit rate, expressed in bits per second. If network bandwidth consumption cannot be lowered to meet the preferredPeakBitRate, it will be reduced as much as possible while continuing to play the item.

func (*AVPlayerItem) PreferredPeakBitRateForExpensiveNetworks ¶

func (o *AVPlayerItem) PreferredPeakBitRateForExpensiveNetworks() float64

Indicates the desired limit of network bandwidth consumption for this item over expensive networks. When preferredPeakBitRateForExpensiveNetworks is set to non-zero, the player will attempt to limit item playback to that bit rate when streaming over an expensive network, such as when using a cellular data plan. (See -[NWPath isExpensive]) If network bandwidth consumption cannot be lowered to meet the preferredPeakBitRateForExpensiveNetworks, it will be reduced as much as possible while continuing to play the item. Note that preferredPeakBitRate still applies unconditionally. If preferredPeakBitRateForExpensiveNetworks is less restrictive (greater) than preferredPeakBitRate, preferredPeakBitRateForExpensiveNetworks has no practical effect.

func (*AVPlayerItem) PresentationSize ¶

func (o *AVPlayerItem) PresentationSize() corefoundation.CGSize

The size of the receiver as presented by the player. Indicates the size at which the visual portion of the item is presented by the player; can be scaled from this size to fit within the bounds of an AVPlayerLayer via its videoGravity property. Can be scaled arbitrarily for presentation via the frame property of an AVPlayerLayer. The value of this property will accord with the properties of the underlying media resource when the receiver becomes ready to play. Before the underlying media resource is sufficiently loaded, its value is CGSizeZero. Use key-value observation to obtain a valid presentationSize as soon as it becomes available. (Note that the value of presentationSize may remain CGSizeZero, e.g. for audio-only items.)

func (*AVPlayerItem) RecommendedTimeOffsetFromLive ¶

func (o *AVPlayerItem) RecommendedTimeOffsetFromLive() coremedia.CMTime

A recommended value for configuredTimeOffsetFromLive, based on observed network conditions. For non-live assets this value is kCMTimeInvalid.

func (*AVPlayerItem) RemoveMediaDataCollector ¶

func (o *AVPlayerItem) RemoveMediaDataCollector(collector *AVPlayerItemMediaDataCollector)

Removes the specified instance of AVPlayerItemMediaDataCollector from the receiver's collection of mediaDataCollectors. - Parameter collector: An instance of AVPlayerItemMediaDataCollector

func (*AVPlayerItem) RemoveOutput ¶

func (o *AVPlayerItem) RemoveOutput(output *AVPlayerItemOutput)

Removes the specified instance of AVPlayerItemOutput from the receiver's collection of outputs. - Parameter output: An instance of AVPlayerItemOutput

func (*AVPlayerItem) RequestContentAuthorizationAsynchronouslyWithTimeoutIntervalCompletionHandler ¶

func (o *AVPlayerItem) RequestContentAuthorizationAsynchronouslyWithTimeoutIntervalCompletionHandler(timeoutInterval float64, handler func())

@method requestContentAuthorizationAsynchronouslyWithTimeoutInterval:completionHandler: @abstract Causes appropriate action to be taken to allow the user to authorize the content for playback. @discussion Calling this method will present the user with the opportunity to authorize the content (e.g. by launching iTunes and prompting the user to enter their Apple ID and password). When the user has taken action (or the timeout has elapsted), the completion handler will be invoked. The status of the authorization attempt can be determined by checking the value of the contentAuthorizationRequestStatus property. Note that even if the status indicates a completed authorization, the content may still not be authorized (e.g. if the user authorizes an Apple ID other than that associated with the content). The contentAuthorizedForPlayback property should be re-checked to verify whether the content has actually been authorized before continuing. It is not necessary to call this method if the value of contentAuthorizedForPlayback is already true. @param timeoutInterval The maximum amount of time to wait for the user to authorize the content in seconds before calling the handler block with a timeout result. @param handler Block to be called upon completion.

func (*AVPlayerItem) ReversePlaybackEndTime ¶

func (o *AVPlayerItem) ReversePlaybackEndTime() coremedia.CMTime

The end time for reverse playback. Specifies the time at which playback should end when the playback rate is negative (see AVPlayer's rate property). The default value is kCMTimeInvalid, which indicates that no end time for reverse playback is specified. In this case, the effective end time for reverse playback is kCMTimeZero. When the end time is reached, the receiver will post AVPlayerItemDidPlayToEndTimeNotification and the AVPlayer will take the action indicated by the value of its actionAtItemEnd property (see AVPlayerActionAtItemEnd in AVPlayer.h). The value of this property has no effect on playback when the rate is positive.

func (*AVPlayerItem) SeekToDate ¶

func (o *AVPlayerItem) SeekToDate(date *foundation.NSDate) bool

move playhead to a point corresponding to a particular date. For playback content that is associated with a range of dates, move the playhead to point within that range. Will fail if the supplied date is outside the range or if the content is not associated with a range of dates. - Parameter date: The new position for the playhead. - Returns: Returns true if the playhead was moved to the supplied date. Deprecated: Use -seekToDate:completionHandler:, passing nil for the completionHandler if you don't require notification of completion

func (*AVPlayerItem) SeekToDateCompletionHandler ¶

func (o *AVPlayerItem) SeekToDateCompletionHandler(date *foundation.NSDate, completionHandler func(bool)) bool

move playhead to a point corresponding to a particular date, and invokes the specified block when the seek operation has either been completed or been interrupted. For playback content that is associated with a range of dates, move the playhead to point within that range and invokes the completion handler when the seek operation is complete. Will fail if the supplied date is outside the range or if the content is not associated with a range of dates. The completion handler for any prior seek request that is still in process will be invoked immediately with the finished parameter set to NO. If the new request completes without being interrupted by another seek request or by any other operation, the specified completion handler will be invoked with the finished parameter set to YES. - Parameter date: The new position for the playhead. - Parameter completionHandler: The block to invoke when seek operation is complete - Returns: Returns true if the playhead was moved to the supplied date.

func (*AVPlayerItem) SeekToTime ¶

func (o *AVPlayerItem) SeekToTime(time_ coremedia.CMTime)

Moves the playback cursor. Use this method to seek to a specified time for the item. The time seeked to may differ from the specified time for efficiency. For sample accurate seeking see seekToTime:toleranceBefore:toleranceAfter:. If the seek time is outside of seekable time ranges as indicated by seekableTimeRanges property, the seek request will be cancelled. - Parameter time: Deprecated: Use -seekToTime:completionHandler:, passing nil for the completionHandler if you don't require notification of completion

func (*AVPlayerItem) SeekToTimeCompletionHandler ¶

func (o *AVPlayerItem) SeekToTimeCompletionHandler(time_ coremedia.CMTime, completionHandler func(bool))

Moves the playback cursor and invokes the specified block when the seek operation has either been completed or been interrupted. Use this method to seek to a specified time for the item and to be notified when the seek operation is complete. The completion handler for any prior seek request that is still in process will be invoked immediately with the finished parameter set to NO. If the new request completes without being interrupted by another seek request or by any other operation the specified completion handler will be invoked with the finished parameter set to YES. If the seek time is outside of seekable time ranges as indicated by seekableTimeRanges property, the seek request will be cancelled and the completion handler will be invoked with the finished parameter set to NO. This method throws an exception if time is invalid or indefinite. - Parameter time: - Parameter completionHandler:

func (*AVPlayerItem) SeekToTimeToleranceBeforeToleranceAfter ¶

func (o *AVPlayerItem) SeekToTimeToleranceBeforeToleranceAfter(time_ coremedia.CMTime, toleranceBefore coremedia.CMTime, toleranceAfter coremedia.CMTime)

Moves the playback cursor within a specified time bound. Use this method to seek to a specified time for the item. The time seeked to will be within the range [time-toleranceBefore, time+toleranceAfter] and may differ from the specified time for efficiency. Pass kCMTimeZero for both toleranceBefore and toleranceAfter to request sample accurate seeking which may incur additional decoding delay. Messaging this method with beforeTolerance:kCMTimePositiveInfinity and afterTolerance:kCMTimePositiveInfinity is the same as messaging seekToTime: directly. Seeking is constrained by the collection of seekable time ranges. If you seek to a time outside all of the seekable ranges the seek will result in a currentTime within the seekable ranges. If the seek time is outside of seekable time ranges as indicated by seekableTimeRanges property, the seek request will be cancelled. - Parameter time: - Parameter toleranceBefore: - Parameter toleranceAfter: Deprecated: Use -seekToTime:toleranceBefore:toleranceAfter:completionHandler:, passing nil for the completionHandler if you don't require notification of completion

func (*AVPlayerItem) SeekToTimeToleranceBeforeToleranceAfterCompletionHandler ¶

func (o *AVPlayerItem) SeekToTimeToleranceBeforeToleranceAfterCompletionHandler(time_ coremedia.CMTime, toleranceBefore coremedia.CMTime, toleranceAfter coremedia.CMTime, completionHandler func(bool))

Moves the playback cursor within a specified time bound and invokes the specified block when the seek operation has either been completed or been interrupted. Use this method to seek to a specified time for the item and to be notified when the seek operation is complete. The time seeked to will be within the range [time-toleranceBefore, time+toleranceAfter] and may differ from the specified time for efficiency. Pass kCMTimeZero for both toleranceBefore and toleranceAfter to request sample accurate seeking which may incur additional decoding delay. Messaging this method with beforeTolerance:kCMTimePositiveInfinity and afterTolerance:kCMTimePositiveInfinity is the same as messaging seekToTime: directly. The completion handler for any prior seek request that is still in process will be invoked immediately with the finished parameter set to NO. If the new request completes without being interrupted by another seek request or by any other operation the specified completion handler will be invoked with the finished parameter set to YES. If the seek time is outside of seekable time ranges as indicated by seekableTimeRanges property, the seek request will be cancelled and the completion handler will be invoked with the finished parameter set to NO. This method throws an exception if time is invalid or indefinite or if tolerance before or tolerance after is invalid or negative. - Parameter time: - Parameter toleranceBefore: - Parameter toleranceAfter: - Parameter completionHandler:

func (*AVPlayerItem) SeekableTimeRanges ¶

func (o *AVPlayerItem) SeekableTimeRanges() *foundation.NSArray[*foundation.NSValue]

This property provides a collection of time ranges that the player item can seek to. The ranges provided might be discontinous. Returns an NSArray of NSValues containing CMTimeRanges.

func (*AVPlayerItem) SeekingWaitsForVideoCompositionRendering ¶

func (o *AVPlayerItem) SeekingWaitsForVideoCompositionRendering() bool

Indicates whether the item's timing follows the displayed video frame when seeking with a video composition By default, item timing is updated as quickly as possible, not waiting for media at new times to be rendered when seeking or during normal playback. The latency that occurs, for example, between the completion of a seek operation and the display of a video frame at a new time is negligible in most situations. However, when video compositions are in use, the processing of video for any particular time may introduce noticeable latency. Therefore it may be desirable when a video composition is in use for the item's timing be updated only after the video frame for a time has been displayed. This allows, for instance, an AVSynchronizedLayer associated with an AVPlayerItem to remain in synchronization with the displayed video and for the currentTime property to return the time of the displayed video. This property has no effect on items for which videoComposition is nil.

func (*AVPlayerItem) SelectMediaOptionAutomaticallyInMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectMediaOptionAutomaticallyInMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup)

Selects the media option in the specified media selection group that best matches the AVPlayer's current automatic selection criteria. Also allows automatic selection to be re-applied to the specified group subsequently if the relevant criteria are changed. Has no effect unless the appliesMediaSelectionCriteriaAutomatically property of the associated AVPlayer is YES and unless automatic media selection has previously been overridden via -[AVPlayerItem selectMediaOption:inMediaSelectionGroup:]. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue. - Parameter mediaSelectionGroup: The media selection group, obtained from the receiver's asset, that contains the specified option.

func (*AVPlayerItem) SelectMediaOptionInMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectMediaOptionInMediaSelectionGroup(mediaSelectionOption *AVMediaSelectionOption, mediaSelectionGroup *AVMediaSelectionGroup)

Selects the media option described by the specified instance of AVMediaSelectionOption in the specified AVMediaSelectionGroup and deselects all other options in that group. If the specified media selection option isn't a member of the specified media selection group, no change in presentation state will result. If the value of the property allowsEmptySelection of the AVMediaSelectionGroup is YES, you can pass nil for mediaSelectionOption to deselect all media selection options in the group. Note that if multiple options within a group meet your criteria for selection according to locale or other considerations, and if these options are otherwise indistinguishable to you according to media characteristics that are meaningful for your application, content is typically authored so that the first available option that meets your criteria is appropriate for selection. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue. - Parameter mediaSelectionOption: The option to select. - Parameter mediaSelectionGroup: The media selection group, obtained from the receiver's asset, that contains the specified option.

func (*AVPlayerItem) SelectMediaPresentationLanguageForMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectMediaPresentationLanguageForMediaSelectionGroup(language *foundation.NSString, mediaSelectionGroup *AVMediaSelectionGroup)

When the associated AVPlayer's appliesMediaSelectionCriteriaAutomatically property is set to YES, configures the player item to prefer a particular language, replacing any previous preference for available languages of the specified group's custom media selection scheme. Overrides preferences for languages specified by the AVPlayer's current media selection criteria. This method has no effect when the associated AVPlayer's appliesMediaSelectionCriteriaAutomatically property has a value of NO, in which case you must use -selectMediaOption:inMediaSelectionGroup: instead in order to alter the presentation state of the media. - Parameter languages: A BCP 47 language tag, typically obtained from the availableLanguages of the AVCustomMediaSelectionScheme of the specified AVMediaSelectionGroup. - Parameter mediaSelectionGroup: The media selection group, obtained from the receiver's asset, to which the specified setting is to be applied.

func (*AVPlayerItem) SelectMediaPresentationSettingForMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectMediaPresentationSettingForMediaSelectionGroup(mediaPresentationSetting *AVMediaPresentationSetting, mediaSelectionGroup *AVMediaSelectionGroup)

When the associated AVPlayer's appliesMediaSelectionCriteriaAutomatically property is set to YES, configures the player item to prefer a particular presentation setting, replacing any previous preference for settings of the same media presentation selector. Note that preferences for media characteristics indicated by selected AVMediaPresentationSettings are treated as supplemental to the associated AVPlayer's media selection criteria for the AVMediaSelectionGroup. An AVPlayer's default media selection criteria can also indicate preferences for media characteristics, such as those indicating the availability of accessibility affordances such as audio descriptions, and these media characteristics can be left up to the AVPlayer to manage even when an AVCustomMediaSelectionScheme is in use. But if you wish to do so, you can use AVMediaPresentationSettings offered by a AVCustomMediaSelectionScheme in combination with custom AVPlayerMediaSelectionCriteria. If the specified setting isn't offered by an AVMediaPresentationSelector of the AVCustomMediaSelectionScheme of the specified AVMediaSelectionGroup, no change in the presentation of the media will result. This method has no effect when the associated AVPlayer's appliesMediaSelectionCriteriaAutomatically property has a value of NO, in which case you must use -selectMediaOption:inMediaSelectionGroup: instead in order to alter the presentation state of the media. - Parameter mediaPresentationSetting: The setting to select. - Parameter mediaSelectionGroup: The media selection group, obtained from the receiver's asset, to which the specified setting is to be applied.

func (*AVPlayerItem) SelectedMediaOptionInMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectedMediaOptionInMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *AVMediaSelectionOption

Indicates the media selection option that's currently selected from the specified group. May be nil. If the value of the property allowsEmptySelection of the AVMediaSelectionGroup is YES, the currently selected option in the group may be nil. - Parameter mediaSelectionGroup: A media selection group obtained from the receiver's asset. - Returns: An instance of AVMediaSelectionOption that describes the currently selection option in the group. Deprecated: Use currentMediaSelection to obtain an instance of AVMediaSelection, which encompasses the currently selected AVMediaSelectionOption in each of the available AVMediaSelectionGroups

func (*AVPlayerItem) SelectedMediaPresentationLanguageForMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectedMediaPresentationLanguageForMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *foundation.NSString

Returns the selected media presentation language for the specified media selection group, if any language has previously been selected via use of -selectMediaPresentationLanguages:forMediaSelectionGroup:. - Parameter mediaSelectionGroup: The media selection group, obtained from the receiver's asset, for which the selected media presentation language is requested.

func (*AVPlayerItem) SelectedMediaPresentationSettingsForMediaSelectionGroup ¶

func (o *AVPlayerItem) SelectedMediaPresentationSettingsForMediaSelectionGroup(mediaSelectionGroup *AVMediaSelectionGroup) *foundation.NSDictionary[*AVMediaPresentationSelector, objc.ID]

Indicates the media presentation settings that have most recently been selected for each AVMediaPresentationSelector of the AVCustomMediaSelectionScheme of the specified AVMediaSelectionGroup. - Parameter mediaSelectionGroup: An AVMediaSelectionGroup obtained from the receiver's asset for which the currently selected media presentation settings are desired. - Returns: A dictionary with AVMediaPresentationSelectors as keys and AVMediaPresentationSettings as values, providing the most recently selected setting for each selector or, if no setting has previously been selected, NSNull.

func (*AVPlayerItem) SetAllowedAudioSpatializationFormats ¶

func (o *AVPlayerItem) SetAllowedAudioSpatializationFormats(allowedAudioSpatializationFormats AVAudioSpatializationFormats)

func (*AVPlayerItem) SetAppliesPerFrameHDRDisplayMetadata ¶

func (o *AVPlayerItem) SetAppliesPerFrameHDRDisplayMetadata(appliesPerFrameHDRDisplayMetadata bool)

func (*AVPlayerItem) SetAudioMix ¶

func (o *AVPlayerItem) SetAudioMix(audioMix *AVAudioMix)

func (*AVPlayerItem) SetAudioSpatializationAllowed deprecated

func (o *AVPlayerItem) SetAudioSpatializationAllowed(audioSpatializationAllowed bool)

Deprecated: Use allowedAudioSpatializationFormats instead

func (*AVPlayerItem) SetAudioTimePitchAlgorithm ¶

func (o *AVPlayerItem) SetAudioTimePitchAlgorithm(audioTimePitchAlgorithm *foundation.NSString)

func (*AVPlayerItem) SetAutomaticallyHandlesInterstitialEvents ¶

func (o *AVPlayerItem) SetAutomaticallyHandlesInterstitialEvents(automaticallyHandlesInterstitialEvents bool)

Allows interstitials to be played according to a schedule that's specified by server-side directives. The default value is YES. A value of NO prevents automatic scheduling of future server-side interstitial events. Events specified by an AVPlayerInterstitialEventController override server-side events, regardless of the value of this property. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayerItem) SetAutomaticallyPreservesTimeOffsetFromLive ¶

func (o *AVPlayerItem) SetAutomaticallyPreservesTimeOffsetFromLive(automaticallyPreservesTimeOffsetFromLive bool)

func (*AVPlayerItem) SetCanUseNetworkResourcesForLiveStreamingWhilePaused ¶

func (o *AVPlayerItem) SetCanUseNetworkResourcesForLiveStreamingWhilePaused(canUseNetworkResourcesForLiveStreamingWhilePaused bool)

func (*AVPlayerItem) SetConfiguredTimeOffsetFromLive ¶

func (o *AVPlayerItem) SetConfiguredTimeOffsetFromLive(configuredTimeOffsetFromLive coremedia.CMTime)

func (*AVPlayerItem) SetForwardPlaybackEndTime ¶

func (o *AVPlayerItem) SetForwardPlaybackEndTime(forwardPlaybackEndTime coremedia.CMTime)

func (*AVPlayerItem) SetPreferredCustomMediaSelectionSchemes ¶

func (o *AVPlayerItem) SetPreferredCustomMediaSelectionSchemes(preferredCustomMediaSelectionSchemes *foundation.NSArray[*AVCustomMediaSelectionScheme])

func (*AVPlayerItem) SetPreferredForwardBufferDuration ¶

func (o *AVPlayerItem) SetPreferredForwardBufferDuration(preferredForwardBufferDuration float64)

func (*AVPlayerItem) SetPreferredMaximumResolution ¶

func (o *AVPlayerItem) SetPreferredMaximumResolution(preferredMaximumResolution corefoundation.CGSize)

func (*AVPlayerItem) SetPreferredMaximumResolutionForExpensiveNetworks ¶

func (o *AVPlayerItem) SetPreferredMaximumResolutionForExpensiveNetworks(preferredMaximumResolutionForExpensiveNetworks corefoundation.CGSize)

func (*AVPlayerItem) SetPreferredPeakBitRate ¶

func (o *AVPlayerItem) SetPreferredPeakBitRate(preferredPeakBitRate float64)

func (*AVPlayerItem) SetPreferredPeakBitRateForExpensiveNetworks ¶

func (o *AVPlayerItem) SetPreferredPeakBitRateForExpensiveNetworks(preferredPeakBitRateForExpensiveNetworks float64)

func (*AVPlayerItem) SetReversePlaybackEndTime ¶

func (o *AVPlayerItem) SetReversePlaybackEndTime(reversePlaybackEndTime coremedia.CMTime)

func (*AVPlayerItem) SetSeekingWaitsForVideoCompositionRendering ¶

func (o *AVPlayerItem) SetSeekingWaitsForVideoCompositionRendering(seekingWaitsForVideoCompositionRendering bool)

func (*AVPlayerItem) SetStartsOnFirstEligibleVariant ¶

func (o *AVPlayerItem) SetStartsOnFirstEligibleVariant(startsOnFirstEligibleVariant bool)

func (*AVPlayerItem) SetTextStyleRules ¶

func (o *AVPlayerItem) SetTextStyleRules(textStyleRules *foundation.NSArray[*AVTextStyleRule])

func (*AVPlayerItem) SetVariantPreferences ¶

func (o *AVPlayerItem) SetVariantPreferences(variantPreferences AVVariantPreferences)

func (*AVPlayerItem) SetVideoApertureMode ¶

func (o *AVPlayerItem) SetVideoApertureMode(videoApertureMode *foundation.NSString)

func (*AVPlayerItem) SetVideoComposition ¶

func (o *AVPlayerItem) SetVideoComposition(videoComposition *AVVideoComposition)

Indicates the video composition settings to be applied during playback. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue. This property throws an exception if a video composition is set with any of the following values: - renderSize, renderScale, or frameDuration is less than or equal to zero - sourceTrackIDForFrameTiming is less than or equal to zero - uses AVVideoCompositionCoreAnimationTool (works for offline rendering only)

func (*AVPlayerItem) StartsOnFirstEligibleVariant ¶

func (o *AVPlayerItem) StartsOnFirstEligibleVariant() bool

Directs the player to start playback with the first eligible variant that appears in the stream's master playlist. This property influences AVPlayer's algorithm for selecting which of the eligible variant streams in an HTTP Live Streaming master playlist is selected when playback first begins. In all cases, AVPlayer may switch to other variants during playback. On releases prior to macOS 10.15, iOS 13, tvOS 13 and watchOS 6, AVPlayer starts HLS playback with the first eligible variant in the master playlist. On releases starting with macOS 10.15, iOS 13, tvOS 13 and watchOS 6, AVPlayer starts HLS playback by choosing an initial variant that optimizes the startup experience. On releases starting with macOS 11.0, iOS 14, tvOS 14 and watchOS 7, applications may set this property to YES to request that AVPlayer use the previous behaviour of using the first eligible variant in the master playlist. This would be appropriate, for example, for applications which wish to control initial variant selection by ordering the variants in the master playlist. Note that changing this property may impact stream startup performance and quality. In order to be effective this property must be set before initial variant selection occurs. This property only applies to HTTP Live Streaming assets. The default value of this property is NO.

func (*AVPlayerItem) Status ¶

func (o *AVPlayerItem) Status() AVPlayerItemStatus

The ability of the receiver to be used for playback. The value of this property is an AVPlayerItemStatus that indicates whether the receiver can be used for playback. When the value of this property is AVPlayerItemStatusFailed, the receiver can no longer be used for playback and a new instance needs to be created in its place. When this happens, clients can check the value of the error property to determine the nature of the failure. The value of this property will not be updated after the receiver is removed from an AVPlayer. This property is key value observable.

func (*AVPlayerItem) StepByCount ¶

func (o *AVPlayerItem) StepByCount(stepCount int)

Moves player's current item's current time forward or backward by the specified number of steps. The size of each step depends on the enabled AVPlayerItemTracks of the AVPlayerItem. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this method must be invoked on the main thread/queue. - Parameter stepCount: The number of steps by which to move. A positive number results in stepping forward, a negative number in stepping backward.

func (*AVPlayerItem) TemplatePlayerItem ¶

func (o *AVPlayerItem) TemplatePlayerItem() *AVPlayerItem

If the item was created automatically according to a template item for looping, for interstitial playback, or for other purposes, indicates the AVPlayerItem that was used as the template.

func (*AVPlayerItem) TextStyleRules ¶

func (o *AVPlayerItem) TextStyleRules() *foundation.NSArray[*AVTextStyleRule]

An array of AVTextStyleRules representing text styling that can be applied to subtitles and other legible media. The styling information contained in each AVTextStyleRule object in the array is used only when no equivalent styling information is provided by the media resource being played. For example, if the text style rules specify Courier font but the media resource specifies Helvetica font, the text will be drawn using Helvetica font. This property has an effect only for tracks with media subtype kCMSubtitleFormatType_WebVTT.

func (*AVPlayerItem) Timebase ¶

func (o *AVPlayerItem) Timebase() unsafe.Pointer

The item's timebase. You can examine the timebase to discover the relationship between the item's time and the source clock used for drift synchronization. This timebase is read-only; you cannot set its time or rate to affect playback.

func (*AVPlayerItem) TimedMetadata ¶

func (o *AVPlayerItem) TimedMetadata() *foundation.NSArray[*AVMetadataItem]

Provides an NSArray of AVMetadataItems representing the timed metadata encountered most recently within the media as it plays. May be nil. Notifications of changes are available via key-value observation. As an optimization for playback, AVPlayerItem may omit the processing of timed metadata when no observer of this property is registered. Therefore, when no such observer is registered, the value of the timedMetadata property may remain nil regardless of the contents of the underlying media. This property must be accessed on the main thread/queue. Deprecated: Use AVPlayerItemMetadataOutput to obtain timed metadata

func (*AVPlayerItem) Tracks ¶

Provides array of AVPlayerItem tracks. Observable (can change dynamically during playback). The value of this property will accord with the properties of the underlying media resource when the receiver becomes ready to play. Before the underlying media resource has been sufficiently loaded, its value is an empty NSArray. Use key-value observation to obtain a valid array of tracks as soon as it becomes available.

func (*AVPlayerItem) VariantPreferences ¶

func (o *AVPlayerItem) VariantPreferences() AVVariantPreferences

Indicates preferences for variant switching. Changing variant preferences during playback may result in a variant switch. The default value is AVVariantPreferenceNone.

func (*AVPlayerItem) VideoApertureMode ¶

func (o *AVPlayerItem) VideoApertureMode() *foundation.NSString

Specifies the video aperture mode to apply during playback. See AVVideoApertureMode constants defined in AVVideoSettings.h. Default is AVVideoApertureModeCleanAperture.

func (*AVPlayerItem) VideoComposition ¶

func (o *AVPlayerItem) VideoComposition() *AVVideoComposition

Indicates the video composition settings to be applied during playback. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue. This property throws an exception if a video composition is set with any of the following values: - renderSize, renderScale, or frameDuration is less than or equal to zero - sourceTrackIDForFrameTiming is less than or equal to zero - uses AVVideoCompositionCoreAnimationTool (works for offline rendering only)

type AVPlayerItemAccessLog ¶

type AVPlayerItemAccessLog struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemaccesslog

func AVPlayerItemAccessLogFromID ¶

func AVPlayerItemAccessLogFromID(id objc.ID) *AVPlayerItemAccessLog

func (*AVPlayerItemAccessLog) Events ¶

An ordered collection of AVPlayerItemAccessLogEvent instances. An ordered collection of AVPlayerItemAccessLogEvent instances that represent the chronological sequence of events contained in the access log. This property is not observable.

func (*AVPlayerItemAccessLog) ExtendedLogData ¶

func (o *AVPlayerItemAccessLog) ExtendedLogData() *foundation.NSData

Serializes an AVPlayerItemAccessLog in the Extended Log File Format. This method converts the webserver access log into a textual format that conforms to the W3C Extended Log File Format for web server log files. For more information see: http://www.w3.org/pub/WWW/TR/WD-logfile.html - Returns: An autoreleased NSData instance.

func (*AVPlayerItemAccessLog) ExtendedLogDataStringEncoding ¶

func (o *AVPlayerItemAccessLog) ExtendedLogDataStringEncoding() uint

Returns the NSStringEncoding for extendedLogData, see above. A string suitable for console output is obtainable by: [[NSString alloc] initWithData:[myLog extendedLogData] encoding:[myLog extendedLogDataStringEncoding]]

type AVPlayerItemAccessLogEvent ¶

type AVPlayerItemAccessLogEvent struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemaccesslogevent

func AVPlayerItemAccessLogEventFromID ¶

func AVPlayerItemAccessLogEventFromID(id objc.ID) *AVPlayerItemAccessLogEvent

func (*AVPlayerItemAccessLogEvent) AverageAudioBitrate ¶

func (o *AVPlayerItemAccessLogEvent) AverageAudioBitrate() float64

The average bitrate of audio track. This is not available if audio is muxed with video. Measured in bits per second. Value is negative if unknown. Corresponds to "c-avg-audio-bitrate". This property is not observable.

func (*AVPlayerItemAccessLogEvent) AverageVideoBitrate ¶

func (o *AVPlayerItemAccessLogEvent) AverageVideoBitrate() float64

The average bitrate of video track if it is unmuxed. Average bitrate of combined content if muxed. Measured in bits per second. Value is negative if unknown. Corresponds to "c-avg-video-bitrate". This property is not observable.

func (*AVPlayerItemAccessLogEvent) DownloadOverdue ¶

func (o *AVPlayerItemAccessLogEvent) DownloadOverdue() int

The total number of times the download of the segments took too long. Value is negative if unknown. Corresponds to "c-overdue". This property is not observable.

func (*AVPlayerItemAccessLogEvent) DurationWatched ¶

func (o *AVPlayerItemAccessLogEvent) DurationWatched() float64

The accumulated duration of the media played. Measured in seconds. Value is negative if unknown. Corresponds to "c-duration-watched". This property is not observable.

func (*AVPlayerItemAccessLogEvent) IndicatedAverageBitrate ¶

func (o *AVPlayerItemAccessLogEvent) IndicatedAverageBitrate() float64

Average throughput required to play the stream, as advertised by the server. Measured in bits per second. Value is negative if unknown. Corresponds to "sc-indicated-avg-bitrate". This property is not observable.

func (*AVPlayerItemAccessLogEvent) IndicatedBitrate ¶

func (o *AVPlayerItemAccessLogEvent) IndicatedBitrate() float64

The throughput required to play the stream, as advertised by the server. Measured in bits per second. Value is negative if unknown. Corresponds to "sc-indicated-bitrate". This property is not observable.

func (*AVPlayerItemAccessLogEvent) MediaRequestsWWAN ¶

func (o *AVPlayerItemAccessLogEvent) MediaRequestsWWAN() int

Number of network read requests over WWAN. Value is negative if unknown. Corresponds to "sc-wwan-count". This property is not observable.

func (*AVPlayerItemAccessLogEvent) NumberOfBytesTransferred ¶

func (o *AVPlayerItemAccessLogEvent) NumberOfBytesTransferred() int64

The accumulated number of bytes transferred. Value is negative if unknown. Corresponds to "bytes". This property is not observable.

func (*AVPlayerItemAccessLogEvent) NumberOfDroppedVideoFrames ¶

func (o *AVPlayerItemAccessLogEvent) NumberOfDroppedVideoFrames() int

The total number of dropped video frames. Value is negative if unknown. Corresponds to "c-frames-dropped". This property is not observable.

func (*AVPlayerItemAccessLogEvent) NumberOfMediaRequests ¶

func (o *AVPlayerItemAccessLogEvent) NumberOfMediaRequests() int

A count of media read requests. Value is negative if unknown. A count of media read requests from the server to this client. Corresponds to "sc-count". For HTTP live Streaming, a count of media segments downloaded from the server to this client. For progressive-style HTTP media downloads, a count of HTTP GET (byte-range) requests for the resource. This property is not observable.

func (*AVPlayerItemAccessLogEvent) NumberOfSegmentsDownloaded ¶

func (o *AVPlayerItemAccessLogEvent) NumberOfSegmentsDownloaded() int

A count of media segments downloaded. Value is negative if unknown. A count of media segments downloaded from the server to this client. Corresponds to "sc-count". This property is not observable. This property is deprecated. Use numberOfMediaRequests instead. Deprecated: since macOS 10.9.

func (*AVPlayerItemAccessLogEvent) NumberOfServerAddressChanges ¶

func (o *AVPlayerItemAccessLogEvent) NumberOfServerAddressChanges() int

A count of changes to the property serverAddress, see above, over the last uninterrupted period of playback. Value is negative if unknown. Corresponds to "s-ip-changes". This property is not observable.

func (*AVPlayerItemAccessLogEvent) NumberOfStalls ¶

func (o *AVPlayerItemAccessLogEvent) NumberOfStalls() int

The total number of playback stalls encountered. Value is negative if unknown. Corresponds to "c-stalls". This property is not observable.

func (*AVPlayerItemAccessLogEvent) ObservedBitrate ¶

func (o *AVPlayerItemAccessLogEvent) ObservedBitrate() float64

The empirical throughput across all media downloaded. Measured in bits per second. Value is negative if unknown. Corresponds to "c-observed-bitrate". This property is not observable.

func (*AVPlayerItemAccessLogEvent) ObservedBitrateStandardDeviation ¶

func (o *AVPlayerItemAccessLogEvent) ObservedBitrateStandardDeviation() float64

Standard deviation of observed segment download bit rates. Value is negative if unknown. Corresponds to "c-observed-bitrate-sd". This property is not observable.

func (*AVPlayerItemAccessLogEvent) ObservedMaxBitrate ¶

func (o *AVPlayerItemAccessLogEvent) ObservedMaxBitrate() float64

Maximum observed segment download bit rate. Value is negative if unknown. Corresponds to "c-observed-max-bitrate". This property is not observable. Deprecated: Use observedBitrateStandardDeviation to monitor variance in network bitrate.

func (*AVPlayerItemAccessLogEvent) ObservedMinBitrate ¶

func (o *AVPlayerItemAccessLogEvent) ObservedMinBitrate() float64

Minimum observed segment download bit rate. Value is negative if unknown. Corresponds to "c-observed-min-bitrate". This property is not observable. Deprecated: Use observedBitrateStandardDeviation to monitor variance in network bitrate.

func (*AVPlayerItemAccessLogEvent) PlaybackSessionID ¶

func (o *AVPlayerItemAccessLogEvent) PlaybackSessionID() *foundation.NSString

A GUID that identifies the playback session. This value is used in HTTP requests. Can be nil. If nil is returned the GUID is unknown. Corresponds to "cs-guid". This property is not observable.

func (*AVPlayerItemAccessLogEvent) PlaybackStartDate ¶

func (o *AVPlayerItemAccessLogEvent) PlaybackStartDate() *foundation.NSDate

The date/time at which playback began for this event. Can be nil. If nil is returned the date is unknown. Corresponds to "date". This property is not observable.

func (*AVPlayerItemAccessLogEvent) PlaybackStartOffset ¶

func (o *AVPlayerItemAccessLogEvent) PlaybackStartOffset() float64

An offset into the playlist where the last uninterrupted period of playback began. Measured in seconds. Value is negative if unknown. Corresponds to "c-start-time". This property is not observable.

func (*AVPlayerItemAccessLogEvent) PlaybackType ¶

func (o *AVPlayerItemAccessLogEvent) PlaybackType() *foundation.NSString

Playback type (LIVE, VOD, FILE). If nil is returned the playback type is unknown. Corresponds to "s-playback-type". This property is not observable.

func (*AVPlayerItemAccessLogEvent) SegmentsDownloadedDuration ¶

func (o *AVPlayerItemAccessLogEvent) SegmentsDownloadedDuration() float64

The accumulated duration of the media downloaded. Measured in seconds. Value is negative if unknown. Corresponds to "c-duration-downloaded". This property is not observable.

func (*AVPlayerItemAccessLogEvent) ServerAddress ¶

func (o *AVPlayerItemAccessLogEvent) ServerAddress() *foundation.NSString

The IP address of the server that was the source of the last delivered media segment. Can be nil. If nil is returned the address is unknown. Can be either an IPv4 or IPv6 address. Corresponds to "s-ip". This property is not observable.

func (*AVPlayerItemAccessLogEvent) StartupTime ¶

func (o *AVPlayerItemAccessLogEvent) StartupTime() float64

The accumulated duration until player item is ready to play. Measured in seconds. Value is negative if unknown. Corresponds to "c-startup-time". This property is not observable.

func (*AVPlayerItemAccessLogEvent) SwitchBitrate ¶

func (o *AVPlayerItemAccessLogEvent) SwitchBitrate() float64

Bandwidth that caused us to switch (up or down). Value is negative if unknown. Corresponds to "c-switch-bitrate". This property is not observable.

func (*AVPlayerItemAccessLogEvent) TransferDuration ¶

func (o *AVPlayerItemAccessLogEvent) TransferDuration() float64

The accumulated duration of active network transfer of bytes. Measured in seconds. Value is negative if unknown. Corresponds to "c-transfer-duration". This property is not observable.

func (*AVPlayerItemAccessLogEvent) URI ¶

The URI of the playback item. Can be nil. If nil is returned the URI is unknown. Corresponds to "uri". This property is not observable.

type AVPlayerItemErrorLog ¶

type AVPlayerItemErrorLog struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemerrorlog

func AVPlayerItemErrorLogFromID ¶

func AVPlayerItemErrorLogFromID(id objc.ID) *AVPlayerItemErrorLog

func (*AVPlayerItemErrorLog) Events ¶

An ordered collection of AVPlayerItemErrorLogEvent instances. An ordered collection of AVPlayerItemErrorLogEvent instances that represent the chronological sequence of events contained in the error log. This property is not observable.

func (*AVPlayerItemErrorLog) ExtendedLogData ¶

func (o *AVPlayerItemErrorLog) ExtendedLogData() *foundation.NSData

Serializes an AVPlayerItemErrorLog in the Extended Log File Format. This method converts the webserver error log into a textual format that conforms to the W3C Extended Log File Format for web server log files. For more information see: http://www.w3.org/pub/WWW/TR/WD-logfile.html - Returns: An autoreleased NSData instance.

func (*AVPlayerItemErrorLog) ExtendedLogDataStringEncoding ¶

func (o *AVPlayerItemErrorLog) ExtendedLogDataStringEncoding() uint

Returns the NSStringEncoding for extendedLogData, see above. A string suitable for console output is obtainable by: [[NSString alloc] initWithData:[myLog extendedLogData] encoding:[myLog extendedLogDataStringEncoding]]

type AVPlayerItemErrorLogEvent ¶

type AVPlayerItemErrorLogEvent struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemerrorlogevent

func AVPlayerItemErrorLogEventFromID ¶

func AVPlayerItemErrorLogEventFromID(id objc.ID) *AVPlayerItemErrorLogEvent

func (*AVPlayerItemErrorLogEvent) AllHTTPResponseHeaderFields ¶

The HTTP header fields returned by the server, if an HTTP response was received as part of this error. See -[NSHTTPURLResponse allHeaderFields] for more information.

func (*AVPlayerItemErrorLogEvent) Date ¶

The date and time when the error occured. Can be nil. If nil is returned the date is unknown. Corresponds to "date". This property is not observable.

func (*AVPlayerItemErrorLogEvent) ErrorComment ¶

func (o *AVPlayerItemErrorLogEvent) ErrorComment() *foundation.NSString

A description of the error encountered. Can be nil. If nil is returned further information is not available. Corresponds to "comment". This property is not observable.

func (*AVPlayerItemErrorLogEvent) ErrorDomain ¶

func (o *AVPlayerItemErrorLogEvent) ErrorDomain() *foundation.NSString

The domain of the error. Corresponds to "domain". This property is not observable.

func (*AVPlayerItemErrorLogEvent) ErrorStatusCode ¶

func (o *AVPlayerItemErrorLogEvent) ErrorStatusCode() int

A unique error code identifier. Corresponds to "status". This property is not observable.

func (*AVPlayerItemErrorLogEvent) PlaybackSessionID ¶

func (o *AVPlayerItemErrorLogEvent) PlaybackSessionID() *foundation.NSString

A GUID that identifies the playback session. This value is used in HTTP requests. Can be nil. If nil is returned the GUID is unknown. Corresponds to "cs-guid". This property is not observable.

func (*AVPlayerItemErrorLogEvent) ServerAddress ¶

func (o *AVPlayerItemErrorLogEvent) ServerAddress() *foundation.NSString

The IP address of the server that was the source of the error. Can be nil. If nil is returned the address is unknown. Can be either an IPv4 or IPv6 address. Corresponds to "s-ip". This property is not observable.

func (*AVPlayerItemErrorLogEvent) URI ¶

The URI of the playback item. Can be nil. If nil is returned the URI is unknown. Corresponds to "uri". This property is not observable.

type AVPlayerItemIntegratedTimeline ¶

type AVPlayerItemIntegratedTimeline struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemintegratedtimeline

func AVPlayerItemIntegratedTimelineFromID ¶

func AVPlayerItemIntegratedTimelineFromID(id objc.ID) *AVPlayerItemIntegratedTimeline

func (*AVPlayerItemIntegratedTimeline) AddBoundaryTimeObserverForSegmentOffsetsIntoSegmentQueueUsing ¶

func (o *AVPlayerItemIntegratedTimeline) AddBoundaryTimeObserverForSegmentOffsetsIntoSegmentQueueUsing(segment *AVPlayerItemSegment, offsetsIntoSegment *foundation.NSArray[objc.ID], queue *foundation.NSObject, block func(bool)) AVPlayerItemIntegratedTimelineObserver

@method addBoundaryTimeObserverForSegment @abstract Requests invocation of a block when an offset in a segment is traversed during playback. @param segment AVPlayerItemSegment to monitor playback traversal of. @param offsetsIntoSegment Offsets in the segment for which the observer requests notification, supplied as an array of NSValues carrying CMTimes. @param queue The serial queue onto which block should be enqueued. If you pass NULL, the main queue (obtained using dispatch_get_main_queue()) will be used. Passing a concurrent queue to this method will result in undefined behavior. @param block The block to be invoked when the offset is crossed during playback of a segment. @result An object conforming to the AVPlayerItemIntegratedTimelineObserver protocol. You must retain this returned value as long as you want the time observer to be invoked by the timeline. Pass this object to -removeTimeObserver: to cancel time observation. One can also configure single point segments with segmentTimes to trigger during traversal of the segment's playback. As the timeline duration and segments change, the installed time observer will be automatically adjusted to fire at the desired offset in the segment. A segment that is removed from the timeline will trigger the invocation of the block immediately with success set as false. Each call to -addBoundaryTimeObserverForSegment:segment:offsetsInSegment:queue:usingBlock: should be paired with a corresponding call to -removeTimeObserver:. Releasing the observer object without a call to -removeTimeObserver: will result in undefined behavior

func (*AVPlayerItemIntegratedTimeline) AddPeriodicTimeObserverForIntervalQueueUsing ¶

func (o *AVPlayerItemIntegratedTimeline) AddPeriodicTimeObserverForIntervalQueueUsing(interval coremedia.CMTime, queue *foundation.NSObject, block objc.Block) AVPlayerItemIntegratedTimelineObserver

@method addPeriodicTimeObserverForInterval @abstract Requests invocation of a block during playback to report changing time. @param interval The interval of invocation of the block during normal playback, according to progress of the current time in the integrated timeline. @param queue The serial queue onto which block should be enqueued. If you pass NULL, the main queue (obtained using dispatch_get_main_queue()) will be used. Passing a concurrent queue to this method will result in undefined behavior. @param block The block to be invoked periodically. @result An object conforming to the AVPlayerItemIntegratedTimelineObserver protocol. You must retain this returned value as long as you want the time observer to be invoked by the timeline. The block is invoked periodically at the interval specified, interpreted according to the integrated timeline. The block is also invoked across AVPlayerItemSegment and AVPlayerItem boundaries, whenever time jumps, and whenever playback starts or stops. Each call to -addPeriodicTimeObserverForInterval:queue:usingBlock: should be paired with a corresponding call to -removeTimeObserver:. Releasing the observer object without a call to -removeTimeObserver: will result in undefined behavior

func (*AVPlayerItemIntegratedTimeline) CurrentDate ¶

@property currentDate @abstract Returns the date of current playback, or nil if playback is not mapped to any date.

func (*AVPlayerItemIntegratedTimeline) CurrentSnapshot ¶

@property currentSnapshot @abstract This property provides an immutable representation of the timeline state at time of request. @discussion Returns an immutable representation of the timeline state at time of request. A timeline snapshot provides accessors for obtaining inspectable details of the timeline. Because a snapshot is immutable, the snapshot's properties will not update as playback continues.

func (*AVPlayerItemIntegratedTimeline) CurrentTime ¶

@property currentTime @abstract Returns the current time on the integrated timeline. @discussion Returns the current time on the integrated timeline. During playback of interstitial events that occupy a single point, currentTime will not change.

func (*AVPlayerItemIntegratedTimeline) RemoveTimeObserver ¶

@method removeTimeObserver: @abstract Cancels a previously registered time observer. @param observer An object returned by a previous call to -addPeriodicTimeObserverForInterval or -addBoundaryTimeObserverForSegment.

func (*AVPlayerItemIntegratedTimeline) SeekToDateCompletionHandler ¶

func (o *AVPlayerItemIntegratedTimeline) SeekToDateCompletionHandler(date *foundation.NSDate, completionHandler func(bool))

@method seekToDate @abstract Seeks playhead to corresponding date and invokes the completionHandler. @param date The new position for the playhead. @param completionHandler CompletionHandler callback after seek completes. Success will be true if the playhead moved to the new date. @discussion The integrated timeline will seek playhead to the coresponding date.

func (*AVPlayerItemIntegratedTimeline) SeekToTimeToleranceBeforeToleranceAfterCompletionHandler ¶

func (o *AVPlayerItemIntegratedTimeline) SeekToTimeToleranceBeforeToleranceAfterCompletionHandler(time_ coremedia.CMTime, toleranceBefore coremedia.CMTime, toleranceAfter coremedia.CMTime, completionHandler func(bool))

@method seekToTime @abstract Seeks to a particular time in the integrated time domain and invokes the completionHandler @param time Time represented in the integrated time domain. @param toleranceBefore Tolerance before target time allowed to seek to. @param toleranceAfter Tolerance after target time allowed to seek to. @param completionHandler CompletionHandler callback after seek completes. Success will be true if the playhead moved to the new time. @discussion The integrated timeline seeks to the the range of [time-beforeTolerance, time+afterTolerance] will be attributed to a segment and AVPlayerItem that falls in that range. You can request sample accurate seeking by passing a time value of kCMTimeZero for both toleranceBefore and toleranceAfter.

type AVPlayerItemIntegratedTimelineObserver ¶

type AVPlayerItemIntegratedTimelineObserver interface {
}

AVPlayerItemIntegratedTimelineObserver wraps the ObjC protocol AVPlayerItemIntegratedTimelineObserver.

type AVPlayerItemIntegratedTimelineSnapshot ¶

type AVPlayerItemIntegratedTimelineSnapshot struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemintegratedtimelinesnapshot

func AVPlayerItemIntegratedTimelineSnapshotFromID ¶

func AVPlayerItemIntegratedTimelineSnapshotFromID(id objc.ID) *AVPlayerItemIntegratedTimelineSnapshot

func (*AVPlayerItemIntegratedTimelineSnapshot) CurrentDate ¶

@property currentDate @abstract Returns the current date when the snapshot was taken, or nil if playback is not mapped to any date.

func (*AVPlayerItemIntegratedTimelineSnapshot) CurrentSegment ¶

@property currentSegment @abstract Returns the current AVPlayerItemSegment playback is traversing.

func (*AVPlayerItemIntegratedTimelineSnapshot) CurrentTime ¶

@property currentTime @abstract Returns the current time on the integrated timeline when the snapshot was taken. @discussion Returns the current time on the integrated timeline when the snapshot was taken. CurrentTime will not change as playback progresses.

func (*AVPlayerItemIntegratedTimelineSnapshot) Duration ¶

@property duration @abstract Returns the duration totaling the primary item and scheduled interstitial events. @discussion This property returns the duration totaling the primary item and scheduled interstitial events and taking into account the interstitial event's playoutLimit and resumption offset. Before loading the duration of the primary item, the value of this property is kCMTimeInvalid. For livestreams, this value will be kCMTimeIndefinite.

func (*AVPlayerItemIntegratedTimelineSnapshot) MapTimeToSegmentAtSegmentOffset ¶

func (o *AVPlayerItemIntegratedTimelineSnapshot) MapTimeToSegmentAtSegmentOffset(time_ coremedia.CMTime, timeSegmentOut *AVPlayerItemSegment, segmentOffsetOut *coremedia.CMTime)

@method mapTime @abstract Provides mapping from time to AVPlayerItemSegment and offset in segment. @param time Time represented in the integrated time domain. @param timeSegmentOut Output parameter for segment. @param segmentOffsetOut Output parameter for offset in segment. @discussion Provides mapping from time to segment and offset in the segment's timeMapping target. For time that correlates to the start of multiple segments, this will return the first one.

func (*AVPlayerItemIntegratedTimelineSnapshot) Segments ¶

@property segments @abstract Returns an array of AVPlayerItemSegment for the snapshot. @discussion Returns an array of AVPlayerItemSegment. The segments are presented in chronological order, contiguous from the previous element, and non-overlapping.

type AVPlayerItemLegibleOutput ¶

type AVPlayerItemLegibleOutput struct {
	AVPlayerItemOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemlegibleoutput

func AVPlayerItemLegibleOutputFromID ¶

func AVPlayerItemLegibleOutputFromID(id objc.ID) *AVPlayerItemLegibleOutput

func (*AVPlayerItemLegibleOutput) AdvanceIntervalForDelegateInvocation ¶

func (o *AVPlayerItemLegibleOutput) AdvanceIntervalForDelegateInvocation() float64

@property advanceIntervalForDelegateInvocation @abstract Permits advance invocation of the associated delegate, if any. @discussion If it is possible, an AVPlayerItemLegibleOutput will message its delegate advanceIntervalForDelegateInvocation seconds earlier than otherwise. If the value you provide is large, effectively requesting provision of samples earlier than the AVPlayerItemLegibleOutput is prepared to act on them, the delegate will be invoked as soon as possible.

func (*AVPlayerItemLegibleOutput) Delegate ¶

@property delegate @abstract The receiver's delegate. @discussion The delegate is held using a zeroing-weak reference, so this property will have a value of nil after a delegate that was previously set has been deallocated. This property is not key-value observable.

func (*AVPlayerItemLegibleOutput) DelegateQueue ¶

func (o *AVPlayerItemLegibleOutput) DelegateQueue() *foundation.NSObject

@property delegateQueue @abstract The dispatch queue where the delegate is messaged. @discussion This property is not key-value observable.

func (*AVPlayerItemLegibleOutput) InitWithMediaSubtypesForNativeRepresentation ¶

func (o *AVPlayerItemLegibleOutput) InitWithMediaSubtypesForNativeRepresentation(subtypes *foundation.NSArray[*foundation.NSNumber]) *AVPlayerItemLegibleOutput

@method initWithMediaSubtypesForNativeRepresentation: @abstract Returns an instance of AVPlayerItemLegibleOutput with filtering enabled for AVPlayerItemLegibleOutputPushDelegate's legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:. @param subtypes NSArray of NSNumber FourCC codes, e.g. @[ [NSNumber numberWithUnsignedInt:'tx3g'] ] @result An instance of AVPlayerItemLegibleOutput. @discussion Add media subtype FourCC number objects to the subtypes array to elect to receive that type as a CMSampleBuffer instead of an NSAttributedString. Initializing an AVPlayerItemLegibleOutput using the -init method is equivalent to calling -initWithMediaSubtypesForNativeRepresentation: with an empty array, which means that all legible data, regardless of media subtype, will be delivered using NSAttributedString in a common format. If a media subtype for which there is no legible data in the current player item is included in the media subtypes array, no error will occur. AVPlayerItemLegibleOutput will not vend closed caption data as CMSampleBuffers, so it is an error to include 'c608' in the media subtypes array. This method throws an exception if any media subtype is kCMClosedCaptionFormatType_CEA608 (native representation is not available for media subtype).

func (*AVPlayerItemLegibleOutput) SetAdvanceIntervalForDelegateInvocation ¶

func (o *AVPlayerItemLegibleOutput) SetAdvanceIntervalForDelegateInvocation(advanceIntervalForDelegateInvocation float64)

func (*AVPlayerItemLegibleOutput) SetDelegateQueue ¶

func (o *AVPlayerItemLegibleOutput) SetDelegateQueue(delegate AVPlayerItemLegibleOutputPushDelegate, delegateQueue *foundation.NSObject)

@method setDelegate:queue: @abstract Sets the receiver's delegate and a dispatch queue on which the delegate will be called. @param delegate An object conforming to AVPlayerItemLegibleOutputPushDelegate protocol. @param delegateQueue A dispatch queue on which all delegate methods will be called. @discussion The delegate is held using a zeroing-weak reference, so it is safe to deallocate the delegate while the receiver still has a reference to it.

func (*AVPlayerItemLegibleOutput) SetTextStylingResolution ¶

func (o *AVPlayerItemLegibleOutput) SetTextStylingResolution(textStylingResolution *foundation.NSString)

func (*AVPlayerItemLegibleOutput) TextStylingResolution ¶

func (o *AVPlayerItemLegibleOutput) TextStylingResolution() *foundation.NSString

type AVPlayerItemLegibleOutputPushDelegate ¶

type AVPlayerItemLegibleOutputPushDelegate interface {
	AVPlayerItemOutputPushDelegate
}

AVPlayerItemLegibleOutputPushDelegate wraps the ObjC protocol AVPlayerItemLegibleOutputPushDelegate.

type AVPlayerItemMetadataCollector ¶

type AVPlayerItemMetadataCollector struct {
	AVPlayerItemMediaDataCollector
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemmetadatacollector

func AVPlayerItemMetadataCollectorFromID ¶

func AVPlayerItemMetadataCollectorFromID(id objc.ID) *AVPlayerItemMetadataCollector

func (*AVPlayerItemMetadataCollector) Delegate ¶

@property delegate @abstract The receiver's delegate. @discussion The delegate is held using a zeroing-weak reference, so this property will have a value of nil after a delegate that was previously set has been deallocated. This property is not key-value observable.

func (*AVPlayerItemMetadataCollector) DelegateQueue ¶

@property delegateQueue @abstract The dispatch queue on which messages are sent to the delegate. @discussion This property is not key-value observable.

func (*AVPlayerItemMetadataCollector) InitWithIdentifiersClassifyingLabels ¶

func (o *AVPlayerItemMetadataCollector) InitWithIdentifiersClassifyingLabels(identifiers *foundation.NSArray[*foundation.NSString], classifyingLabels *foundation.NSArray[*foundation.NSString]) *AVPlayerItemMetadataCollector

@method initWithIdentifiers:classifyingLabels: @abstract Returns an instance of AVPlayerItemMetadataCollector that can provide all available AVMetadataGroups matching a set of criteria. @param identifiers A array of metadata identifiers indicating the metadata items that the output should provide. See AVMetadataIdentifiers.h for publicly defined metadata identifiers. Pass nil to include metadata with any identifier. @param classifyingLabels If the metadata format supports labeling each metadata group with a string, supplying an array of group labels indicates that the output should provide metadata groups that match one of the supplied labels. Pass nil to include metadata with any (or no) classifying label. @result An instance of AVPlayerItemMetadataCollector. @discussion Some metadata available in some formats - such as timed metadata embedded in HLS segments - is not available for collector output. The default init method can be used as an alternative to setting both identifiers and classifyingLabels to nil.

func (*AVPlayerItemMetadataCollector) SetDelegateQueue ¶

@method setDelegate:queue: @abstract Sets the receiver's delegate and a dispatch queue on which the delegate will be called. @param delegate An object conforming to AVPlayerItemMetadataCollectorPushDelegate protocol. @param delegateQueue A dispatch queue on which all delegate methods will be called.

type AVPlayerItemMetadataCollectorPushDelegate ¶

type AVPlayerItemMetadataCollectorPushDelegate interface {
	MetadataCollectorDidCollectDateRangeMetadataGroupsIndexesOfNewGroupsIndexesOfModifiedGroups(metadataCollector *AVPlayerItemMetadataCollector, metadataGroups *foundation.NSArray[*AVDateRangeMetadataGroup], indexesOfNewGroups *foundation.NSIndexSet, indexesOfModifiedGroups *foundation.NSIndexSet)
}

AVPlayerItemMetadataCollectorPushDelegate wraps the ObjC protocol AVPlayerItemMetadataCollectorPushDelegate.

type AVPlayerItemMetadataOutput ¶

type AVPlayerItemMetadataOutput struct {
	AVPlayerItemOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemmetadataoutput

func AVPlayerItemMetadataOutputFromID ¶

func AVPlayerItemMetadataOutputFromID(id objc.ID) *AVPlayerItemMetadataOutput

func (*AVPlayerItemMetadataOutput) AdvanceIntervalForDelegateInvocation ¶

func (o *AVPlayerItemMetadataOutput) AdvanceIntervalForDelegateInvocation() float64

@property advanceIntervalForDelegateInvocation @abstract Permits advance invocation of the associated delegate, if any. @discussion If it is possible, an AVPlayerItemMetadataOutput will message its delegate advanceIntervalForDelegateInvocation seconds earlier than otherwise. If the value you provide is large, effectively requesting provision of samples earlier than the AVPlayerItemMetadataOutput is prepared to act on them, the delegate will be invoked as soon as possible.

func (*AVPlayerItemMetadataOutput) Delegate ¶

@property delegate @abstract The receiver's delegate. @discussion The delegate is held using a zeroing-weak reference, so this property will have a value of nil after a delegate that was previously set has been deallocated. This property is not key-value observable.

func (*AVPlayerItemMetadataOutput) DelegateQueue ¶

func (o *AVPlayerItemMetadataOutput) DelegateQueue() *foundation.NSObject

@property delegateQueue @abstract The dispatch queue on which messages are sent to the delegate. @discussion This property is not key-value observable.

func (*AVPlayerItemMetadataOutput) InitWithIdentifiers ¶

@method initWithIdentifiers: @abstract Creates an instance of AVPlayerItemMetadataOutput. @param identifiers A array of metadata identifiers indicating the metadata items that the output should provide. @discussion See AVMetadataIdentifiers.h for publicly defined metadata identifiers. Pass nil to receive all of the timed metadata from all enabled AVPlayerItemTracks that carry timed metadata.

func (*AVPlayerItemMetadataOutput) SetAdvanceIntervalForDelegateInvocation ¶

func (o *AVPlayerItemMetadataOutput) SetAdvanceIntervalForDelegateInvocation(advanceIntervalForDelegateInvocation float64)

func (*AVPlayerItemMetadataOutput) SetDelegateQueue ¶

func (o *AVPlayerItemMetadataOutput) SetDelegateQueue(delegate AVPlayerItemMetadataOutputPushDelegate, delegateQueue *foundation.NSObject)

@method setDelegate:queue: @abstract Sets the receiver's delegate and a dispatch queue on which the delegate will be called. @param delegate An object conforming to AVPlayerItemMetadataOutputPushDelegate protocol. @param delegateQueue A dispatch queue on which all delegate methods will be called.

type AVPlayerItemMetadataOutputPushDelegate ¶

type AVPlayerItemMetadataOutputPushDelegate interface {
	AVPlayerItemOutputPushDelegate
}

AVPlayerItemMetadataOutputPushDelegate wraps the ObjC protocol AVPlayerItemMetadataOutputPushDelegate.

type AVPlayerItemOutput ¶

type AVPlayerItemOutput struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemoutput

func AVPlayerItemOutputFromID ¶

func AVPlayerItemOutputFromID(id objc.ID) *AVPlayerItemOutput

func (*AVPlayerItemOutput) ItemTimeForCVTimeStamp ¶

func (o *AVPlayerItemOutput) ItemTimeForCVTimeStamp(timestamp corevideo.CVTimeStamp) coremedia.CMTime

func (*AVPlayerItemOutput) ItemTimeForHostTime ¶

func (o *AVPlayerItemOutput) ItemTimeForHostTime(hostTimeInSeconds float64) coremedia.CMTime

func (*AVPlayerItemOutput) ItemTimeForMachAbsoluteTime ¶

func (o *AVPlayerItemOutput) ItemTimeForMachAbsoluteTime(machAbsoluteTime int64) coremedia.CMTime

func (*AVPlayerItemOutput) SetSuppressesPlayerRendering ¶

func (o *AVPlayerItemOutput) SetSuppressesPlayerRendering(suppressesPlayerRendering bool)

func (*AVPlayerItemOutput) SuppressesPlayerRendering ¶

func (o *AVPlayerItemOutput) SuppressesPlayerRendering() bool

type AVPlayerItemOutputPullDelegate ¶

type AVPlayerItemOutputPullDelegate interface {
}

AVPlayerItemOutputPullDelegate wraps the ObjC protocol AVPlayerItemOutputPullDelegate.

type AVPlayerItemOutputPushDelegate ¶

type AVPlayerItemOutputPushDelegate interface {
}

AVPlayerItemOutputPushDelegate wraps the ObjC protocol AVPlayerItemOutputPushDelegate.

type AVPlayerItemRenderedLegibleOutput ¶

type AVPlayerItemRenderedLegibleOutput struct {
	AVPlayerItemOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemrenderedlegibleoutput

func AVPlayerItemRenderedLegibleOutputFromID ¶

func AVPlayerItemRenderedLegibleOutputFromID(id objc.ID) *AVPlayerItemRenderedLegibleOutput

func (*AVPlayerItemRenderedLegibleOutput) AdvanceIntervalForDelegateInvocation ¶

func (o *AVPlayerItemRenderedLegibleOutput) AdvanceIntervalForDelegateInvocation() float64

@property advanceIntervalForDelegateInvocation @abstract Permits advance invocation of the associated delegate, if any. @discussion If it is possible, an AVPlayerItemRenderedLegibleOutput will message its delegate advanceIntervalForDelegateInvocation seconds earlier than otherwise. If the value you provide is large, effectively requesting provision of samples earlier than the AVPlayerItemRenderedLegibleOutput is prepared to act on them, the delegate will be invoked as soon as possible.

func (*AVPlayerItemRenderedLegibleOutput) Delegate ¶

@property delegate @abstract The receiver's delegate. @discussion The delegate is held using a zeroing-weak reference, so this property will have a value of nil after a delegate that was previously set has been deallocated. This property is not key-value observable.

func (*AVPlayerItemRenderedLegibleOutput) DelegateQueue ¶

@property delegateQueue @abstract The dispatch queue where the delegate is messaged. @discussion This property is not key-value observable.

func (*AVPlayerItemRenderedLegibleOutput) InitWithVideoDisplaySize ¶

func (o *AVPlayerItemRenderedLegibleOutput) InitWithVideoDisplaySize(videoDisplaySize corefoundation.CGSize) *AVPlayerItemRenderedLegibleOutput

@method initWithVideoDisplaySize: @abstract Creates an instance of AVPlayerItemRenderedLegibleOutput. @param videoDisplaySize CGSize for the video display area @discussion This is the only available initializer for AVPlayerItemRenderedLegibleOutput. The client can also choose to reset videoDisplaySize after initialization or during playback. Initializing and resetting videoDisplaySize with a zero height or width will result in an exception being thrown.

func (*AVPlayerItemRenderedLegibleOutput) SetAdvanceIntervalForDelegateInvocation ¶

func (o *AVPlayerItemRenderedLegibleOutput) SetAdvanceIntervalForDelegateInvocation(advanceIntervalForDelegateInvocation float64)

func (*AVPlayerItemRenderedLegibleOutput) SetDelegateQueue ¶

@method setDelegate:queue: @abstract Sets the receiver's delegate and a dispatch queue on which the delegate will be called. @param delegate An object conforming to AVPlayerItemRenderedLegibleOutputPushDelegate protocol. @param delegateQueue A dispatch queue on which all delegate methods will be called. @discussion The delegate is held using a zeroing-weak reference, so it is safe to deallocate the delegate while the receiver still has a reference to it.

func (*AVPlayerItemRenderedLegibleOutput) SetVideoDisplaySize ¶

func (o *AVPlayerItemRenderedLegibleOutput) SetVideoDisplaySize(videoDisplaySize corefoundation.CGSize)

func (*AVPlayerItemRenderedLegibleOutput) VideoDisplaySize ¶

@property videoDisplaySize @abstract Permits rendering of pixel buffers according to the set width and height @discussion The client is expected to set videodisplay size during init and may also set it again during playback. The pixel buffers will be rendered according to the set width and height of display area. If this property is set during the presentation time of a vended caption image, a new caption image rendered according to new videoDisplaySize, will be vended out. Setting this property with a zero height or width will result in an exception being thrown and it is client's responsibility to handle it using appropriate catch block.

type AVPlayerItemRenderedLegibleOutputPushDelegate ¶

type AVPlayerItemRenderedLegibleOutputPushDelegate interface {
	AVPlayerItemOutputPushDelegate
}

AVPlayerItemRenderedLegibleOutputPushDelegate wraps the ObjC protocol AVPlayerItemRenderedLegibleOutputPushDelegate.

type AVPlayerItemSegment ¶

type AVPlayerItemSegment struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemsegment

func AVPlayerItemSegmentFromID ¶

func AVPlayerItemSegmentFromID(id objc.ID) *AVPlayerItemSegment

func (*AVPlayerItemSegment) InterstitialEvent ¶

func (o *AVPlayerItemSegment) InterstitialEvent() *AVPlayerInterstitialEvent

@property interstitialEvent @abstract The associated interstitial event for this segment. @discussion The associated interstitial event for this segment. This value will be nil for segments representing playback of the primary itme.

func (*AVPlayerItemSegment) LoadedTimeRanges ¶

func (o *AVPlayerItemSegment) LoadedTimeRanges() *foundation.NSArray[*foundation.NSValue]

@property loadedTimeRanges @abstract This property provides a collection of time ranges for the segment if media data is readily available. The ranges provided might be discontinuous. @discussion Returns an NSArray of NSValues containing CMTimeRanges. Loaded time ranges will be within the timeMapping's target timeRange. Loaded time ranges will be empty for interstitial events that occupy a single point in time.

func (*AVPlayerItemSegment) SegmentType ¶

@property segmentType @abstract The type of content this segment represents.

func (*AVPlayerItemSegment) StartDate ¶

func (o *AVPlayerItemSegment) StartDate() *foundation.NSDate

@property startDate @abstract The date this segment starts at. @discussion The date this segment starts at. This value will be nil if the primary item does not contain dates.

func (*AVPlayerItemSegment) TimeMapping ¶

func (o *AVPlayerItemSegment) TimeMapping() coremedia.CMTimeMapping

@property timeMapping @abstract The timeMapping for this segment. @discussion The timeMapping source timeRange represents the start and duration in the segment source's timeline (ie: primary item timeline or interstitial event). The target timeRange represents the start point and duration in the integrated timeline. For interstitial events which occupy a single point, the target's duration will be kCMTimeZero.

type AVPlayerItemSegmentType ¶

type AVPlayerItemSegmentType int64
const (
	AVPlayerItemSegmentTypePrimary      AVPlayerItemSegmentType = 0
	AVPlayerItemSegmentTypeInterstitial AVPlayerItemSegmentType = 1
)

func (AVPlayerItemSegmentType) String ¶

func (e AVPlayerItemSegmentType) String() string

type AVPlayerItemStatus ¶

type AVPlayerItemStatus int64
const (
	// Indicates that the status of the player item is not yet known because it has not tried to load new media resources for playback.
	AVPlayerItemStatusUnknown AVPlayerItemStatus = 0
	// Indicates that the player item is ready to be played.
	AVPlayerItemStatusReadyToPlay AVPlayerItemStatus = 1
	// Indicates that the player item can no longer be played because of an error. The error is described by the value of the player item's error property. The player item's errorLog property might contain additional information about the error.
	AVPlayerItemStatusFailed AVPlayerItemStatus = 2
)

func (AVPlayerItemStatus) String ¶

func (e AVPlayerItemStatus) String() string

type AVPlayerItemTrack ¶

type AVPlayerItemTrack struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemtrack

func AVPlayerItemTrackFromID ¶

func AVPlayerItemTrackFromID(id objc.ID) *AVPlayerItemTrack

func (*AVPlayerItemTrack) AssetTrack ¶

func (o *AVPlayerItemTrack) AssetTrack() *AVAssetTrack

@property assetTrack @abstract Indicates the AVAssetTrack for which the AVPlayerItemTrack represents presentation state. @discussion This property is not observable. Clients must serialize their access to the resulting AVAssetTrack and related objects on the associated AVPlayer's notification queue. By default, this queue is the main queue.

func (*AVPlayerItemTrack) CurrentVideoFrameRate ¶

func (o *AVPlayerItemTrack) CurrentVideoFrameRate() float32

@property currentVideoFrameRate @abstract If the media type of the assetTrack is AVMediaTypeVideo, indicates the current frame rate of the track as it plays, in units of frames per second. If the item is not playing, or if the media type of the track is not video, the value of this property is 0. @discussion This property is not observable. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayerItemTrack) IsEnabled ¶

func (o *AVPlayerItemTrack) IsEnabled() bool

@property enabled @abstract Indicates whether the track is enabled for presentation during playback. @discussion Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayerItemTrack) SetEnabled ¶

func (o *AVPlayerItemTrack) SetEnabled(enabled bool)

func (*AVPlayerItemTrack) SetVideoFieldMode ¶

func (o *AVPlayerItemTrack) SetVideoFieldMode(videoFieldMode *foundation.NSString)

@property videoFieldMode @abstract If the media type of the assetTrack is AVMediaTypeVideo, specifies the handling of video frames that contain multiple fields. @discussion A value of nil indicates default processing of video frames. If you want video fields to be deinterlaced, set videoFieldMode to AVPlayerItemTrackVideoFieldModeDeinterlaceFields. You can test whether video being played has multiple fields by examining the underlying AVAssetTrack's format descriptions. See -[AVAssetTrack formatDescriptions] and, for video format descriptions, kCMFormatDescriptionExtension_FieldCount. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

func (*AVPlayerItemTrack) VideoFieldMode ¶

func (o *AVPlayerItemTrack) VideoFieldMode() *foundation.NSString

@property videoFieldMode @abstract If the media type of the assetTrack is AVMediaTypeVideo, specifies the handling of video frames that contain multiple fields. @discussion A value of nil indicates default processing of video frames. If you want video fields to be deinterlaced, set videoFieldMode to AVPlayerItemTrackVideoFieldModeDeinterlaceFields. You can test whether video being played has multiple fields by examining the underlying AVAssetTrack's format descriptions. See -[AVAssetTrack formatDescriptions] and, for video format descriptions, kCMFormatDescriptionExtension_FieldCount. Before macOS 13, iOS 16, tvOS 16, and watchOS 9, this property must be accessed on the main thread/queue.

type AVPlayerItemVideoOutput ¶

type AVPlayerItemVideoOutput struct {
	AVPlayerItemOutput
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayeritemvideooutput

func AVPlayerItemVideoOutputFromID ¶

func AVPlayerItemVideoOutputFromID(id objc.ID) *AVPlayerItemVideoOutput

func (*AVPlayerItemVideoOutput) CopyPixelBufferForItemTimeItemTimeForDisplay ¶

func (o *AVPlayerItemVideoOutput) CopyPixelBufferForItemTimeItemTimeForDisplay(itemTime coremedia.CMTime, outItemTimeForDisplay *coremedia.CMTime) unsafe.Pointer

func (*AVPlayerItemVideoOutput) Delegate ¶

@property delegate @abstract The receiver's delegate.

func (*AVPlayerItemVideoOutput) DelegateQueue ¶

func (o *AVPlayerItemVideoOutput) DelegateQueue() *foundation.NSObject

func (*AVPlayerItemVideoOutput) HasNewPixelBufferForItemTime ¶

func (o *AVPlayerItemVideoOutput) HasNewPixelBufferForItemTime(itemTime coremedia.CMTime) bool

func (*AVPlayerItemVideoOutput) InitWithOutputSettings ¶

func (o *AVPlayerItemVideoOutput) InitWithOutputSettings(outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVPlayerItemVideoOutput

func (*AVPlayerItemVideoOutput) InitWithPixelBufferAttributes ¶

func (o *AVPlayerItemVideoOutput) InitWithPixelBufferAttributes(pixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVPlayerItemVideoOutput

func (*AVPlayerItemVideoOutput) RequestNotificationOfMediaDataChangeWithAdvanceInterval ¶

func (o *AVPlayerItemVideoOutput) RequestNotificationOfMediaDataChangeWithAdvanceInterval(interval float64)

func (*AVPlayerItemVideoOutput) SetDelegateQueue ¶

func (o *AVPlayerItemVideoOutput) SetDelegateQueue(delegate AVPlayerItemOutputPullDelegate, delegateQueue *foundation.NSObject)

type AVPlayerLayer ¶

type AVPlayerLayer struct {
	quartzcore.CALayer
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayerlayer

func AVPlayerLayerFromID ¶

func AVPlayerLayerFromID(id objc.ID) *AVPlayerLayer

func AVPlayerLayerPlayerLayerWithPlayer ¶

func AVPlayerLayerPlayerLayerWithPlayer(player *AVPlayer) *AVPlayerLayer

@method layerWithPlayer: @abstract Returns an instance of AVPlayerLayer to display the visual output of the specified AVPlayer. @result An instance of AVPlayerLayer.

func (*AVPlayerLayer) CopyDisplayedPixelBuffer ¶

func (o *AVPlayerLayer) CopyDisplayedPixelBuffer() unsafe.Pointer

@method copyDisplayedPixelBuffer @abstract Returns a retained reference to the pixel buffer currently displayed in this AVPlayerLayer. This will return NULL if the displayed pixel buffer is protected, no image is currently being displayed, if the current player's rate is non-zero or if the image is unavailable. @discussion This will only return the current image while the media is paused, otherwise this will return nil. Clients must release the pixel buffer after use. Do not write to the returned CVPixelBuffer's attachments or pixel data.

func (*AVPlayerLayer) IsReadyForDisplay ¶

func (o *AVPlayerLayer) IsReadyForDisplay() bool

@property readyForDisplay @abstract Boolean indicating that the first video frame has been made ready for display for the current item of the associated AVPlayer. @discusssion Use this property as an indicator of when best to show or animate-in an AVPlayerLayer into view. An AVPlayerLayer may be displayed, or made visible, while this property is NO, however the layer will not have any user-visible content until the value becomes YES. Note that if an animation is added to an AVPlayerLayer before it becomes readyForDisplay the video image displayed inside might not animate with the receiver. This property remains NO for an AVPlayer currentItem whose AVAsset contains no enabled video tracks. This property is key-value observable.

func (*AVPlayerLayer) PixelBufferAttributes ¶

func (o *AVPlayerLayer) PixelBufferAttributes() *foundation.NSDictionary[*foundation.NSString, objc.ID]

@property pixelBufferAttributes @abstract The client requirements for the visual output displayed in AVPlayerLayer during playback. @discussion Pixel buffer attribute keys are defined in <CoreVideo/CVPixelBuffer.h> This property is key-value observable.

func (*AVPlayerLayer) Player ¶

func (o *AVPlayerLayer) Player() *AVPlayer

@property player @abstract Indicates the instance of AVPlayer for which the AVPlayerLayer displays visual output

func (*AVPlayerLayer) SetCaptionPreviewProfileIDPositionText ¶

func (o *AVPlayerLayer) SetCaptionPreviewProfileIDPositionText(profileID *foundation.NSString, position corefoundation.CGPoint, text *foundation.NSString)

Starts displaying a caption preview with the specified accessibility profile. This method enables a preview mode that displays sample caption text using the visual appearance settings from the specified accessibility profile. The preview replaces any currently active subtitles and/or closed captions while active. The sample caption text position can be specified to avoid UI controls. - Parameters: - profileID: The identifier of the accessibility profile to use for caption appearance. Profile IDs can be obtained from `MACaptionAppearanceCopyProfileIDs()`. This determines font, color, background, and other visual characteristics. - position: A CGPoint that defines the position (in points) of the caption preview relative to the default positioning of content captions (centered near the bottom of the video). Position values can be negative. (0, 0) represents the default positioning. - text: Optional custom text to display in the preview. If `nil`, a standard localized preview message will be shown. - Note: You must call “stopShowingCaptionPreview“ to exit the preview.

func (*AVPlayerLayer) SetPixelBufferAttributes ¶

func (o *AVPlayerLayer) SetPixelBufferAttributes(pixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID])

func (*AVPlayerLayer) SetPlayer ¶

func (o *AVPlayerLayer) SetPlayer(player *AVPlayer)

func (*AVPlayerLayer) SetVideoGravity ¶

func (o *AVPlayerLayer) SetVideoGravity(videoGravity *foundation.NSString)

func (*AVPlayerLayer) StopShowingCaptionPreview ¶

func (o *AVPlayerLayer) StopShowingCaptionPreview()

Stops showing the caption preview. This method stops the caption preview and restores any currently active subtitles and/or closed captions.

func (*AVPlayerLayer) VideoGravity ¶

func (o *AVPlayerLayer) VideoGravity() *foundation.NSString

@property videoGravity @abstract A string defining how the video is displayed within an AVPlayerLayer bounds rect. @discusssion Options are AVLayerVideoGravityResizeAspect, AVLayerVideoGravityResizeAspectFill and AVLayerVideoGravityResize. AVLayerVideoGravityResizeAspect is default. See <AVFoundation/AVAnimation.h> for a description of these options.

func (*AVPlayerLayer) VideoRect ¶

func (o *AVPlayerLayer) VideoRect() corefoundation.CGRect

@property videoRect @abstract The current size and position of the video image as displayed within the receiver's bounds.

type AVPlayerLooper ¶

type AVPlayerLooper struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayerlooper

func AVPlayerLooperFromID ¶

func AVPlayerLooperFromID(id objc.ID) *AVPlayerLooper

func AVPlayerLooperPlayerLooperWithPlayerTemplateItem ¶

func AVPlayerLooperPlayerLooperWithPlayerTemplateItem(player *AVQueuePlayer, itemToLoop *AVPlayerItem) *AVPlayerLooper

@method playerLooperWithPlayer:templateItem: @abstract Returns an instance of AVPlayerLooper to loop specified AVPlayerItem with specified AVQueuePlayer. @param player Must not be nil @param itemToLoop Must not be nil @result An instance of AVPlayerLooper. @discussion Equivalent to +playerLooperWithPlayer:templateItem:timeRange: and passing in kCMTimeRangeInvalid for timeRange parameter.

func AVPlayerLooperPlayerLooperWithPlayerTemplateItemTimeRange ¶

func AVPlayerLooperPlayerLooperWithPlayerTemplateItemTimeRange(player *AVQueuePlayer, itemToLoop *AVPlayerItem, loopRange coremedia.CMTimeRange) *AVPlayerLooper

@method playerLooperWithPlayer:templateItem:timeRange: @abstract Returns an instance of AVPlayerLooper to loop specified AVPlayerItem within the specified time range with specified AVQueuePlayer. @param player Must not be nil @param itemToLoop Must not be nil @param loopRange Playback time range in [0, itemToLoop's duration]. kCMTimeRangeInvalid means [0, itemToLoop's duration]. @result An instance of AVPlayerLooper. @discussion The specified AVPlayerItem will be used as a template to generate at least 3 AVPlayerItem replicas and the replicas will be inserted into specified AVQueuePlayer's play queue to accomplish the looping playback. The specified AVPlayerItem should have its asset's duration property loaded beforehand so looping setup work would not be blocked until the duration value is known. Otherwise, AVPlayerLooper's status property is AVPlayerLooperStatusUnknown until the duration property is loaded. The specified AVPlayerItem will not be used in the actual looping playback. Furthermore, AVPlayerItem replicas will be generated at initialization time so any changes made to the specified AVPlayerItem's property afterwards will not be reflected in the replicas used for looping playback. Specified CMTimeRange will limit each item loop iteration to playing within the specified time range. To play from beginning and the whole duration of the item, specify kCMTimeRangeInvalid for the range parameter. Time range will be accomplished by seeking to range start time and setting AVPlayerItem's forwardPlaybackEndTime property on the looping item replicas. Client should not modify AVQueuePlayer's play queue while AVPlayerLooper is performing the looping. AVPlayerLooper will insert the replica items before any existing items in the specified AVQueuePlayer's play queue and change the actionAtItemEnd to AVPlayerActionAtItemEndAdvance if required. AVQueuePlayer's play queue and actionAtItemEnd will be restored when -disableLooping method is called and then current looping item replicas completes playback or when AVPlayerLooper is destroyed. While AVPlayerLooper is being initialized, the specified AVQueuePlayer will be paused (rate of 0.0) if necessary and the original player rate will be restored after initialization completes. The client shall set the specified AVQueuePlayer's rate to 0 beforehand if additional set-up work needs to be performed after AVPlayerLooper initialization and before starting looping playback. An NSInvalidArgumentException will be raised if the player and template item are not specified or the template item has a 0 duration. An NSInvalidArgumentException will be raised if a valid time range has a duration of 0 or is not contained within time 0 and duration of the templateItem.

func (*AVPlayerLooper) DisableLooping ¶

func (o *AVPlayerLooper) DisableLooping()

@method disableLooping @abstract Disables the item looping @discussion AVPlayerLooper will stop performing player queue operations for looping and let the current looping item replica play to the end. The player's original actionAtItemEnd property will be restored afterwards. After this method is called, the value of the receiver's status property will be AVPlayerLooperStatusCancelled.

func (*AVPlayerLooper) Error ¶

func (o *AVPlayerLooper) Error() unsafe.Pointer

@property error @abstract If the receiver's status is AVPlayerLooperStatusFailed, this describes the error that caused the failure. @discussion The value of this property is a NSError that describes what caused the receiver to not be able to perform looping playback. If the receiver's status is not AVPlayerLooperStatusFailed, the value of this property is nil.

func (*AVPlayerLooper) InitWithPlayerTemplateItemTimeRange ¶

func (o *AVPlayerLooper) InitWithPlayerTemplateItemTimeRange(player *AVQueuePlayer, itemToLoop *AVPlayerItem, loopRange coremedia.CMTimeRange) *AVPlayerLooper

@method initWithPlayer:templateItem:timeRange: @abstract Initializes an instance of AVPlayerLooper to loop specified AVPlayerItem within specified time range with specified AVQueuePlayer. @param player Must not be nil @param itemToLoop Must not be nil @param loopRange Playback time range in [0, itemToLoop's duration]. kCMTimeRangeInvalid means [0, itemToLoop's duration]. @result An initialized AVPlayerLooper. @discussion Equivalent to -initWithPlayer:templateItem:timeRange:existingItemsOrdering: and passing AVPlayerLooperItemOrderingLoopingItemsPrecedeExistingItems as the beforeOrAfter parameter.

func (*AVPlayerLooper) InitWithPlayerTemplateItemTimeRangeExistingItemsOrdering ¶

func (o *AVPlayerLooper) InitWithPlayerTemplateItemTimeRangeExistingItemsOrdering(player *AVQueuePlayer, itemToLoop *AVPlayerItem, loopRange coremedia.CMTimeRange, itemOrdering AVPlayerLooperItemOrdering) *AVPlayerLooper

@method initWithPlayer:templateItem:timeRange:existingItemsOrdering: @abstract Initializes an instance of AVPlayerLooper to loop specified AVPlayerItem within specified time range with specified AVQueuePlayer and adhering to specified ordering of existing items in the play queue. @param player Must not be nil @param itemToLoop Must not be nil @param loopRange Playback time range in [0, itemToLoop's duration]. kCMTimeRangeInvalid means [0, itemToLoop's duration]. @param itemOrdering Specifes if replica items are to be inserted before or after existing items in the specified AVQueuePlayer. @result An initialized AVPlayerLooper. @discussion The specified AVPlayerItem will be used as a template to generate at least 3 AVPlayerItem replicas and the replicas will be inserted into specified AVQueuePlayer's play queue to accomplish the looping playback. The specified AVPlayerItem should have its asset's duration property loaded beforehand so looping setup work would not be blocked until the duration value is known. Otherwise, AVPlayerLooper's status property is AVPlayerLooperStatusUnknown until the duration property is loaded. The specified AVPlayerItem will not be used in the actual looping playback. Furthermore, AVPlayerItem replicas will be generated at initialization time so any changes made to the specified AVPlayerItem's property afterwards will not be reflected in the replicas used for looping playback. Specified CMTimeRange will limit each item loop iteration to playing within the specified time range. To play from beginning and the whole duration of the item, specify kCMTimeRangeInvalid for the range parameter. Time range will be accomplished by seeking to range start time and setting AVPlayerItem's forwardPlaybackEndTime property on the looping item replicas. Client should not modify AVQueuePlayer's play queue while AVPlayerLooper is performing the looping. AVPlayerLooper will insert the replica items in the specified AVQueuePlayer's play queue before or after existing equeued items according to the specified AVPlayerLooperItemOrdering. The looper will change the actionAtItemEnd to AVPlayerActionAtItemEndAdvance if required. AVQueuePlayer's play queue and actionAtItemEnd will be restored when -disableLooping method is called and then current looping item replicas completes playback or when AVPlayerLooper is destroyed. While AVPlayerLooper is being initialized, the specified AVQueuePlayer will be paused (rate of 0.0) if necessary and the original player rate will be restored after initialization completes. The client shall set the specified AVQueuePlayer's rate to 0 beforehand if additional set-up work needs to be performed after AVPlayerLooper initialization and before starting looping playback. An NSInvalidArgumentException will be raised if the player and template item are not specified or the template item has a 0 duration. An NSInvalidArgumentException will be raised if a valid time range has a duration of 0 or is not contained within time 0 and duration of the templateItem.

func (*AVPlayerLooper) LoopCount ¶

func (o *AVPlayerLooper) LoopCount() int

@property loopCount @abstract Number of times the specified AVPlayerItem has been played @discussion Starts at 0 and increments when the player starts playback of the AVPlayerItem again. This property is key value observable.

func (*AVPlayerLooper) LoopingPlayerItems ¶

func (o *AVPlayerLooper) LoopingPlayerItems() *foundation.NSArray[*AVPlayerItem]

@property loopingPlayerItems @abstract Returns an array containing replicas of specified AVPlayerItem used to accomplish the looping @discussion AVPlayerLooper creates replicas of the template AVPlayerItem using -copyWithZone: and inserts the replicas in the specified AVQueuePlayer to accomplish the looping. The AVPlayerItem replicas are for informational purposes and to allow the client to apply properties that are not transferred from the template AVPlayerItem to the replicas. The client can determine the number of replicas created and can listen for notifications and property changes from the replicas if desired. AVPlayerItemOutputs and AVPlayerItemMediaDataCollectors are not transferred to the replicas so the client should add them to each replica if desired. The client shall not modify the properties on the replicas that would disrupt looping playback. Examples of such properties are playhead time/date, selected media option, and forward playback end time. This property is key value observable. @result Array containing replicas of specified AVPlayerItem

func (*AVPlayerLooper) Status ¶

@property status @abstract The ability of the receiver to be used for looping playback. @discussion The value of this property is an AVPlayerLooperStatus that indicates whether the receiver is ready for looping playback. When the value of this property is AVPlayerStatusFailed, the receiver can no longer be used for playback and a new instance needs to be created in its place. When this happens, clients can check the value of the error property to determine the nature of the failure. This property is key value observable.

type AVPlayerLooperItemOrdering ¶

type AVPlayerLooperItemOrdering int64
const (
	AVPlayerLooperItemOrderingLoopingItemsPrecedeExistingItems AVPlayerLooperItemOrdering = 0
	AVPlayerLooperItemOrderingLoopingItemsFollowExistingItems  AVPlayerLooperItemOrdering = 1
)

func (AVPlayerLooperItemOrdering) String ¶

type AVPlayerLooperStatus ¶

type AVPlayerLooperStatus int64
const (
	AVPlayerLooperStatusUnknown   AVPlayerLooperStatus = 0
	AVPlayerLooperStatusReady     AVPlayerLooperStatus = 1
	AVPlayerLooperStatusFailed    AVPlayerLooperStatus = 2
	AVPlayerLooperStatusCancelled AVPlayerLooperStatus = 3
)

func (AVPlayerLooperStatus) String ¶

func (e AVPlayerLooperStatus) String() string

type AVPlayerMediaSelectionCriteria ¶

type AVPlayerMediaSelectionCriteria struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayermediaselectioncriteria

func AVPlayerMediaSelectionCriteriaFromID ¶

func AVPlayerMediaSelectionCriteriaFromID(id objc.ID) *AVPlayerMediaSelectionCriteria

func (*AVPlayerMediaSelectionCriteria) InitWithPreferredLanguagesPreferredMediaCharacteristics ¶

func (o *AVPlayerMediaSelectionCriteria) InitWithPreferredLanguagesPreferredMediaCharacteristics(preferredLanguages *foundation.NSArray[*foundation.NSString], preferredMediaCharacteristics *foundation.NSArray[*foundation.NSString]) *AVPlayerMediaSelectionCriteria

@method initWithPreferredLanguages:preferredMediaCharacteristics: @abstract Creates an instance of AVPlayerMediaSelectionCriteria. @param preferredLanguages An NSArray of NSStrings containing language identifiers, in order of desirability, that are preferred for selection. Can be nil. @param preferredMediaCharacteristics An NSArray of AVMediaCharacteristics indicating additional media characteristics, in order of desirability, that are preferred when selecting media with the characteristic for which the receiver is set on the AVPlayer as the selection criteria. Can be nil. @result An instance of AVPlayerMediaSelectionCriteria.

func (*AVPlayerMediaSelectionCriteria) InitWithPrincipalMediaCharacteristicsPreferredLanguagesPreferredMediaCharacteristics ¶

func (o *AVPlayerMediaSelectionCriteria) InitWithPrincipalMediaCharacteristicsPreferredLanguagesPreferredMediaCharacteristics(principalMediaCharacteristics *foundation.NSArray[*foundation.NSString], preferredLanguages *foundation.NSArray[*foundation.NSString], preferredMediaCharacteristics *foundation.NSArray[*foundation.NSString]) *AVPlayerMediaSelectionCriteria

@method initWithPrincipalMediaCharacteristics:principalMediaCharacteristics:preferredLanguages:preferredMediaCharacteristics: @abstract Creates an instance of AVPlayerMediaSelectionCriteria. @param principalMediaCharacteristics An NSArray of AVMediaCharacteristics indicating media characteristics that are considered essential when selecting media with the characteristic for which the receiver is set on the AVPlayer as the selection criteria. Can be nil. @param preferredLanguages An NSArray of NSStrings containing language identifiers, in order of desirability, that are preferred for selection. Can be nil. @param preferredMediaCharacteristics An NSArray of AVMediaCharacteristics indicating additional media characteristics, in order of desirability, that are preferred when selecting media with the characteristic for which the receiver is set on the AVPlayer as the selection criteria. Can be nil. @result An instance of AVPlayerMediaSelectionCriteria. @discussion Note that even though principal media characteristics, when present, will override language preferences when making a selection within a specific media selection group, language preferences may still pertain to selections in other groups. For example, language preferences for the group that corresponds to the audible characteristic may be considered when choosing whether or not to select non-forced subtitles for translation purposes.

func (*AVPlayerMediaSelectionCriteria) PreferredLanguages ¶

func (*AVPlayerMediaSelectionCriteria) PreferredMediaCharacteristics ¶

func (o *AVPlayerMediaSelectionCriteria) PreferredMediaCharacteristics() *foundation.NSArray[*foundation.NSString]

func (*AVPlayerMediaSelectionCriteria) PrincipalMediaCharacteristics ¶

func (o *AVPlayerMediaSelectionCriteria) PrincipalMediaCharacteristics() *foundation.NSArray[*foundation.NSString]

type AVPlayerNetworkResourcePriority ¶

type AVPlayerNetworkResourcePriority int64
const (
	// The default priority level given to a player for loading network resources. Use this when the player requires an optimal level of network resources and streaming in high-quality resolution is ideal. Players with AVPlayerNetworkResourcePriorityHigh will take precedence over this player. This player will take precedence over players with AVPlayerNetworkResourcePriorityLow.
	AVPlayerNetworkResourcePriorityDefault AVPlayerNetworkResourcePriority = 0
	// Indicates a low priority level for loading network resources. Use this when the player requires minimal network bandwidth and streaming in high-quality resolution is not crucial. Other players with higher priority will take precedence over this player.
	AVPlayerNetworkResourcePriorityLow AVPlayerNetworkResourcePriority = 1
	// Indicates a high priority level for loading network resources. Use this when the player requires a high level of network resources and streaming in high-quality resolution is crucial. This player will take precedence over other lower priority players.
	AVPlayerNetworkResourcePriorityHigh AVPlayerNetworkResourcePriority = 2
)

func (AVPlayerNetworkResourcePriority) String ¶

type AVPlayerPlaybackCoordinator ¶

type AVPlayerPlaybackCoordinator struct {
	AVPlaybackCoordinator
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayerplaybackcoordinator

func AVPlayerPlaybackCoordinatorFromID ¶

func AVPlayerPlaybackCoordinatorFromID(id objc.ID) *AVPlayerPlaybackCoordinator

func (*AVPlayerPlaybackCoordinator) CoordinateUsingCoordinationMediumError ¶

func (o *AVPlayerPlaybackCoordinator) CoordinateUsingCoordinationMediumError(coordinationMedium *AVPlaybackCoordinationMedium) (bool, error)

Connects the playback coordinator to the coordination medium This connects the playback coordinator to a coordination medium to enable sending and receiving messages from other connected playback coordinators. If the coordination medium is non-NULL, this will connect the playback coordinator to the specified coordination medium. If the coordination medium is set to NULL, this will disconnect the playback coordinator from the playback coordination medium. The player will no longer be coordinated with the other players connected to the coordination medium. The playback coordinator can either only coordinate with local players through an AVPlaybackCoordinationMedium or coordinate with a remote group session through the `coordinateWithSession` API. If the client attempts to connect to an AVPlaybackCoordinationMedium while already connected to a group session, this method will populate the outError parameter If the playback coordinator successfully connects to the coordination medium or disconnects from a coordination medium, the `outError` parameter will be nil. If the playback coordinator fails to connect to the specified coordination medium, the `outError` parameter will describe what went wrong. - Parameter coordinationMedium: The coordination medium the playback coordinator connects to. If NULL, the playback coordinator disconnects from any existing coordination medium. - Parameter outError: A pointer to an NSError object that will be populated with failure information if connecting to or disconnecting from the coordination medium fails.

func (*AVPlayerPlaybackCoordinator) Delegate ¶

An object implementing the AVPlaybackCoordinatorDelegate protocol.

func (*AVPlayerPlaybackCoordinator) PlaybackCoordinationMedium ¶

func (o *AVPlayerPlaybackCoordinator) PlaybackCoordinationMedium() *AVPlaybackCoordinationMedium

func (*AVPlayerPlaybackCoordinator) Player ¶

The AVPlayer this coordinator is controlling.

func (*AVPlayerPlaybackCoordinator) SetDelegate ¶

type AVPlayerPlaybackCoordinatorDelegate ¶

type AVPlayerPlaybackCoordinatorDelegate interface {
}

AVPlayerPlaybackCoordinatorDelegate wraps the ObjC protocol AVPlayerPlaybackCoordinatorDelegate.

type AVPlayerStatus ¶

type AVPlayerStatus int64
const (
	// Indicates that the status of the player is not yet known because it has not tried to load new media resources for playback.
	AVPlayerStatusUnknown AVPlayerStatus = 0
	// Indicates that the player is ready to play AVPlayerItem instances.
	AVPlayerStatusReadyToPlay AVPlayerStatus = 1
	// Indicates that the player can no longer play AVPlayerItem instances because of an error. The error is described by the value of the player's error property.
	AVPlayerStatusFailed AVPlayerStatus = 2
)

func (AVPlayerStatus) String ¶

func (e AVPlayerStatus) String() string

type AVPlayerTimeControlStatus ¶

type AVPlayerTimeControlStatus int64
const (
	// This state is entered upon receipt of a -pause message, an invocation of -setRate: with a value of 0.0, when a change in overall state requires playback to be halted, such as when an interruption occurs on iOS, as announced by AVAudioSession. In this state, playback is paused indefinitely and will not resume until 1) a subsequent -play message is received or 2) a -setRate: or -playImmediatelyAtRate: message with a non-zero value for rate is received and sufficient media data has been buffered for playback to proceed.
	AVPlayerTimeControlStatusPaused AVPlayerTimeControlStatus = 0
	// This state is entered when 1) the playback buffer becomes empty and playback stalls in AVPlayerTimeControlStatusPlaying, 2) when rate is set from zero to non-zero in AVPlayerTimeControlStatusPaused and insufficient media data has been buffered for playback to occur, or 3) when the player has no item to play, i.e. when the receiver's currentItem is nil. In this state, the value of the rate property is not currently effective but instead indicates the rate at which playback will start or resume. Refer to the value of reasonForWaitingToPlay for details about why the receiver is waiting and the conditions that allow waitStatus to change to AVPlayerWaitStatusPlaying. While waiting for buffering, you can attempt to start playback of any available media data via -playImmediatelyAtRate:.
	AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate AVPlayerTimeControlStatus = 1
	// In this state, playback is currently progressing and rate changes will take effect immediately. Should playback stall because of insufficient media data, timeControlStatus will change to AVPlayerTimeControlStatusWaitingToPlayAtSpecifiedRate.
	AVPlayerTimeControlStatusPlaying AVPlayerTimeControlStatus = 2
)

func (AVPlayerTimeControlStatus) String ¶

func (e AVPlayerTimeControlStatus) String() string

type AVPlayerVideoOutput ¶

type AVPlayerVideoOutput struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayervideooutput

func AVPlayerVideoOutputFromID ¶

func AVPlayerVideoOutputFromID(id objc.ID) *AVPlayerVideoOutput

func (*AVPlayerVideoOutput) CopyTaggedBufferGroupForHostTimePresentationTimeStampActiveConfiguration ¶

func (o *AVPlayerVideoOutput) CopyTaggedBufferGroupForHostTimePresentationTimeStampActiveConfiguration(hostTime coremedia.CMTime, presentationTimeStampOut *coremedia.CMTime, activeConfigurationOut *AVPlayerVideoOutputConfiguration) unsafe.Pointer

@method copyTaggedBufferGroupForHostTime:presentationTimeStamp:activeConfiguration @abstract Retrieves a tagged buffer group that is appropriate for display at the specified host time. @param hostTime A CMTime that expresses a desired host time. @param presentationTimeStamp On return points to a CMTime whose value is the presentation time in terms of the corresponding AVPlayerItem's timebase for the copied tagged buffer group, or kCMTimeInvalid if no sample is available for the provided hostTime. Note: This timestamp is in terms of the timebase of the AVPlayerItem for which this sample is associated. @param activeConfiguration On return points to the active configuration associated with the copied tagged buffer group, or nil, if no sample is available for the provided hostTime. @result A tagged buffer group for the specified host time if a sample is available, and NULL otherwise. @discussion The client is responsible for releasing the returned CMTaggedBufferGroup.

func (*AVPlayerVideoOutput) InitWithSpecification ¶

func (o *AVPlayerVideoOutput) InitWithSpecification(specification *AVVideoOutputSpecification) *AVPlayerVideoOutput

@method initWithSpecification: @abstract Creates an instance of AVPlayerVideoOutput, initialized with the specified video output specification. @param specification An instance of AVVideoOutputSpecification, used to recommend data channels to the AVPlayer associated with this AVPlayerVideoOutput. The tag collections owned by the AVVideoOutputSpecification will be given a priority based on their position in the array which they are held by AVVideoOutputSpecification, meaning position i takes priority over position i+1. This means that the player will first check if the tag collection at index 0 matches the shape of the current item's data channels. If the item's data channels would not be able satisfy the shape of the requested tag collection, it will fall back to the next collection and repeat this process. This continues until a tag collection or set of tag collection can be selected, otherwise if no collections match the shape of the item’s data channels then samples cannot be vended for that item. @result An instance of AVPlayerVideoOutput. @discussion Output settings will be selected from the input AVVideoOutputSpecification based on the data channels selected for an item. If no output settings were set for the selected tag collection, then the default output settings from the AVVideoOutputSpecification will be used if those were set.

type AVPlayerVideoOutputConfiguration ¶

type AVPlayerVideoOutputConfiguration struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avplayervideooutputconfiguration

func AVPlayerVideoOutputConfigurationFromID ¶

func AVPlayerVideoOutputConfigurationFromID(id objc.ID) *AVPlayerVideoOutputConfiguration

func (*AVPlayerVideoOutputConfiguration) ActivationTime ¶

@property activationTime @abstract Host time when this configuration became active on the player the vending output is attached to.

func (*AVPlayerVideoOutputConfiguration) DataChannelDescriptions ¶

func (o *AVPlayerVideoOutputConfiguration) DataChannelDescriptions() *foundation.NSArray[objc.ID]

@property dataChannelDescriptions @abstract List of data channels, represented as CMTagCollections, selected for this configuration. @discussion Returns an Array of CMTagCollections

func (*AVPlayerVideoOutputConfiguration) PreferredTransform ¶

@property preferredTransform @abstract The preferred transformation of the visual media data vended with this configuration. This transformation is acquired from the AVAssetTrack that was used to source the media data accompanying this configuration. @discussion If no transform was specified by the source track a default value of CGAffineTransformIdentity is returned.

func (*AVPlayerVideoOutputConfiguration) SourcePlayerItem ¶

func (o *AVPlayerVideoOutputConfiguration) SourcePlayerItem() *AVPlayerItem

@property sourcePlayerItem @abstract The AVPlayerItem which is the source of this configuration. @discussion This AVPlayerItem can be seen as the source of all samples this configuration vended alongside.

type AVPortraitEffectsMatte ¶

type AVPortraitEffectsMatte struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avportraiteffectsmatte

func AVPortraitEffectsMatteFromID ¶

func AVPortraitEffectsMatteFromID(id objc.ID) *AVPortraitEffectsMatte

func AVPortraitEffectsMattePortraitEffectsMatteFromDictionaryRepresentationError ¶

func AVPortraitEffectsMattePortraitEffectsMatteFromDictionaryRepresentationError(imageSourceAuxDataInfoDictionary *foundation.NSDictionary[objc.ID, objc.ID]) (*AVPortraitEffectsMatte, error)

@method portraitEffectsMatteFromDictionaryRepresentation:error: @abstract Returns an AVPortraitEffectsMatte instance from auxiliary image information in an image file. @param imageSourceAuxDataInfoDictionary A dictionary of primitive portrait effects matte related information obtained from CGImageSourceCopyAuxiliaryDataInfoAtIndex. @param outError On return, if the portrait effects matte cannot be created, points to an NSError describing the problem. @result An AVPortraitEffectsMatte instance, or nil if the auxiliary data info dictionary was malformed. @discussion When using ImageIO framework's CGImageSource API to read from a HEIF or JPEG file containing a portrait effects matte, AVPortraitEffectsMatte can be instantiated using the result of CGImageSourceCopyAuxiliaryDataInfoAtIndex, which returns a CFDictionary of primitive map information.

func (*AVPortraitEffectsMatte) DictionaryRepresentationForAuxiliaryDataType ¶

func (o *AVPortraitEffectsMatte) DictionaryRepresentationForAuxiliaryDataType(outAuxDataType *foundation.NSString) *foundation.NSDictionary[objc.ID, objc.ID]

@method dictionaryRepresentationForAuxiliaryDataType: @abstract Returns a dictionary of primitive map information to be used when writing an image file with a portrait effects matte. @param outAuxDataType On output, the auxiliary data type to be used when calling CGImageDestinationAddAuxiliaryDataInfo. Currently the only supported auxiliary data type is kCGImageAuxiliaryDataTypePortraitEffectsMatte. @result A dictionary of CGImageDestination compatible portrait effects matte information, or nil if the auxDataType is unsupported. @discussion When using ImageIO framework's CGImageDestination API to write portrait effects matte information to a HEIF or JPEG file, you may use this method to generate a dictionary of primitive map information consumed by CGImageDestinationAddAuxiliaryDataInfo.

func (*AVPortraitEffectsMatte) MattingImage ¶

func (o *AVPortraitEffectsMatte) MattingImage() unsafe.Pointer

@property mattingImage @abstract Provides access to the portrait effects matte's internal image. @discussion The pixel format can be queried using the pixelFormatType property.

func (*AVPortraitEffectsMatte) PixelFormatType ¶

func (o *AVPortraitEffectsMatte) PixelFormatType() uint

@property pixelFormatType @abstract Specifies the pixel format type of this object's internal matting image. @discussion Currently the only supported CV pixel format type for the matting image is kCVPixelFormatType_OneComponent8.

func (*AVPortraitEffectsMatte) PortraitEffectsMatteByApplyingExifOrientation ¶

func (o *AVPortraitEffectsMatte) PortraitEffectsMatteByApplyingExifOrientation(exifOrientation imageio.CGImagePropertyOrientation) *AVPortraitEffectsMatte

@method portraitEffectsMatteByApplyingExifOrientation: @abstract Returns a derivative AVPortraitEffectsMatte instance in which the specified Exif orientation has been applied. @param exifOrientation One of the 8 standard Exif orientation tags expressing how the portrait effects matte should be rotated / mirrored. @result An AVPortraitEffectsMatte instance. @discussion When applying simple 90 degree rotation or mirroring edits to media containing a portrait effects matte, you may use this initializer to create a derivative copy of the portrait effects matte in which the specified orientation is applied. This method throws an NSInvalidArgumentException if you pass an unrecognized exifOrientation.

func (*AVPortraitEffectsMatte) PortraitEffectsMatteByReplacingPortraitEffectsMatteWithPixelBufferError ¶

func (o *AVPortraitEffectsMatte) PortraitEffectsMatteByReplacingPortraitEffectsMatteWithPixelBufferError(pixelBuffer unsafe.Pointer) (*AVPortraitEffectsMatte, error)

@method portraitEffectsMatteByReplacingPortraitEffectsMatteWithPixelBuffer:error: @abstract Returns an AVPortraitEffectsMatte instance wrapping the replacement pixel buffer. @param pixelBuffer A pixel buffer containing a portrait effects matting image, represented as kCVPixelFormatType_OneComponent8 with a kCVImageBufferTransferFunction_Linear transfer function. @param outError On return, if the AVPortraitEffectsMatte cannot be created, points to an NSError describing the problem. @result An AVPortraitEffectsMatte instance, or nil if the pixel buffer is malformed. @discussion When applying complex edits to media containing a portrait effects matte, you may create a derivative matte with arbitrary transforms applied to it, then use this initializer to create a new AVPortraitEffectsMatte.

type AVQueuePlayer ¶

type AVQueuePlayer struct {
	AVPlayer
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avqueueplayer

func AVQueuePlayerFromID ¶

func AVQueuePlayerFromID(id objc.ID) *AVQueuePlayer

func AVQueuePlayerQueuePlayerWithItems ¶

func AVQueuePlayerQueuePlayerWithItems(items *foundation.NSArray[*AVPlayerItem]) *AVQueuePlayer

Creates an instance of AVQueuePlayer and enqueues the AVPlayerItems from the specified array. - Parameter items: An NSArray of AVPlayerItems with which to populate the player's queue initially. - Returns: An instance of AVQueuePlayer.

func (*AVQueuePlayer) AdvanceToNextItem ¶

func (o *AVQueuePlayer) AdvanceToNextItem()

Ends playback of the current item and initiates playback of the next item in the player's queue. Removes the current item from the play queue.

func (*AVQueuePlayer) CanInsertItemAfterItem ¶

func (o *AVQueuePlayer) CanInsertItemAfterItem(item *AVPlayerItem, afterItem *AVPlayerItem) bool

Tests whether an AVPlayerItem can be inserted into the player's queue. Note that adding the same AVPlayerItem to an AVQueuePlayer at more than one position in the queue is not supported. - Parameter item: The AVPlayerItem to be tested. - Parameter afterItem: The item that the item to be tested is to follow in the queue. Pass nil to test whether the item can be appended to the queue. - Returns: An indication of whether the item can be inserted into the queue after the specified item.

func (*AVQueuePlayer) InitWithItems ¶

func (o *AVQueuePlayer) InitWithItems(items *foundation.NSArray[*AVPlayerItem]) *AVQueuePlayer

Initializes an instance of AVQueuePlayer by enqueueing the AVPlayerItems from the specified array. This method throws an exception if items contains duplicated values or values associated with another AVPlayer. - Parameter items: An NSArray of AVPlayerItems with which to populate the player's queue initially. - Returns: An instance of AVQueuePlayer.

func (*AVQueuePlayer) InsertItemAfterItem ¶

func (o *AVQueuePlayer) InsertItemAfterItem(item *AVPlayerItem, afterItem *AVPlayerItem)

Places an AVPlayerItem after the specified item in the queue. This method throws an exception if item already exists in the queue. - Parameter item: The item to be inserted. - Parameter afterItem: The item that the newly inserted item should follow in the queue. Pass nil to append the item to the queue.

func (*AVQueuePlayer) Items ¶

Provides an array of the currently enqueued items. - Returns: An NSArray containing the enqueued AVPlayerItems.

func (*AVQueuePlayer) RemoveAllItems ¶

func (o *AVQueuePlayer) RemoveAllItems()

Removes all items from the queue. Stops playback by the target.

func (*AVQueuePlayer) RemoveItem ¶

func (o *AVQueuePlayer) RemoveItem(item *AVPlayerItem)

Removes an AVPlayerItem from the queue. If the item to be removed is currently playing, has the same effect as -advanceToNextItem. - Parameter item: The item to be removed.

type AVQueuedSampleBufferRendering ¶

type AVQueuedSampleBufferRendering interface {
}

AVQueuedSampleBufferRendering wraps the ObjC protocol AVQueuedSampleBufferRendering.

type AVQueuedSampleBufferRenderingStatus ¶

type AVQueuedSampleBufferRenderingStatus int64
const (
	AVQueuedSampleBufferRenderingStatusUnknown   AVQueuedSampleBufferRenderingStatus = 0
	AVQueuedSampleBufferRenderingStatusRendering AVQueuedSampleBufferRenderingStatus = 1
	AVQueuedSampleBufferRenderingStatusFailed    AVQueuedSampleBufferRenderingStatus = 2
)

func (AVQueuedSampleBufferRenderingStatus) String ¶

type AVRenderedCaptionImage ¶

type AVRenderedCaptionImage struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avrenderedcaptionimage

func AVRenderedCaptionImageFromID ¶

func AVRenderedCaptionImageFromID(id objc.ID) *AVRenderedCaptionImage

func (*AVRenderedCaptionImage) PixelBuffer ¶

func (o *AVRenderedCaptionImage) PixelBuffer() unsafe.Pointer

@property pixelBuffer @abstract A CVPixelBufferRef that contains pixel data for the rendered caption. @discussion If the client reads a pixelBuffer and wants to use it longer than AVRenderedCaptionImage, it must retain the pixelBuffer. The pixel buffer can be converted to MTLTexture using CVMetalTextureCache. The pixel format is fixed to kCVPixelFormatType_32BGRA defined in <CoreVideo/CVPixelBuffer.h>.

func (*AVRenderedCaptionImage) Position ¶

@property position @abstract A CGPoint that defines the position (in pixels) of the rendered caption image relative to the video frame @discussion To place the caption image correcly, the size of pixel buffer can be extracted from CVPixelBufferGetWidth and CVPixelBufferGetHeight. Origin is assumed at upper-left. So, a caption image is rendered to the right and bottom of the origin point.

type AVRouteDetector ¶

type AVRouteDetector struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avroutedetector

func AVRouteDetectorFromID ¶

func AVRouteDetectorFromID(id objc.ID) *AVRouteDetector

func (*AVRouteDetector) IsRouteDetectionEnabled ¶

func (o *AVRouteDetector) IsRouteDetectionEnabled() bool

@property routeDetectionEnabled @abstract Whether or not route detection is enabled. The default value is NO. @discussion Route detection significantly increases power consumption and must be turned off when it's no longer needed.

func (*AVRouteDetector) MultipleRoutesDetected ¶

func (o *AVRouteDetector) MultipleRoutesDetected() bool

@property multipleRoutesDetected @abstract This property is YES if, in addition to the local playback route, at least one more playback route has been detected. @discussion If multiple route have been detected, AVKit's AVRoutePickerView can be used to allow users to pick from the set of available routes. When the values of this property changes AVRouteDetectorMultipleRoutesDetectedDidChangeNotification is posted.

func (*AVRouteDetector) SetRouteDetectionEnabled ¶

func (o *AVRouteDetector) SetRouteDetectionEnabled(routeDetectionEnabled bool)

type AVSampleBufferAudioRenderer ¶

type AVSampleBufferAudioRenderer struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebufferaudiorenderer

func AVSampleBufferAudioRendererFromID ¶

func AVSampleBufferAudioRendererFromID(id objc.ID) *AVSampleBufferAudioRenderer

func (*AVSampleBufferAudioRenderer) AllowedAudioSpatializationFormats ¶

func (o *AVSampleBufferAudioRenderer) AllowedAudioSpatializationFormats() AVAudioSpatializationFormats

@property allowedAudioSpatializationFormats @abstract Indicates the source audio channel layouts allowed by the receiver for spatialization. @discussion Spatialization uses psychoacoustic methods to create a more immersive audio rendering when the content is played on specialized headphones and speaker arrangements. When an AVSampleBufferAudioRenderer's allowedAudioSpatializationFormats property is set to AVAudioSpatializationFormatMonoAndStereo the AVSampleBufferAudioRenderer will attempt to spatialize content tagged with a stereo channel layout, two-channel content with no layout specified as well as mono. It is considered incorrect to render a binaural recording with spatialization. A binaural recording is captured using two carefully placed microphones at each ear where the intent, when played on headphones, is to reproduce a naturally occurring spatial effect. Content tagged with a binaural channel layout will ignore this property value. When an AVSampleBufferAudioRenderer's allowedAudioSpatializationFormats property is set to AVAudioSpatializationFormatMultichannel the AVSampleBufferAudioRenderer will attempt to spatialize any decodable multichannel layout. Setting this property to AVAudioSpatializationFormatMonoStereoAndMultichannel indicates that the sender allows the AVSampleBufferAudioRenderer to spatialize any decodable mono, stereo or multichannel layout. This property is not observable. The default value for this property is AVAudioSpatializationFormatMultichannel.

func (*AVSampleBufferAudioRenderer) AudioOutputDeviceUniqueID ¶

func (o *AVSampleBufferAudioRenderer) AudioOutputDeviceUniqueID() *foundation.NSString

@property audioOutputDeviceUniqueID @abstract Specifies the unique ID of the Core Audio output device used to play audio. @discussion By default, the value of this property is nil, indicating that the default audio output device is used. Otherwise the value of this property is an NSString containing the unique ID of the Core Audio output device to be used for audio output. Core Audio's kAudioDevicePropertyDeviceUID is a suitable source of audio output device unique IDs. Modifying this property while the timebase's rate is not 0.0 may cause the rate to briefly change to 0.0. On macOS, the audio device clock may be used as the AVSampleBufferRenderSynchronizer's and all attached AVQueuedSampleBufferRendering's timebase's clocks. If the audioOutputDeviceUniqueID is modified, the clocks of all these timebases may also change. If multiple AVSampleBufferAudioRenderers with different values for audioOutputDeviceUniqueID are attached to the same AVSampleBufferRenderSynchronizer, audio may not stay in sync during playback. To avoid this, ensure that all synchronized AVSampleBufferAudioRenderers are using the same audio output device.

func (*AVSampleBufferAudioRenderer) AudioTimePitchAlgorithm ¶

func (o *AVSampleBufferAudioRenderer) AudioTimePitchAlgorithm() *foundation.NSString

@property audioTimePitchAlgorithm @abstract Indicates the processing algorithm used to manage audio pitch at varying rates. @discussion Constants for various time pitch algorithms, e.g. AVAudioTimePitchSpectral, are defined in AVAudioProcessingSettings.h. The default value for applications linked on or after iOS 15.0 or macOS 12.0 is AVAudioTimePitchAlgorithmTimeDomain. For iOS versions prior to 15.0 the default value is AVAudioTimePitchAlgorithmLowQualityZeroLatency. For macOS versions prior to 12.0 the default value is AVAudioTimePitchAlgorithmSpectral. If the timebase's rate is not supported by the audioTimePitchAlgorithm, audio will be muted. Modifying this property while the timebase's rate is not 0.0 may cause the rate to briefly change to 0.0.

func (*AVSampleBufferAudioRenderer) Error ¶

func (*AVSampleBufferAudioRenderer) FlushFromSourceTimeCompletionHandler ¶

func (o *AVSampleBufferAudioRenderer) FlushFromSourceTimeCompletionHandler(time_ coremedia.CMTime, completionHandler func(bool))

@method flushFromSourceTime:completionHandler: @abstract Flushes enqueued sample buffers with presentation time stamps later than or equal to the specified time. @param completionHandler A block that is invoked, possibly asynchronously, after the flush operation completes or fails. @discussion This method can be used to replace media data scheduled to be rendered in the future, without interrupting playback. One example of this is when the data that has already been enqueued is from a sequence of two songs and the second song is swapped for a new song. In this case, this method would be called with the time stamp of the first sample buffer from the second song. After the completion handler is executed with a YES parameter, media data may again be enqueued with timestamps at the specified time. If NO is provided to the completion handler, the flush did not succeed and the set of enqueued sample buffers remains unchanged. A flush can fail becuse the source time was too close to (or earlier than) the current time or because the current configuration of the receiver does not support flushing at a particular time. In these cases, the caller can choose to flush all enqueued media data by invoking the -flush method.

func (*AVSampleBufferAudioRenderer) IsMuted ¶

func (o *AVSampleBufferAudioRenderer) IsMuted() bool

func (*AVSampleBufferAudioRenderer) SetAllowedAudioSpatializationFormats ¶

func (o *AVSampleBufferAudioRenderer) SetAllowedAudioSpatializationFormats(allowedAudioSpatializationFormats AVAudioSpatializationFormats)

func (*AVSampleBufferAudioRenderer) SetAudioOutputDeviceUniqueID ¶

func (o *AVSampleBufferAudioRenderer) SetAudioOutputDeviceUniqueID(audioOutputDeviceUniqueID *foundation.NSString)

func (*AVSampleBufferAudioRenderer) SetAudioTimePitchAlgorithm ¶

func (o *AVSampleBufferAudioRenderer) SetAudioTimePitchAlgorithm(audioTimePitchAlgorithm *foundation.NSString)

func (*AVSampleBufferAudioRenderer) SetMuted ¶

func (o *AVSampleBufferAudioRenderer) SetMuted(muted bool)

func (*AVSampleBufferAudioRenderer) SetVolume ¶

func (o *AVSampleBufferAudioRenderer) SetVolume(volume float32)

func (*AVSampleBufferAudioRenderer) Status ¶

func (*AVSampleBufferAudioRenderer) Volume ¶

type AVSampleBufferDisplayLayer ¶

type AVSampleBufferDisplayLayer struct {
	quartzcore.CALayer
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebufferdisplaylayer

func AVSampleBufferDisplayLayerFromID ¶

func AVSampleBufferDisplayLayerFromID(id objc.ID) *AVSampleBufferDisplayLayer

func (*AVSampleBufferDisplayLayer) ControlTimebase ¶

func (o *AVSampleBufferDisplayLayer) ControlTimebase() unsafe.Pointer

@property controlTimebase @abstract The layer's control timebase, which governs how time stamps are interpreted. @discussion By default, this property is NULL, in which case time stamps will be interpreted according to the host time clock (mach_absolute_time with the appropriate timescale conversion; this is the same as Core Animation's CACurrentMediaTime). With no control timebase, once frames are enqueued, it is not possible to adjust exactly when they are displayed. If a non-NULL control timebase is set, it will be used to interpret time stamps. You can control the timing of frame display by setting the rate and time of the control timebase. If you are synchronizing video to audio, you can use a timebase whose source clock is a CMAudioDeviceClock for the appropriate audio device to prevent drift. Note that prior to OSX 10.10 and iOS 8.0, the control timebase could not be changed after enqueueSampleBuffer: was called. As of OSX 10.10 and iOS 8.0, the control timebase may be changed at any time.

func (*AVSampleBufferDisplayLayer) EnqueueSampleBuffer ¶

func (o *AVSampleBufferDisplayLayer) EnqueueSampleBuffer(sampleBuffer unsafe.Pointer)

@method enqueueSampleBuffer: @abstract Sends a sample buffer for display. @discussion If sampleBuffer has the kCMSampleAttachmentKey_DoNotDisplay attachment set to kCFBooleanTrue, the frame will be decoded but not displayed. Otherwise, if sampleBuffer has the kCMSampleAttachmentKey_DisplayImmediately attachment set to kCFBooleanTrue, the decoded image will be displayed as soon as possible, replacing all previously enqueued images regardless of their timestamps. Otherwise, the decoded image will be displayed at sampleBuffer's output presentation timestamp, as interpreted by the control timebase (or the mach_absolute_time timeline if there is no control timebase). To schedule the removal of previous images at a specific timestamp, enqueue a marker sample buffer containing no samples, with the kCMSampleBufferAttachmentKey_EmptyMedia attachment set to kCFBooleanTrue. IMPORTANT NOTE: attachments with the kCMSampleAttachmentKey_ prefix must be set via CMSampleBufferGetSampleAttachmentsArray and CFDictionarySetValue. Attachments with the kCMSampleBufferAttachmentKey_ prefix must be set via CMSetAttachment. IMPORTANT NOTE: When using CMSampleBuffers that wrap CVPixelBuffer, it is important that such CVPixelBuffers be IOSurface-backed. CoreVideo allocates IOSurface-backed CVPixelBuffers when the pixel buffer attribute dictionary passed to CVPixelBufferPoolCreate contains an entry with key kCVPixelBufferIOSurfacePropertiesKey and value being a dictionary (which can be an empty dictionary). The combination of either a non-NULL controlTimebase or an AVSampleBufferRenderSynchronizer with the use of kCMSampleAttachmentKey_DisplayImmediately as an attachment to the CMSampleBuffers that are enqueued for display is not recommended. Deprecated: Use sampleBufferRenderer's enqueueSampleBuffer: instead

func (*AVSampleBufferDisplayLayer) Error ¶

@property error @abstract If the display layer's status is AVQueuedSampleBufferRenderingStatusFailed, this describes the error that caused the failure. @discussion The value of this property is an NSError that describes what caused the display layer to no longer be able to enqueue sample buffers. If the status is not AVQueuedSampleBufferRenderingStatusFailed, the value of this property is nil. Deprecated: Use sampleBufferRenderer's error instead

func (*AVSampleBufferDisplayLayer) Flush ¶

func (o *AVSampleBufferDisplayLayer) Flush()

@method flush @abstract Instructs the layer to discard pending enqueued sample buffers. @discussion It is not possible to determine which sample buffers have been decoded, so the next frame passed to enqueueSampleBuffer: should be an IDR frame (also known as a key frame or sync sample). Deprecated: Use sampleBufferRenderer's flush instead

func (*AVSampleBufferDisplayLayer) FlushAndRemoveImage ¶

func (o *AVSampleBufferDisplayLayer) FlushAndRemoveImage()

@method flushAndRemoveImage @abstract Instructs the layer to discard pending enqueued sample buffers and remove any currently displayed image. @discussion It is not possible to determine which sample buffers have been decoded, so the next frame passed to enqueueSampleBuffer: should be an IDR frame (also known as a key frame or sync sample). Deprecated: Use sampleBufferRenderer's flushWithRemovalOfDisplayedImage:completionHandler: instead

func (*AVSampleBufferDisplayLayer) HasSufficientMediaDataForReliablePlaybackStart ¶

func (o *AVSampleBufferDisplayLayer) HasSufficientMediaDataForReliablePlaybackStart() bool

@property hasSufficientMediaDataForReliablePlaybackStart @abstract Indicates whether the enqueued media data meets the renderer's preroll level. @discussion Clients should fetch the value of this property to learn if the renderer has had enough media data enqueued to start playback reliably. Starting playback when this property is NO may prevent smooth playback following an immediate start. Deprecated: Use sampleBufferRenderer's hasSufficientMediaDataForReliablePlaybackStart instead

func (*AVSampleBufferDisplayLayer) IsReadyForDisplay ¶

func (o *AVSampleBufferDisplayLayer) IsReadyForDisplay() bool

@property readyForDisplay @abstract Boolean indicating that the first video frame has been made ready for display. @discusssion Use this property as an indicator of when best to show or animate-in an AVSampleBufferDisplayLayer into view. An AVSampleBufferDisplayLayer may be displayed, or made visible, while this property is NO, however the layer will not have any user-visible content until the value becomes YES. Note that if an animation is added to an AVSampleBufferDisplayLayer before it becomes readyForDisplay the video image displayed inside might not animate with the receiver. readyForDisplay will change to NO when the layer can no longer display frames. readyForDisplay will be YES when the first video frame has been made ready for display. This property is not key-value observable. AVSampleBufferDisplayLayerReadyForDisplayDidChangeNotification is posted when this value changes.

func (*AVSampleBufferDisplayLayer) IsReadyForMoreMediaData ¶

func (o *AVSampleBufferDisplayLayer) IsReadyForMoreMediaData() bool

@property readyForMoreMediaData @abstract Indicates the readiness of the layer to accept more sample buffers. @discussion AVSampleBufferDisplayLayer keeps track of the occupancy levels of its internal queues for the benefit of clients that enqueue sample buffers from non-real-time sources -- i.e., clients that can supply sample buffers faster than they are consumed, and so need to decide when to hold back. Clients enqueueing sample buffers from non-real-time sources may hold off from generating or obtaining more sample buffers to enqueue when the value of readyForMoreMediaData is NO. It is safe to call enqueueSampleBuffer: when readyForMoreMediaData is NO, but it is a bad idea to enqueue sample buffers without bound. To help with control of the non-real-time supply of sample buffers, such clients can use -requestMediaDataWhenReadyOnQueue:usingBlock in order to specify a block that the layer should invoke whenever it's ready for sample buffers to be appended. The value of readyForMoreMediaData will often change from NO to YES asynchronously, as previously supplied sample buffers are decoded and displayed. This property is not key value observable. Deprecated: Use sampleBufferRenderer's readyForMoreMediaData instead

func (*AVSampleBufferDisplayLayer) OutputObscuredDueToInsufficientExternalProtection ¶

func (o *AVSampleBufferDisplayLayer) OutputObscuredDueToInsufficientExternalProtection() bool

func (*AVSampleBufferDisplayLayer) PreventsCapture ¶

func (o *AVSampleBufferDisplayLayer) PreventsCapture() bool

func (*AVSampleBufferDisplayLayer) PreventsDisplaySleepDuringVideoPlayback ¶

func (o *AVSampleBufferDisplayLayer) PreventsDisplaySleepDuringVideoPlayback() bool

func (*AVSampleBufferDisplayLayer) RequestMediaDataWhenReadyOnQueueUsing ¶

func (o *AVSampleBufferDisplayLayer) RequestMediaDataWhenReadyOnQueueUsing(queue *foundation.NSObject, block func())

@method requestMediaDataWhenReadyOnQueue:usingBlock: @abstract Instructs the target to invoke a client-supplied block repeatedly, at its convenience, in order to gather sample buffers for display. @discussion The block should enqueue sample buffers to the layer either until the layer's readyForMoreMediaData property becomes NO or until there is no more data to supply. When the layer has decoded enough of the media data it has received that it becomes ready for more media data again, it will invoke the block again in order to obtain more. If this function is called multiple times, only the last call is effective. Call stopRequestingMediaData to cancel this request. Each call to requestMediaDataWhenReadyOnQueue:usingBlock: should be paired with a corresponding call to stopRequestingMediaData:. Releasing the AVSampleBufferDisplayLayer without a call to stopRequestingMediaData will result in undefined behavior. Deprecated: Use sampleBufferRenderer's requestMediaDataWhenReadyOnQueue:usingBlock: instead

func (*AVSampleBufferDisplayLayer) RequiresFlushToResumeDecoding ¶

func (o *AVSampleBufferDisplayLayer) RequiresFlushToResumeDecoding() bool

@property requiresFlushToResumeDecoding @abstract Indicates that the receiver is in a state where it requires a call to -flush to continue decoding frames. @discussion When the application enters a state where use of video decoder resources is not permissible, the value of this property changes to YES along with the display layer's status changing to AVQueuedSampleBufferRenderingStatusFailed. To resume rendering sample buffers using the display layer after this property's value is YES, clients must first reset the display layer's status to AVQueuedSampleBufferRenderingStatusUnknown. This can be achieved by invoking -flush on the display layer. Clients can track changes to this property via AVSampleBufferDisplayLayerRequiresFlushToResumeDecodingDidChangeNotification. This property is not key value observable. Deprecated: Use sampleBufferRenderer's requiresFlushToResumeDecoding instead

func (*AVSampleBufferDisplayLayer) SampleBufferRenderer ¶

func (o *AVSampleBufferDisplayLayer) SampleBufferRenderer() *AVSampleBufferVideoRenderer

func (*AVSampleBufferDisplayLayer) SetControlTimebase ¶

func (o *AVSampleBufferDisplayLayer) SetControlTimebase(controlTimebase unsafe.Pointer)

func (*AVSampleBufferDisplayLayer) SetPreventsCapture ¶

func (o *AVSampleBufferDisplayLayer) SetPreventsCapture(preventsCapture bool)

func (*AVSampleBufferDisplayLayer) SetPreventsDisplaySleepDuringVideoPlayback ¶

func (o *AVSampleBufferDisplayLayer) SetPreventsDisplaySleepDuringVideoPlayback(preventsDisplaySleepDuringVideoPlayback bool)

func (*AVSampleBufferDisplayLayer) SetVideoGravity ¶

func (o *AVSampleBufferDisplayLayer) SetVideoGravity(videoGravity *foundation.NSString)

func (*AVSampleBufferDisplayLayer) Status ¶

@property status @abstract The ability of the display layer to be used for enqueuing sample buffers. @discussion The value of this property is an AVQueuedSampleBufferRenderingStatus that indicates whether the receiver can be used for enqueuing and rendering sample buffers. When the value of this property is AVQueuedSampleBufferRenderingStatusFailed, clients can check the value of the error property to determine the failure. To resume rendering sample buffers using the display layer after a failure, clients must first reset the status to AVQueuedSampleBufferRenderingStatusUnknown. This can be achieved by invoking -flush on the display layer. This property is key value observable. Deprecated: Use sampleBufferRenderer's status instead

func (*AVSampleBufferDisplayLayer) StopRequestingMediaData ¶

func (o *AVSampleBufferDisplayLayer) StopRequestingMediaData()

@method stopRequestingMediaData @abstract Cancels any current requestMediaDataWhenReadyOnQueue:usingBlock: call. @discussion This method may be called from outside the block or from within the block. Deprecated: Use sampleBufferRenderer's stopRequestingMediaData instead

func (*AVSampleBufferDisplayLayer) Timebase ¶

@property timebase @abstract The renderer's timebase, which governs how time stamps are interpreted. @discussion The timebase is used to interpret time stamps. The timebase is read-only. Use the AVSampleBufferRenderSynchronizer to set the rate or time. Deprecated: Use sampleBufferRenderer's timebase instead

func (*AVSampleBufferDisplayLayer) VideoGravity ¶

func (o *AVSampleBufferDisplayLayer) VideoGravity() *foundation.NSString

@property videoGravity @abstract A string defining how the video is displayed within an AVSampleBufferDisplayLayer bounds rect. @discusssion Options are AVLayerVideoGravityResizeAspect, AVLayerVideoGravityResizeAspectFill and AVLayerVideoGravityResize. AVLayerVideoGravityResizeAspect is default. See <AVFoundation/AVAnimation.h> for a description of these options.

type AVSampleBufferGenerator ¶

type AVSampleBufferGenerator struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebuffergenerator

func AVSampleBufferGeneratorFromID ¶

func AVSampleBufferGeneratorFromID(id objc.ID) *AVSampleBufferGenerator

func (*AVSampleBufferGenerator) CreateSampleBufferForRequest deprecated

func (o *AVSampleBufferGenerator) CreateSampleBufferForRequest(request *AVSampleBufferRequest) unsafe.Pointer

Deprecated: Use -createSampleBufferForRequest: error:, passing NULL for the error if not required

func (*AVSampleBufferGenerator) CreateSampleBufferForRequestAddingToBatchError ¶

func (o *AVSampleBufferGenerator) CreateSampleBufferForRequestAddingToBatchError(request *AVSampleBufferRequest, batch *AVSampleBufferGeneratorBatch) (unsafe.Pointer, error)

@method createSampleBufferForRequest: addingToBatch: error: @abstract Creates a sample buffer and attempts to defer I/O for its data. Attempt may fail based on generator configuration or file format. The [AVSampleBufferGeneratorBatch makeDataReadyWithCompletionHandler:] should be called once to commence I/O and load sample data for all CMSampleBuffers within a batch. Any subsequent calls to createSampleBufferForRequest:addingToBatch:error: will throw an exception. @param request An instance of AVSampleBufferRequest representing the CMSampleBuffer creation request @param batch An instance of AVSampleBufferGeneratorBatch to contain the output sample buffer. If nil, an exception is thrown. Must be created by calling makeBatch on the same instance of AVSampleBufferGenerator. An exception will be thrown otherwise. @param outError A pointer to an NSError object that will be populated with failure information, if sample buffer creation fails. @result A CMSampleBuffer object referencing the output sample buffer. The generator may defer I/O to fetch sample data depending on the source of the sample data and the generator's timebase.

func (*AVSampleBufferGenerator) CreateSampleBufferForRequestError ¶

func (o *AVSampleBufferGenerator) CreateSampleBufferForRequestError(request *AVSampleBufferRequest) (unsafe.Pointer, error)

@method createSampleBufferForRequest: error: @abstract Creates a sample buffer and if requested, attempts to load its data asynchronously. Attempt may fail based on generator configuration or file format. See [AVSampleBufferGenerator notifyOfDataReadyForSampleBuffer: completionHandler:] to get notified when the sample buffer data is available. @param request An instance of AVSampleBufferRequest representing the CMSampleBuffer creation request. @param outError A pointer to an NSError object that will be populated with failure information, if sample buffer creation fails. @result A CMSampleBuffer object referencing the output sample buffer. @discussion If the AVSampleBufferGenerator was created with a NULL timebase, any associated AVSampleBufferRequest will default to using AVSampleBufferRequestModeImmediate.

func (*AVSampleBufferGenerator) InitWithAssetTimebase ¶

func (o *AVSampleBufferGenerator) InitWithAssetTimebase(asset *AVAsset, timebase unsafe.Pointer) *AVSampleBufferGenerator

@method initWithAsset: timebase: @abstract Creates an instance of AVSampleBufferGenerator to generate sample buffers from the specified asset. @param asset The asset from which sample buffers will be created. @param timebase The generator timebase, which governs when sample data for sample buffers is loaded. If NULL, sample data is loaded synchronously. @result An instance of AVSampleBufferGenerator. @discussion If the specified asset is an HTTP Live Streaming asset, the generator cannot create sample buffers.

func (*AVSampleBufferGenerator) MakeBatch ¶

@method makeBatch @abstract Creates a batch to handle multiple sample buffers, allowing to asynchronously load sample data and optimize I/O when possible. @result An instance of an AVSampleBufferGeneratorBatch that can be used in calls to createSampleBufferForRequest:addingToBatch:error: of the same AVSampleBufferGenerator instance.

type AVSampleBufferGeneratorBatch ¶

type AVSampleBufferGeneratorBatch struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebuffergeneratorbatch

func AVSampleBufferGeneratorBatchFromID ¶

func AVSampleBufferGeneratorBatchFromID(id objc.ID) *AVSampleBufferGeneratorBatch

func (*AVSampleBufferGeneratorBatch) Cancel ¶

func (o *AVSampleBufferGeneratorBatch) Cancel()

@method cancel @abstract Attempt to cancel any I/O for this batch. The associated sample buffers will have their data ready handler invoked with an error.

func (*AVSampleBufferGeneratorBatch) MakeDataReadyWithCompletionHandler ¶

func (o *AVSampleBufferGeneratorBatch) MakeDataReadyWithCompletionHandler(completionHandler func(unsafe.Pointer))

@method makeDataReadyWithCompletionHandler: @abstract Loads sample data asynchronously for all CMSampleBuffers within a batch. This can only be called once on a batch, an exception will be thrown otherwise. @param completionHandler The completionHandler is called once, when all CMSampleBuffers in the batch are data-ready, or as soon as an error has occurred.

type AVSampleBufferRenderSynchronizer ¶

type AVSampleBufferRenderSynchronizer struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebufferrendersynchronizer

func AVSampleBufferRenderSynchronizerFromID ¶

func AVSampleBufferRenderSynchronizerFromID(id objc.ID) *AVSampleBufferRenderSynchronizer

func (*AVSampleBufferRenderSynchronizer) AddBoundaryTimeObserverForTimesQueueUsing ¶

func (o *AVSampleBufferRenderSynchronizer) AddBoundaryTimeObserverForTimesQueueUsing(times *foundation.NSArray[*foundation.NSValue], queue *foundation.NSObject, block func()) objc.ID

Requests invocation of a block when specified times are traversed during normal rendering. Each call to -addPeriodicTimeObserverForInterval:queue:usingBlock: should be paired with a corresponding call to -removeTimeObserver:. Releasing the observer object without a call to -removeTimeObserver: will result in undefined behavior. - Parameter times: The times for which the observer requests notification, supplied as an array of NSValues carrying CMTimes. - Parameter queue: The serial queue onto which block should be enqueued. If you pass NULL, the main queue (obtained using dispatch_get_main_queue()) will be used. Passing a concurrent queue to this method will result in undefined behavior. - Parameter block: The block to be invoked when any of the specified times is crossed during normal rendering. - Returns: An object conforming to the NSObject protocol. You must retain this returned value as long as you want the time observer to be invoked by the synchronizer. Pass this object to -removeTimeObserver: to cancel time observation.

func (*AVSampleBufferRenderSynchronizer) AddPeriodicTimeObserverForIntervalQueueUsing ¶

func (o *AVSampleBufferRenderSynchronizer) AddPeriodicTimeObserverForIntervalQueueUsing(interval coremedia.CMTime, queue *foundation.NSObject, block objc.Block) objc.ID

Requests invocation of a block during rendering to report changing time. The block is invoked periodically at the interval specified, interpreted according to the timeline of the timebase. The block is also invoked whenever time jumps and whenever rendering starts or stops. If the interval corresponds to a very short interval in real time, the synchronizer may invoke the block less frequently than requested. Even so, the synchronizer will invoke the block sufficiently often for the client to update indications of the current time appropriately in its end-user interface. Each call to -addPeriodicTimeObserverForInterval:queue:usingBlock: should be paired with a corresponding call to -removeTimeObserver:. Releasing the observer object without a call to -removeTimeObserver: will result in undefined behavior. - Parameter interval: The interval of invocation of the block during normal rendering, according to progress of the current time of the timebase. - Parameter queue: The serial queue onto which block should be enqueued. If you pass NULL, the main queue (obtained using dispatch_get_main_queue()) will be used. Passing a concurrent queue to this method will result in undefined behavior. - Parameter block: The block to be invoked periodically. - Returns: An object conforming to the NSObject protocol. You must retain this returned value as long as you want the time observer to be invoked by the synchronizer. Pass this object to -removeTimeObserver: to cancel time observation.

func (*AVSampleBufferRenderSynchronizer) AddRenderer ¶

Adds a renderer to the list of renderers under the synchronizer's control. Adds a renderer to begin operating with the synchronizer's timebase. This method can be called while rate is non-0.0. - Parameter renderer: An object conforming to AVQueuedSampleBufferRendering to be synchronized by this synchronizer.

func (*AVSampleBufferRenderSynchronizer) CurrentTime ¶

Returns the current time of the synchronizer. Returns the current time of the synchronizer. Not key-value observable; use -addPeriodicTimeObserverForInterval:queue:usingBlock: instead. - Returns: A CMTime

func (*AVSampleBufferRenderSynchronizer) DelaysRateChangeUntilHasSufficientMediaData ¶

func (o *AVSampleBufferRenderSynchronizer) DelaysRateChangeUntilHasSufficientMediaData() bool

Indicates whether the playback should be started immediately on rate change request. If set to YES, playback will be delayed if the value of hasSufficientMediaDataForReliablePlaybackStart of any added renderer is NO. If set to NO, playback will attempt to start immediately regardless of the value of hasSufficientMediaDataForReliablePlaybackStart of added renderers. Default is YES.

func (*AVSampleBufferRenderSynchronizer) IntendedSpatialAudioExperience ¶

func (o *AVSampleBufferRenderSynchronizer) IntendedSpatialAudioExperience() unsafe.Pointer

func (*AVSampleBufferRenderSynchronizer) Rate ¶

Playback rate. Indicates the current rate of rendering. A value of 0.0 means "stopped"; a value of 1.0 means "play at the natural rate of the media". Must be greater than or equal to 0.0.

func (*AVSampleBufferRenderSynchronizer) RemoveRendererAtTimeCompletionHandler ¶

func (o *AVSampleBufferRenderSynchronizer) RemoveRendererAtTimeCompletionHandler(renderer AVQueuedSampleBufferRendering, time_ coremedia.CMTime, completionHandler func(bool))

Removes a renderer from the list of renderers under the synchronizer's control. This method can be called while rate is non-0.0. time is used to schedule future removals. If the time is in the past, the renderer will be removed immediately. kCMTimeInvalid can also be used to force immediate removal. This method removes the renderer asynchronously. The method can be called more than once, with a subsequent scheduled removal replacing a previously scheduled removal. Clients may provide an optional completionHandler block to be notified when the scheduled removal completes. If provided, completionHandler will always be called with the following values for didRemoveRenderer: - If the renderer has not been added to this synchronizer, completionHandler will be called and didRemoveRenderer will be NO. - If a removal of a particular renderer is scheduled after another removal of that same renderer has already been scheduled but not yet occurred, the previously-scheduled removal's completionHandler will be called and didRemoveRenderer will be NO. The new scheduled removal's completionHandler will not be called until it is replaced by another scheduled removal or the renderer is actually removed. - When the renderer is removed due to a scheduled removal, the completionHandler provided when that removal was scheduled will be called and didRemoveRenderer will be YES. - Parameter renderer: An object conforming to AVQueuedSampleBufferRendering currently synchronized by this synchronizer to no longer be synchronized by the synchronizer. - Parameter time: The time on the timebase's timeline at which the renderer should be removed. - Parameter completionHandler: Optional. A block called when the renderer is removed from the synchronizer. If provided, this block will always be called with didRemoveRenderer indicating whether the renderer was removed by this scheduled removal.

func (*AVSampleBufferRenderSynchronizer) RemoveTimeObserver ¶

func (o *AVSampleBufferRenderSynchronizer) RemoveTimeObserver(observer objc.ID)

Cancels a previously registered time observer. Upon return, the caller is guaranteed that no new time observer blocks will begin executing. Depending on the calling thread and the queue used to add the time observer, an in-flight block may continue to execute after this method returns. You can guarantee synchronous time observer removal by enqueuing the call to -removeTimeObserver: on that queue. Alternatively, call dispatch_sync(queue, ^{}) after -removeTimeObserver: to wait for any in-flight blocks to finish executing. -removeTimeObserver: should be used to explicitly cancel each time observer added using -addPeriodicTimeObserverForInterval:queue:usingBlock: and -addBoundaryTimeObserverForTimes:queue:usingBlock:. This method throws an exception for any of the following reasons: - observer was added by another AVSampleBufferRenderSynchronizer - observer was not returned by either -addPeriodicTimeObserverForInterval:queue:usingBlock: -addBoundaryTimeObserverForTimes:queue:usingBlock: - Parameter observer: An object returned by a previous call to -addPeriodicTimeObserverForInterval:queue:usingBlock: or -addBoundaryTimeObserverForTimes:queue:usingBlock:.

func (*AVSampleBufferRenderSynchronizer) Renderers ¶

Array of id<AVQueuedSampleBufferRendering> currently attached to the synchronizer. A list of renderers added to and not removed from the synchronizer. The list also includes renderers that have been scheduled to be removed but have not yet been removed. This property is not KVO observable.

func (*AVSampleBufferRenderSynchronizer) SetDelaysRateChangeUntilHasSufficientMediaData ¶

func (o *AVSampleBufferRenderSynchronizer) SetDelaysRateChangeUntilHasSufficientMediaData(delaysRateChangeUntilHasSufficientMediaData bool)

func (*AVSampleBufferRenderSynchronizer) SetIntendedSpatialAudioExperience ¶

func (o *AVSampleBufferRenderSynchronizer) SetIntendedSpatialAudioExperience(intendedSpatialAudioExperience unsafe.Pointer)

func (*AVSampleBufferRenderSynchronizer) SetRate ¶

func (o *AVSampleBufferRenderSynchronizer) SetRate(rate float32)

func (*AVSampleBufferRenderSynchronizer) SetRateTime ¶

func (o *AVSampleBufferRenderSynchronizer) SetRateTime(rate float32, time_ coremedia.CMTime)

Sets the timebase's time and rate. Sets the timebase's time to time and then sets the rendering rate to rate. A rate value of 0.0 means "stopped"; a rate value of 1.0 means "play at the natural rate of the media". Use kCMTimeInvalid for time to not modify the timebase's time. Note that this method updates the rate property synchronously, but the timebase is updated asynchronously. - Parameter rate: A new timebase rate to set. Must be greater than or equal to 0.0 - Parameter time: A new time to set. Must be greater than or equal to kCMTimeZero, or kCMTimeInvalid

func (*AVSampleBufferRenderSynchronizer) SetRateTimeAtHostTime ¶

func (o *AVSampleBufferRenderSynchronizer) SetRateTimeAtHostTime(rate float32, time_ coremedia.CMTime, hostTime coremedia.CMTime)

Simultaneously sets the playback rate and the relationship between the current time and host time. You can use this function to synchronize playback with an external activity. The timebase is adjusted so that its time will be (or was) time when host time is (or was) hostTime. In other words: if hostTime is in the past, the timebase's time will be interpolated as though the timebase has been running at the requested rate since that time. If hostTime is in the future, the timebase will immediately start running at the requested rate from an earlier time so that it will reach the requested time at the requested hostTime. It is a responsibility of the client to ensure that proper time and hostTime is set. This method will not attempt to validate improper time, hostTime values. In addition, it is also the caller’s responsibility to enqueue samples in the connected renderers that match the timeline defined here. Note that any buffers that are in the past of the defined timeline will still be processed by the renderers. The recommended approach is to use the output presentation time of the first buffer enqueued in the renderers as time and and an associated hostTime in the future. Example use: ```objc CMTime startTime = …; __block CMTime nextBufferTime = startTime; [renderer requestMediaDataWhenReadyOnQueue:queue usingBlock:^{ … CMSampleBufferRef sampleBuffer = [self generateSampleBufferFor: nextBufferTime]; [renderer enqueueSampleBuffer:sampleBuffer]; ... }]; CMTime inOneSecond = CMTimeAdd(CMClockGetTime(CMClockGetHostTimeClock()), CMTimeMake(1, 1)); [synchronizer setRate:rate time:startTime atHostTime:inOneSecond]; ``` Also note that this method updates the rate property synchronously, but the timebase is updated asynchronously. - Parameter rate: A new timebase rate to set. Must be greater than or equal to 0.0 - Parameter time: A new timebase time to set. Must be greater than or equal to kCMTimeZero, or kCMTimeInvalid - Parameter hostTime: A new hostTime to set. Must be greater than or equal to kCMTimeZero, or kCMTimeInvalid

func (*AVSampleBufferRenderSynchronizer) Timebase ¶

The synchronizer's rendering timebase, which governs how time stamps are interpreted. By default, this timebase will be driven by the clock of an added AVSampleBufferAudioRenderer. If no AVSampleBufferAudioRenderer has been added, the source clock will be the host time clock (mach_absolute_time with the appropriate timescale conversion; this is the same as Core Animation's CACurrentMediaTime). The timebase is a read-only timebase. Use the rate property and corresponding methods to adjust the timebase.

type AVSampleBufferRequest ¶

type AVSampleBufferRequest struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebufferrequest

func AVSampleBufferRequestFromID ¶

func AVSampleBufferRequestFromID(id objc.ID) *AVSampleBufferRequest

func (*AVSampleBufferRequest) Direction ¶

func (*AVSampleBufferRequest) InitWithStartCursor ¶

func (o *AVSampleBufferRequest) InitWithStartCursor(startCursor *AVSampleCursor) *AVSampleBufferRequest

func (*AVSampleBufferRequest) LimitCursor ¶

func (o *AVSampleBufferRequest) LimitCursor() *AVSampleCursor

func (*AVSampleBufferRequest) MaxSampleCount ¶

func (o *AVSampleBufferRequest) MaxSampleCount() int

func (*AVSampleBufferRequest) Mode ¶

func (*AVSampleBufferRequest) OverrideTime ¶

func (o *AVSampleBufferRequest) OverrideTime() coremedia.CMTime

func (*AVSampleBufferRequest) PreferredMinSampleCount ¶

func (o *AVSampleBufferRequest) PreferredMinSampleCount() int

func (*AVSampleBufferRequest) SetDirection ¶

func (o *AVSampleBufferRequest) SetDirection(direction AVSampleBufferRequestDirection)

func (*AVSampleBufferRequest) SetLimitCursor ¶

func (o *AVSampleBufferRequest) SetLimitCursor(limitCursor *AVSampleCursor)

func (*AVSampleBufferRequest) SetMaxSampleCount ¶

func (o *AVSampleBufferRequest) SetMaxSampleCount(maxSampleCount int)

func (*AVSampleBufferRequest) SetMode ¶

func (*AVSampleBufferRequest) SetOverrideTime ¶

func (o *AVSampleBufferRequest) SetOverrideTime(overrideTime coremedia.CMTime)

func (*AVSampleBufferRequest) SetPreferredMinSampleCount ¶

func (o *AVSampleBufferRequest) SetPreferredMinSampleCount(preferredMinSampleCount int)

func (*AVSampleBufferRequest) StartCursor ¶

func (o *AVSampleBufferRequest) StartCursor() *AVSampleCursor

type AVSampleBufferRequestDirection ¶

type AVSampleBufferRequestDirection int64
const (
	AVSampleBufferRequestDirectionForward AVSampleBufferRequestDirection = 1
	AVSampleBufferRequestDirectionNone    AVSampleBufferRequestDirection = 0
	AVSampleBufferRequestDirectionReverse AVSampleBufferRequestDirection = -1
)

func (AVSampleBufferRequestDirection) String ¶

type AVSampleBufferRequestMode ¶

type AVSampleBufferRequestMode int64
const (
	AVSampleBufferRequestModeImmediate     AVSampleBufferRequestMode = 0
	AVSampleBufferRequestModeScheduled     AVSampleBufferRequestMode = 1
	AVSampleBufferRequestModeOpportunistic AVSampleBufferRequestMode = 2
)

func (AVSampleBufferRequestMode) String ¶

func (e AVSampleBufferRequestMode) String() string

type AVSampleBufferVideoRenderer ¶

type AVSampleBufferVideoRenderer struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplebuffervideorenderer

func AVSampleBufferVideoRendererFromID ¶

func AVSampleBufferVideoRendererFromID(id objc.ID) *AVSampleBufferVideoRenderer

func (*AVSampleBufferVideoRenderer) CopyDisplayedPixelBuffer ¶

func (o *AVSampleBufferVideoRenderer) CopyDisplayedPixelBuffer() unsafe.Pointer

@method copyDisplayedPixelBuffer @abstract Returns a retained reference to the pixel buffer currently displayed in the AVSampleBufferVideoRenderer's target. This will return NULL if the displayed pixel buffer is protected, no image is currently being displayed, or if the image is unavailable. @discussion This will return NULL if the rate is non-zero. Clients must release the pixel buffer after use. Do not write to the returned CVPixelBuffer's attachments or pixel data.

func (*AVSampleBufferVideoRenderer) Error ¶

@property error @abstract If the video renderer's status is AVQueuedSampleBufferRenderingStatusFailed, this describes the error that caused the failure. @discussion The value of this property is an NSError that describes what caused the video renderer to no longer be able to enqueue sample buffers. If the status is not AVQueuedSampleBufferRenderingStatusFailed, the value of this property is nil.

func (*AVSampleBufferVideoRenderer) ExpectMinimumUpcomingSampleBufferPresentationTime ¶

func (o *AVSampleBufferVideoRenderer) ExpectMinimumUpcomingSampleBufferPresentationTime(minimumUpcomingPresentationTime coremedia.CMTime)

@method expectMinimumUpcomingSampleBufferPresentationTime: @abstract Promises, for the purpose of enabling power optimizations, that future sample buffers will have PTS values no less than a specified lower-bound PTS. @discussion Only applicable for forward playback. Sending this message and later calling -enqueueSampleBuffer: with a buffer with a lower PTS has the potential to lead to dropping that later buffer. For best results, call -expectMinimumUpcomingSampleBufferPresentationTime: regularly, in between calls to -enqueueSampleBuffer:, to advance the lower-bound PTS. Messaging -flush resets such expectations. (For example, it's OK to make this expectation, then in response to a seek back, flush and then enqueue buffers with lower PTS values.) @param minimumUpcomingPresentationTime A lower bound on PTS values for buffers that will be passed to -enqueueSampleBuffer: in the future.

func (*AVSampleBufferVideoRenderer) ExpectMonotonicallyIncreasingUpcomingSampleBufferPresentationTimes ¶

func (o *AVSampleBufferVideoRenderer) ExpectMonotonicallyIncreasingUpcomingSampleBufferPresentationTimes()

@method expectMonotonicallyIncreasingUpcomingSampleBufferPresentationTimes @abstract Promises, for the purpose of enabling power optimizations, that future sample buffers will have monotonically increasing PTS values. @discussion Only applicable for forward playback. Sending this message and later calling -enqueueSampleBuffer: with a buffer with a lower PTS than any previously enqueued PTS has the potential to lead to dropped buffers. Messaging -flush resets such expectations.

func (*AVSampleBufferVideoRenderer) FlushWithRemovalOfDisplayedImageCompletionHandler ¶

func (o *AVSampleBufferVideoRenderer) FlushWithRemovalOfDisplayedImageCompletionHandler(removeDisplayedImage bool, handler func())

func (*AVSampleBufferVideoRenderer) LoadVideoPerformanceMetricsWithCompletionHandler ¶

func (o *AVSampleBufferVideoRenderer) LoadVideoPerformanceMetricsWithCompletionHandler(completionHandler func(unsafe.Pointer))

@method loadVideoPerformanceMetricsWithCompletionHandler: @abstract Gathers a snapshot of the video performance metrics and calls the completion handler with the results. @param completionHandler The handler to invoke with the video performance metrics. @discussion If there are no performance metrics available, the completion handler will be called with nil videoPerformanceMetrics.

func (*AVSampleBufferVideoRenderer) RecommendedPixelBufferAttributes ¶

func (o *AVSampleBufferVideoRenderer) RecommendedPixelBufferAttributes() *foundation.NSDictionary[*foundation.NSString, objc.ID]

func (*AVSampleBufferVideoRenderer) RequiresFlushToResumeDecoding ¶

func (o *AVSampleBufferVideoRenderer) RequiresFlushToResumeDecoding() bool

@property requiresFlushToResumeDecoding @abstract Indicates that the receiver is in a state where it requires a call to -flush to continue decoding frames. @discussion When the application enters a state where use of video decoder resources is not permissible, the value of this property changes to YES along with the video renderer's status changing to AVQueuedSampleBufferRenderingStatusFailed. To resume rendering sample buffers using the video renderer after this property's value is YES, clients must first reset the video renderer by calling flush or flushWithRemovalOfDisplayedImage:completionHandler:. Clients can track changes to this property via AVSampleBufferVideoRendererRequiresFlushToResumeDecodingDidChangeNotification. This property is not key value observable.

func (*AVSampleBufferVideoRenderer) ResetUpcomingSampleBufferPresentationTimeExpectations ¶

func (o *AVSampleBufferVideoRenderer) ResetUpcomingSampleBufferPresentationTimeExpectations()

@method resetUpcomingSampleBufferPresentationTimeExpectations: @abstract Resets previously-promised expectations about upcoming sample buffer PTSs. @discussion This undoes the state set by messaging -expectMinimumUpcomingSampleBufferPresentationTime: or -expectMonotonicallyIncreasingUpcomingSampleBufferPresentationTimes. If you didn't use either of those, you don't have to use this.

func (*AVSampleBufferVideoRenderer) Status ¶

@property status @abstract The ability of the video renderer to be used for enqueueing sample buffers. @discussion The value of this property is an AVQueuedSampleBufferRenderingStatus that indicates whether the receiver can be used for enqueueing and rendering sample buffers. When the value of this property is AVQueuedSampleBufferRenderingStatusFailed, clients can check the value of the error property to determine the failure. To resume rendering sample buffers using the video renderer after a failure, clients must first reset the status to AVQueuedSampleBufferRenderingStatusUnknown. This can be achieved by invoking -flush on the video renderer. This property is key value observable.

type AVSampleCursor ¶

type AVSampleCursor struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsamplecursor

func AVSampleCursorFromID ¶

func AVSampleCursorFromID(id objc.ID) *AVSampleCursor

func (*AVSampleCursor) ComparePositionInDecodeOrderWithPositionOfCursor ¶

func (o *AVSampleCursor) ComparePositionInDecodeOrderWithPositionOfCursor(cursor *AVSampleCursor) foundation.NSComparisonResult

@method comparePositionInDecodeOrderWithPositionOfCursor: @abstract Compares the relative positions of two AVSampleCursors. @param cursor An instance of AVSampleCursor with which to compare positions. @result kCFCompareLessThan, kCFCompareEqualTo or kCFCompareGreaterThan, depending on whether the receiver points at a sample before, the same as, or after the sample pointed to by the specified AVSampleCursor. @discussion If the receiver and cursor reference different sequences of samples, as when they're created by different instances of AVAssetTrack, results are undefined.

func (*AVSampleCursor) CopyCurrentSampleFormatDescription ¶

func (o *AVSampleCursor) CopyCurrentSampleFormatDescription() unsafe.Pointer

@method copyCurrentSampleFormatDescription: @abstract Provides the format description of the sample at the receiver's current position.

func (*AVSampleCursor) CurrentChunkInfo ¶

func (o *AVSampleCursor) CurrentChunkInfo() AVSampleCursorChunkInfo

@property currentChunkInfo @abstract Provides information about the "chunk" of samples to which the current sample belongs. If the media format that defines the sequence of samples does not signal "chunking" of samples in any way, each sample will be considered by the receiver as belonging to a chunk of one sample only.

func (*AVSampleCursor) CurrentChunkStorageRange ¶

func (o *AVSampleCursor) CurrentChunkStorageRange() AVSampleCursorStorageRange

@property currentChunkStorageRange @abstract The offset and length of samples in currentChunkStorageURL that are intended to be loaded together with the current sample as a "chunk". @discussion If the current chunk isn't stored contiguously in its storage container, currentChunkStorageRange.offset will be -1. In such cases you can use AVSampleBufferGenerator to obtain the sample data.

func (*AVSampleCursor) CurrentChunkStorageURL ¶

func (o *AVSampleCursor) CurrentChunkStorageURL() *foundation.NSURL

@property currentChunkStorageURL @abstract The URL of the storage container of the current sample, as well as other samples that are intended to be loaded in the same operation as a "chunk". @discussion May be nil; if nil, the storage location of the chunk is the URL of the sample cursor's track's asset, if it has one.

func (*AVSampleCursor) CurrentSampleAudioDependencyInfo ¶

func (o *AVSampleCursor) CurrentSampleAudioDependencyInfo() AVSampleCursorAudioDependencyInfo

@property currentSampleAudioDependencyInfo @abstract Provides information about the independent decodability of an audio sample. @discussion In order to position a sample cursor at the first sample that the audio decoder requires for a full refresh, you will need to walk it back from the current sample until you find a sample that is independently decodable, and whose audioSamplePacketRefreshCount is greater than or equal to the number of steps back you have taken. This implies that if the current sample (before this walk) is independently decodable, with an audioSampleRefreshCount of zero, no walk is required.

func (*AVSampleCursor) CurrentSampleDependencyAttachments ¶

func (o *AVSampleCursor) CurrentSampleDependencyAttachments() *foundation.NSDictionary[objc.ID, objc.ID]

@property currentSampleDependencyAttachments @abstract Provides a dictionary containing dependency related sample buffer attachments, if known. See kCMSampleAttachmentKey_... in CoreMedia/CMSampleBuffer.h.

func (*AVSampleCursor) CurrentSampleDependencyInfo ¶

func (o *AVSampleCursor) CurrentSampleDependencyInfo() AVSampleCursorDependencyInfo

@property currentSampleDependencyInfo @abstract Provides information about dependencies between a media sample and other media samples in the same sample sequence, if known.

func (*AVSampleCursor) CurrentSampleDuration ¶

func (o *AVSampleCursor) CurrentSampleDuration() coremedia.CMTime

@property currentSampleDuration @abstract Indicates the decode duration of the sample at the receiver's current position. @discussion If the receiver must be advanced past its current position in order to determine the decode duration of the current sample, the value of currentSampleDuration is equal to kCMTimeIndefinite. This can occur with streaming formats such as MPEG-2 transport streams.

func (*AVSampleCursor) CurrentSampleIndexInChunk ¶

func (o *AVSampleCursor) CurrentSampleIndexInChunk() int64

@property currentSampleIndexInChunk @abstract The index of the current sample within the chunk to which it belongs.

func (*AVSampleCursor) CurrentSampleStorageRange ¶

func (o *AVSampleCursor) CurrentSampleStorageRange() AVSampleCursorStorageRange

@property currentSampleStorageRange @abstract The offset and length of the current sample in currentChunkStorageURL. @discussion If the current sample isn't stored contiguously in its storage container, currentSampleStorageRange.offset will be -1. In such cases you can use AVSampleBufferGenerator to obtain the sample data.

func (*AVSampleCursor) CurrentSampleSyncInfo ¶

func (o *AVSampleCursor) CurrentSampleSyncInfo() AVSampleCursorSyncInfo

@property currentSampleSyncInfo @abstract Provides information about the current sample for consideration when resynchronizing a decoder, as when scrubbing.

func (*AVSampleCursor) DecodeTimeStamp ¶

func (o *AVSampleCursor) DecodeTimeStamp() coremedia.CMTime

@property decodeTimeStamp @abstract The decode timestamp (DTS) of the sample at the current position of the cursor.

func (*AVSampleCursor) PresentationTimeStamp ¶

func (o *AVSampleCursor) PresentationTimeStamp() coremedia.CMTime

@property presentationTimeStamp @abstract The presentation timestamp (PTS) of the sample at the current position of the cursor.

func (*AVSampleCursor) SamplesRequiredForDecoderRefresh ¶

func (o *AVSampleCursor) SamplesRequiredForDecoderRefresh() int

@property samplesRequiredForDecoderRefresh @abstract Count of samples prior to the current sample, in decode order, that the decoder requires in order to achieve fully coherent output at the current decode time, as after a seek. Zero will be returned if no samples are required for decoder refresh or if the track does not contain this information. @discussion Some sample sequences that do not indicate sample dependencies may instead indicate that in order for a specific sample to be decoded with all available accuracy, samples prior to that sample in decode order must be decoded before the specific sample is decoded. In order to position a sample cursor at the first sample that the decoder requires for a full refresh, you can use code like the following: NSInteger samplesPriorToCurrentSampleToFeedToDecoder = [mySampleCursor samplesRequiredForDecoderRefresh]; AVSampleCursor *cursorForObtainingRefreshSamples = [mySampleCursor copy]; [cursorForObtainingRefreshSamples stepInDecodeOrderByCount: -samplesPriorToCurrentSampleToFeedToDecoder ]; // cursorForObtainingRefreshSamples is now positioned at the first sample that must be provided to the decoder // in order to decode the sample at the position of mySampleCursor in full

func (*AVSampleCursor) SamplesWithEarlierDecodeTimeStampsMayHaveLaterPresentationTimeStampsThanCursor ¶

func (o *AVSampleCursor) SamplesWithEarlierDecodeTimeStampsMayHaveLaterPresentationTimeStampsThanCursor(cursor *AVSampleCursor) bool

@method samplesWithEarlierDecodeTimeStampsMayHaveLaterPresentationTimeStampsThanCursor: @abstract This method tests a boundary in the reordering from decode order to presentation order, determining whether it's possible for any sample earlier in decode order than the sample at the position of the receiver can have a presentation timestamp later than that of the specified sample cursor. @param cursor An instance of AVSampleCursor with which to test the sample reordering boundary. @result YES if it's possible for any sample earlier in decode order than the sample at the position of the receiver can have a presentation timestamp later than that of the specified sample cursor. @discussion If the receiver and cursor reference different sequences of samples, as when they're created by different instances of AVAssetTrack, results are undefined.

func (*AVSampleCursor) SamplesWithLaterDecodeTimeStampsMayHaveEarlierPresentationTimeStampsThanCursor ¶

func (o *AVSampleCursor) SamplesWithLaterDecodeTimeStampsMayHaveEarlierPresentationTimeStampsThanCursor(cursor *AVSampleCursor) bool

@method samplesWithLaterDecodeTimeStampsMayHaveEarlierPresentationTimeStampsThanCursor: @abstract This method tests a boundary in the reordering from decode order to presentation order, determining whether it's possible for any sample later in decode order than the sample at the position of the receiver can have a presentation timestamp earlier than that of the specified sample cursor. @param cursor An instance of AVSampleCursor with which to test the sample reordering boundary. @result YES if it's possible for any sample later in decode order than the sample at the position of the receiver can have a presentation timestamp earlier than that of the specified sample cursor. @discussion If the receiver and cursor reference different sequences of samples, as when they're created by different instances of AVAssetTrack, results are undefined.

func (*AVSampleCursor) StepByDecodeTimeWasPinned ¶

func (o *AVSampleCursor) StepByDecodeTimeWasPinned(deltaDecodeTime coremedia.CMTime, outWasPinned *bool) coremedia.CMTime

@method stepByDecodeTime:wasPinned: @abstract Moves the cursor by a given deltaTime on the decode timeline. @param deltaDecodeTime The amount of time to move in the decode timeline. @param outWasPinned If the beginning or the end of the sample sequence was reached before the requested deltaDecodeTime was traversed, the BOOL value at the address specified by outWasPinned will be set to YES. May be NULL if this information isn't desired. @result The amount of time the cursor was moved along the decode timeline. Because sample cursors snap to sample boundaries when stepped, this value may not be equal to deltaDecodeTime even if the cursor was not pinned.

func (*AVSampleCursor) StepByPresentationTimeWasPinned ¶

func (o *AVSampleCursor) StepByPresentationTimeWasPinned(deltaPresentationTime coremedia.CMTime, outWasPinned *bool) coremedia.CMTime

@method stepByPresentationTime:wasPinned: @abstract Moves the cursor by a given deltaTime on the presentation timeline. @param deltaPresentationTime The amount of time to move in the presentation timeline. @param outWasPinned If the beginning or the end of the sample sequence was reached before the requested deltaPresentationTime was traversed, the BOOL value at the address specified by outWasPinned will be set to YES. May be NULL if this information isn't desired. @result The amount of time the cursor was moved along the presentation timeline. Because sample cursors snap to sample boundaries when stepped, this value may not be equal to deltaPresentationTime even if the cursor was not pinned.

func (*AVSampleCursor) StepInDecodeOrderByCount ¶

func (o *AVSampleCursor) StepInDecodeOrderByCount(stepCount int64) int64

@method stepInDecodeOrderByCount: @abstract Moves the cursor a given number of samples in decode order. @param stepCount The number of samples to move across. If positive, step forward this many samples. If negative, step backward (-stepCount) samples. @result The number of samples the cursor traversed. If the beginning or the end of the sample sequence was reached before the requested number of samples was traversed, the absolute value of the result will be less than the absolute value of stepCount.

func (*AVSampleCursor) StepInPresentationOrderByCount ¶

func (o *AVSampleCursor) StepInPresentationOrderByCount(stepCount int64) int64

@method stepInPresentationOrderByCount: @abstract Moves the cursor a given number of samples in presentation order. @param stepCount The number of samples to move across. If positive, step forward this many samples. If negative, step backward (-stepCount) samples. @result The number of samples the cursor traversed. If the beginning or the end of the sample sequence was reached before the requested number of samples was traversed, the absolute value of the result will be less than the absolute value of stepCount.

type AVSampleCursorAudioDependencyInfo ¶

type AVSampleCursorAudioDependencyInfo struct {
	AudioSampleIsIndependentlyDecodable bool
	AudioSamplePacketRefreshCount       int
}

@struct AVSampleCursorAudioDependencyInfo @abstract A struct for describing the independent decodability of audio samples @field audioSampleIsIndependentlyDecodable Indicates whether the sample is independently decodable. Will be YES for Immediate Playout Frames (IPFs) and Independent Frames (IFs). @field audioSamplePacketRefreshCount If audioSampleIsIndependentlyDecodable is YES, indicates how many samples, starting at this sample, must be fed to the decoder to achieve full decoder refresh. Will be zero for Immediate Playout Frames (IPFs).

type AVSampleCursorChunkInfo ¶

type AVSampleCursorChunkInfo struct {
	ChunkSampleCount                  int64
	ChunkHasUniformSampleSizes        bool
	ChunkHasUniformSampleDurations    bool
	ChunkHasUniformFormatDescriptions bool
}

@struct AVSampleCursorChunkInfo @abstract Provides information about a chunk of media samples. @field chunkSampleCount The count of media samples in the chunk. @field chunkHasUniformSampleSizes YES if all of the samples in the chunk occupy the same number of bytes in storage. @field currentChunkHasUniformSampleDurations YES if all of the samples in the chunk have the same duration. @field currentChunkHasUniformFormatDescriptions YES if all of the samples in the chunk have the same format description.

type AVSampleCursorDependencyInfo ¶

type AVSampleCursorDependencyInfo struct {
	SampleIndicatesWhetherItHasDependentSamples bool
	SampleHasDependentSamples                   bool
	SampleIndicatesWhetherItDependsOnOthers     bool
	SampleDependsOnOthers                       bool
	SampleIndicatesWhetherItHasRedundantCoding  bool
	SampleHasRedundantCoding                    bool
}

@struct AVSampleCursorDependencyInfo @abstract A struct for describing dependencies between a media sample and other media samples in the same sample sequence. @field sampleIndicatesWhetherItHasDependentSamples Indicates whether the presence or absence of other samples that are dependent on the sample is known. @field sampleHasDependentSamples If sampleIndicatesWhetherItHasDependentSamples is YES, indicates whether the sample has dependent samples. @field sampleIndicatesWhetherItDependsOnOthers Indicates whether the sample's independency from other samples or dependency on other samples is known. @field sampleDependsOnOthers If sampleIndicatesWhetherItDependsOnOthers is YES, indicates whether the sample depends on other media samples. @field sampleIndicatesWhetherItHasRedundantCoding Indicates whether the presence of redundant coding of the sample is known. @field sampleHasRedundantCoding If sampleIndicatesWhetherItHasRedundantCoding is YES, indicates whether the sample has redundant coding.

type AVSampleCursorStorageRange ¶

type AVSampleCursorStorageRange struct {
	Offset int64
	Length int64
}

@struct AVSampleCursorStorageRange @abstract A struct for indicating the offset and length of storage occupied by a media sample or its chunk. @field offset The offset of the first byte of storage occupied by a media sample or its chunk. @field length The count of bytes of storage occupied by a media sample or its chunk. @discussion Like NSRange, but rangier.

type AVSampleCursorSyncInfo ¶

type AVSampleCursorSyncInfo struct {
	SampleIsFullSync    bool
	SampleIsPartialSync bool
	SampleIsDroppable   bool
}

@struct AVSampleCursorSyncInfo @abstract A struct for describing attributes of a media sample for consideration when resynchronizing a decoder. @field sampleIsFullSync Indicates whether the sample is a full sync sample, also known as an Instantaneous Decoder Refresh sample, and is sufficient in itself to completely resynchronize a decoder. @field sampleIsPartialSync Indicates whether the sample is a partial sync sample. @field sampleIsDroppable Indicates whether the sample is droppable.

type AVSemanticSegmentationMatte ¶

type AVSemanticSegmentationMatte struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsemanticsegmentationmatte

func AVSemanticSegmentationMatteFromID ¶

func AVSemanticSegmentationMatteFromID(id objc.ID) *AVSemanticSegmentationMatte

func AVSemanticSegmentationMatteSemanticSegmentationMatteFromImageSourceAuxiliaryDataTypeDictionaryRepresentationError ¶

func AVSemanticSegmentationMatteSemanticSegmentationMatteFromImageSourceAuxiliaryDataTypeDictionaryRepresentationError(imageSourceAuxiliaryDataType unsafe.Pointer, imageSourceAuxiliaryDataInfoDictionary *foundation.NSDictionary[objc.ID, objc.ID]) (*AVSemanticSegmentationMatte, error)

@method semanticSegmentationMatteFromDictionaryRepresentation:error: @abstract Returns an AVSemanticSegmentationMatte instance from auxiliary image information in an image file. @param imageSourceAuxiliaryDataType The kCGImageAuxiliaryDataType constant corresponding to the semantic segmentation matte being created (see <ImageIO/CGImageProperties.h>. @param imageSourceAuxiliaryDataInfoDictionary A dictionary of primitive semantic segmentation matte related information obtained from CGImageSourceCopyAuxiliaryDataInfoAtIndex. @param outError On return, if the semantic segmentation matte cannot be created, points to an NSError describing the problem. @result An AVSemanticSegmentationMatte instance, or nil if the auxiliary data info dictionary was malformed. @discussion When using ImageIO framework's CGImageSource API to read from a HEIF or JPEG file containing a semantic segmentation matte, AVSemanticSegmentationMatte can be instantiated using the result of CGImageSourceCopyAuxiliaryDataInfoAtIndex, which returns a CFDictionary of primitive segmentation matte information.

func (*AVSemanticSegmentationMatte) DictionaryRepresentationForAuxiliaryDataType ¶

func (o *AVSemanticSegmentationMatte) DictionaryRepresentationForAuxiliaryDataType(outAuxDataType *foundation.NSString) *foundation.NSDictionary[objc.ID, objc.ID]

@method dictionaryRepresentationForAuxiliaryDataType: @abstract Returns a dictionary of primitive map information to be used when writing an image file with a semantic segmentation matte. @param outAuxDataType On output, the auxiliary data type to be used when calling CGImageDestinationAddAuxiliaryDataInfo. Currently supported auxiliary data types are enumerated in <ImageIO/CGImageProperties.h> @result A dictionary of CGImageDestination compatible semantic segmentation matte information, or nil if the auxDataType is unsupported. @discussion When using ImageIO framework's CGImageDestination API to write semantic segmentation matte information to a HEIF or JPEG file, you may use this method to generate a dictionary of primitive map information consumed by CGImageDestinationAddAuxiliaryDataInfo.

func (*AVSemanticSegmentationMatte) MatteType ¶

@property matteType @abstract Specifies the receiver's semantic segmentation matting image type. @discussion An AVSemanticSegmentationMatte's matteType is immutable for the life of the object.

func (*AVSemanticSegmentationMatte) MattingImage ¶

func (o *AVSemanticSegmentationMatte) MattingImage() unsafe.Pointer

@property mattingImage @abstract Provides access to the semantic segmentation matte's internal image. @discussion The pixel format can be queried using the pixelFormatType property.

func (*AVSemanticSegmentationMatte) PixelFormatType ¶

func (o *AVSemanticSegmentationMatte) PixelFormatType() uint

@property pixelFormatType @abstract Specifies the pixel format type of this object's internal matting image. @discussion Currently the only supported CV pixel format type for the matting image is kCVPixelFormatType_OneComponent8.

func (*AVSemanticSegmentationMatte) SemanticSegmentationMatteByApplyingExifOrientation ¶

func (o *AVSemanticSegmentationMatte) SemanticSegmentationMatteByApplyingExifOrientation(exifOrientation imageio.CGImagePropertyOrientation) *AVSemanticSegmentationMatte

@method semanticSegmentationMatteByApplyingExifOrientation: @abstract Returns a derivative AVSemanticSegmentationMatte instance in which the specified Exif orientation has been applied. @param exifOrientation One of the 8 standard Exif orientation tags expressing how the matte should be rotated / mirrored. @result An AVSemanticSegmentationMatte's instance. @discussion When applying simple 90 degree rotation or mirroring edits to media containing a semantic segmentation matte, you may use this initializer to create a derivative copy of the matte in which the specified orientation is applied. This method throws an NSInvalidArgumentException if you pass an unrecognized exifOrientation.

func (*AVSemanticSegmentationMatte) SemanticSegmentationMatteByReplacingSemanticSegmentationMatteWithPixelBufferError ¶

func (o *AVSemanticSegmentationMatte) SemanticSegmentationMatteByReplacingSemanticSegmentationMatteWithPixelBufferError(pixelBuffer unsafe.Pointer) (*AVSemanticSegmentationMatte, error)

@method semanticSegmentationMatteByReplacingSemanticSegmentationMatteWithPixelBuffer:error: @abstract Returns an AVSemanticSegmentationMatte instance wrapping the replacement pixel buffer. @param pixelBuffer A pixel buffer containing a semantic segmentation matting image, represented as kCVPixelFormatType_OneComponent8 with a kCVImageBufferTransferFunction_Linear transfer function. @param outError On return, if the AVSemanticSegmentationMatte cannot be created, points to an NSError describing the problem. @result An AVSemanticSegmentationMatte instance, or nil if the pixel buffer is malformed. @discussion When applying complex edits to media containing a semantic segmentation matte, you may create a derivative matte with arbitrary transforms applied to it, then use this initializer to create a new AVSemanticSegmentationMatte.

type AVSpatialVideoConfiguration ¶

type AVSpatialVideoConfiguration struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avspatialvideoconfiguration

func AVSpatialVideoConfigurationFromID ¶

func AVSpatialVideoConfigurationFromID(id objc.ID) *AVSpatialVideoConfiguration

func (*AVSpatialVideoConfiguration) CameraCalibrationDataLensCollection ¶

func (o *AVSpatialVideoConfiguration) CameraCalibrationDataLensCollection() *foundation.NSArray[objc.ID]

Specifies intrinsic and extrinsic parameters for single or multiple lenses. The property value is an array of dictionaries describing the camera calibration data for each lens. The camera calibration data includes intrinsics and extrinics with other parameters. This property is only applicable when the projection kind is kCMTagProjectionTypeParametricImmersive. Can be nil if the value is unknown.

func (*AVSpatialVideoConfiguration) CameraSystemBaseline ¶

func (o *AVSpatialVideoConfiguration) CameraSystemBaseline() *foundation.NSNumber

Specifies the distance between centers of the lenses of the camera system that created the video. The distance is in micrometers or thousandths of a millimeter. Can be nil if the value is unknown.

func (*AVSpatialVideoConfiguration) DisparityAdjustment ¶

func (o *AVSpatialVideoConfiguration) DisparityAdjustment() *foundation.NSNumber

Specifies a relative shift of the left and right images, which changes the zero parallax plane. The value is in normalized image space and measured over the range of -10000 to 10000 mapping to the uniform range [-1.0...1.0]. The interval of 0.0 to 1.0 or 0 to 10000 maps onto the stereo eye view image width. The negative interval 0.0 to -1.0 or 0 to -10000 similarly map onto the stereo eye view image width. Can be nil if the value is unknown.

func (*AVSpatialVideoConfiguration) HorizontalFieldOfView ¶

func (o *AVSpatialVideoConfiguration) HorizontalFieldOfView() *foundation.NSNumber

Specifies horizontal field of view in thousandths of a degree. Can be nil if the value is unknown.

func (*AVSpatialVideoConfiguration) Init ¶

func (*AVSpatialVideoConfiguration) InitWithFormatDescription ¶

func (o *AVSpatialVideoConfiguration) InitWithFormatDescription(formatDescription unsafe.Pointer) *AVSpatialVideoConfiguration

Initializes an AVSpatialVideoConfiguration with a format description. The format description is not stored. - Parameter formatDescription: Format description to use to initialize the AVSpatialVideoConfiguration. - Returns: An instance of AVSpatialVideoConfiguration

func (*AVSpatialVideoConfiguration) SetCameraCalibrationDataLensCollection ¶

func (o *AVSpatialVideoConfiguration) SetCameraCalibrationDataLensCollection(cameraCalibrationDataLensCollection *foundation.NSArray[objc.ID])

func (*AVSpatialVideoConfiguration) SetCameraSystemBaseline ¶

func (o *AVSpatialVideoConfiguration) SetCameraSystemBaseline(cameraSystemBaseline *foundation.NSNumber)

func (*AVSpatialVideoConfiguration) SetDisparityAdjustment ¶

func (o *AVSpatialVideoConfiguration) SetDisparityAdjustment(disparityAdjustment *foundation.NSNumber)

func (*AVSpatialVideoConfiguration) SetHorizontalFieldOfView ¶

func (o *AVSpatialVideoConfiguration) SetHorizontalFieldOfView(horizontalFieldOfView *foundation.NSNumber)

type AVSynchronizedLayer ¶

type AVSynchronizedLayer struct {
	quartzcore.CALayer
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avsynchronizedlayer

func AVSynchronizedLayerFromID ¶

func AVSynchronizedLayerFromID(id objc.ID) *AVSynchronizedLayer

func AVSynchronizedLayerSynchronizedLayerWithPlayerItem ¶

func AVSynchronizedLayerSynchronizedLayerWithPlayerItem(playerItem *AVPlayerItem) *AVSynchronizedLayer

@method synchronizedLayerWithPlayerItem: @abstract Returns an instance of AVSynchronizedLayer with timing synchronized with the specified AVPlayerItem. @result An instance of AVSynchronizedLayer.

func (*AVSynchronizedLayer) PlayerItem ¶

func (o *AVSynchronizedLayer) PlayerItem() *AVPlayerItem

func (*AVSynchronizedLayer) SetPlayerItem ¶

func (o *AVSynchronizedLayer) SetPlayerItem(playerItem *AVPlayerItem)

type AVTextStyleRule ¶

type AVTextStyleRule struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avtextstylerule

func AVTextStyleRuleFromID ¶

func AVTextStyleRuleFromID(id objc.ID) *AVTextStyleRule

func AVTextStyleRuleTextStyleRuleWithTextMarkupAttributes ¶

func AVTextStyleRuleTextStyleRuleWithTextMarkupAttributes(textMarkupAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVTextStyleRule

@method textStyleRuleWithTextMarkupAttributes: @abstract Creates an instance of AVTextStyleRule with the specified text markup attributes. @param textMarkupAttributes An NSDictionary with keys representing text style attributes that are specifiable in text markup. Eligible keys are defined in <CoreMedia/CMTextMarkup.h>. @result An instance of AVTextStyleRule @discussion Equivalent to invoking +textStyleRuleWithTextMarkupAttributes:textSelector: with a value of nil for textSelector.

func AVTextStyleRuleTextStyleRuleWithTextMarkupAttributesTextSelector ¶

func AVTextStyleRuleTextStyleRuleWithTextMarkupAttributesTextSelector(textMarkupAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID], textSelector *foundation.NSString) *AVTextStyleRule

@method textStyleRuleWithTextMarkupAttributes:textSelector: @abstract Creates an instance of AVTextStyleRule with the specified text markup attributes and an identifier for the range or ranges of text to which the attributes should be applied. @param textMarkupAttributes An NSDictionary with keys representing text style attributes that are specifiable in text markup. Eligible keys are defined in <CoreMedia/CMTextMarkup.h>. @param textSelector An identifier for the range or ranges of text to which the attributes should be applied. Eligible identifiers are determined by the format and content of the legible media. A value of nil indicates that the textMarkupAttributes should be applied as default styles for all text unless overridden by content markup or other applicable text selectors. @result An instance of AVTextStyleRule

func (*AVTextStyleRule) InitWithTextMarkupAttributes ¶

func (o *AVTextStyleRule) InitWithTextMarkupAttributes(textMarkupAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVTextStyleRule

@method initWithTextMarkupAttributes: @abstract Creates an instance of AVTextStyleRule with the specified text markup attributes. @param textMarkupAttributes An NSDictionary with keys representing text style attributes that are specifiable in text markup. Eligible keys are defined in <CoreMedia/CMTextMarkup.h>. @result An instance of AVTextStyleRule @discussion Equivalent to invoking -initWithTextMarkupAttributes:textSelector: with a value of nil for textSelector.

func (*AVTextStyleRule) InitWithTextMarkupAttributesTextSelector ¶

func (o *AVTextStyleRule) InitWithTextMarkupAttributesTextSelector(textMarkupAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID], textSelector *foundation.NSString) *AVTextStyleRule

@method initWithTextMarkupAttributes:textSelector: @abstract Creates an instance of AVTextStyleRule with the specified text markup attributes and an identifier for the range or ranges of text to which the attributes should be applied. @param textMarkupAttributes An NSDictionary with keys representing text style attributes that are specifiable in text markup. Eligible keys are defined in <CoreMedia/CMTextMarkup.h>. @param textSelector An identifier for the range or ranges of text to which the attributes should be applied. Eligible identifiers are determined by the format and content of the legible media. A value of nil indicates that the textMarkupAttributes should be applied as default styles for all text unless overridden by content markup or other applicable text selectors. @result An instance of AVTextStyleRule

func (*AVTextStyleRule) TextMarkupAttributes ¶

func (o *AVTextStyleRule) TextMarkupAttributes() *foundation.NSDictionary[*foundation.NSString, objc.ID]

@property textMarkupAttributes @abstract An NSDictionary with keys representing text style attributes that are specifiable in text markup. Eligible keys and the expected types of their corresponding values are defined in <CoreMedia/CMTextMarkup.h>.

func (*AVTextStyleRule) TextSelector ¶

func (o *AVTextStyleRule) TextSelector() *foundation.NSString

@property textSelector @abstract A string that identifies the range or ranges of text to which the attributes should be applied. A value of nil indicates that the textMarkupAttributes should be applied as default styles for all text unless overridden by content markup or other applicable text selectors. @dicussion The syntax of text selectors is determined by the format of the legible media. Eligible selectors may be determined by the content of the legible media (e.g. CSS selectors that are valid for a specific WebVTT document).

type AVTimedMetadataGroup ¶

type AVTimedMetadataGroup struct {
	AVMetadataGroup
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avtimedmetadatagroup

func AVTimedMetadataGroupFromID ¶

func AVTimedMetadataGroupFromID(id objc.ID) *AVTimedMetadataGroup

func (*AVTimedMetadataGroup) CopyFormatDescription ¶

func (o *AVTimedMetadataGroup) CopyFormatDescription() unsafe.Pointer

@method copyFormatDescription @abstract Creates a format description based on the receiver's items. @result An instance of CMMetadataFormatDescription sufficient to describe the contents of all the items referenced by the receiver. @discussion The returned format description is suitable for use as the format hint parameter when creating an instance of AVAssetWriterInput. Each item referenced by the receiver must carry a non-nil value for its dataType property. An exception will be thrown if any item does not have a data type.

func (*AVTimedMetadataGroup) InitWithItemsTimeRange ¶

func (o *AVTimedMetadataGroup) InitWithItemsTimeRange(items *foundation.NSArray[*AVMetadataItem], timeRange coremedia.CMTimeRange) *AVTimedMetadataGroup

@method initWithItems:timeRange: @abstract Initializes an instance of AVTimedMetadataGroup with a collection of metadata items. @param items An NSArray of AVMetadataItems. @param timeRange The timeRange of the collection of AVMetadataItems. @result An instance of AVTimedMetadataGroup.

func (*AVTimedMetadataGroup) InitWithSampleBuffer ¶

func (o *AVTimedMetadataGroup) InitWithSampleBuffer(sampleBuffer unsafe.Pointer) *AVTimedMetadataGroup

@method initWithSampleBuffer: @abstract Initializes an instance of AVTimedMetadataGroup with a sample buffer. @param sampleBuffer A CMSampleBuffer with media type kCMMediaType_Metadata. @result An instance of AVTimedMetadataGroup.

func (*AVTimedMetadataGroup) TimeRange ¶

type AVURLAsset ¶

type AVURLAsset struct {
	AVAsset
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avurlasset

func AVURLAssetFromID ¶

func AVURLAssetFromID(id objc.ID) *AVURLAsset

func AVURLAssetURLAssetWithURLOptions ¶

func AVURLAssetURLAssetWithURLOptions(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVURLAsset

Returns an instance of AVURLAsset for inspection of a media resource. - Parameter URL: An instance of NSURL that references a media resource. - Parameter options: An instance of NSDictionary that contains keys for specifying options for the initialization of the AVURLAsset. See AVURLAssetPreferPreciseDurationAndTimingKey and AVURLAssetReferenceRestrictionsKey above. - Returns: An instance of AVURLAsset.

func (*AVURLAsset) AssetCache ¶

func (o *AVURLAsset) AssetCache() *AVAssetCache

func (*AVURLAsset) CompatibleTrackForCompositionTrack ¶

func (o *AVURLAsset) CompatibleTrackForCompositionTrack(compositionTrack *AVCompositionTrack) *AVAssetTrack

Provides a reference to an AVAssetTrack of the target from which any timeRange can be inserted into a mutable composition track (via -[AVMutableCompositionTrack insertTimeRange:ofTrack:atTime:error:]). Finds a track of the target with content that can be accommodated by the specified composition track. The logical complement of -[AVMutableComposition mutableTrackCompatibleWithTrack:]. - Parameter compositionTrack: The composition track for which a compatible AVAssetTrack is requested. - Returns: an instance of AVAssetTrack Deprecated: Use findCompatibleTrackForCompositionTrack:completionHandler: instead

func (*AVURLAsset) FindCompatibleTrackForCompositionTrackCompletionHandler ¶

func (o *AVURLAsset) FindCompatibleTrackForCompositionTrackCompletionHandler(compositionTrack *AVCompositionTrack, completionHandler func(unsafe.Pointer, unsafe.Pointer))

Loads a reference to an AVAssetTrack of the target from which any timeRange can be inserted into a mutable composition track (via -[AVMutableCompositionTrack insertTimeRange:ofTrack:atTime:error:]). Finds a track of the target with content that can be accommodated by the specified composition track. The logical complement of -[AVMutableComposition mutableTrackCompatibleWithTrack:]. - Parameter compositionTrack: The composition track for which a compatible AVAssetTrack is requested. - Parameter completionHandler: A block that is invoked when loading is complete, vending an instance of AVAssetTrack or an error.

func (*AVURLAsset) HttpSessionIdentifier ¶

func (o *AVURLAsset) HttpSessionIdentifier() *foundation.NSUUID

Provides the identifier that's automatically included in any HTTP request issued on behalf of this asset in the HTTP header field "X-Playback-Session-Id". The value is an NSUUID from which the UUID string can be obtained. Note that copies of an AVURLAsset vend an equivalent httpSessionIdentifier.

func (*AVURLAsset) InitWithURLOptions ¶

func (o *AVURLAsset) InitWithURLOptions(uRL *foundation.NSURL, options *foundation.NSDictionary[*foundation.NSString, objc.ID]) *AVURLAsset

Initializes an instance of AVURLAsset for inspection of a media resource. - Parameter URL: An instance of NSURL that references a media resource. - Parameter options: An instance of NSDictionary that contains keys for specifying options for the initialization of the AVURLAsset. See AVURLAssetPreferPreciseDurationAndTimingKey and AVURLAssetReferenceRestrictionsKey above. - Returns: An instance of AVURLAsset.

func (*AVURLAsset) MayRequireContentKeysForMediaDataProcessing ¶

func (o *AVURLAsset) MayRequireContentKeysForMediaDataProcessing() bool

func (*AVURLAsset) MediaExtensionProperties ¶

func (o *AVURLAsset) MediaExtensionProperties() *AVMediaExtensionProperties

The properties of the MediaExtension format reader for the asset. If the asset is being decoded using a MediaExtension format reader, this property will return a AVMediaExtensionProperties object describing the extension. If the asset is not being decoded with a MediaExtension format reader, this property will return nil.

func (*AVURLAsset) ResourceLoader ¶

func (o *AVURLAsset) ResourceLoader() *AVAssetResourceLoader

func (*AVURLAsset) SidecarURL ¶

func (o *AVURLAsset) SidecarURL() *foundation.NSURL

The sidecar URL used by the MediaExtension. The sidecar URL is returned only if the MediaExtension format reader supports sidecar files, and implements this property [MEFileInfo setSidecarFilename:]. Will return nil otherwise.

func (*AVURLAsset) URL ¶

func (o *AVURLAsset) URL() *foundation.NSURL

Indicates the URL with which the instance of AVURLAsset was initialized.

func (*AVURLAsset) Variants ¶

func (o *AVURLAsset) Variants() *foundation.NSArray[*AVAssetVariant]

Provides an array of AVAssetVariants contained in the asset Some variants may not be playable according to the current device configuration.

type AVVariantPreferences ¶

type AVVariantPreferences uint64
const (
	// Indicates that only the basic behaviors of the player for choosing among variants should be applied, including considerations of available bandwidth, compatibility of the indicated codec or codecs, the dimensions of visual output, and the number of available audio output channels.
	AVVariantPreferenceNone AVVariantPreferences = 0
	// Directs the item to permit the use of variants with lossless audio encodings, if sufficient bandwidth is available for their use.
	AVVariantPreferenceScalabilityToLosslessAudio AVVariantPreferences = 1
)

func (AVVariantPreferences) String ¶

func (e AVVariantPreferences) String() string

type AVVideoCompositing ¶

type AVVideoCompositing interface {
}

AVVideoCompositing wraps the ObjC protocol AVVideoCompositing.

type AVVideoComposition ¶

type AVVideoComposition struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideocomposition

func AVVideoCompositionFromID ¶

func AVVideoCompositionFromID(id objc.ID) *AVVideoComposition

func AVVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandler ¶

func AVVideoCompositionVideoCompositionWithAssetApplyingCIFiltersWithHandler(asset *AVAsset, applier func(*AVAsynchronousCIImageFilteringRequest)) *AVVideoComposition

Returns a new instance of AVVideoComposition with values and instructions that will apply the specified handler block to video frames represented as instances of CIImage. The returned AVVideoComposition will cause the specified handler block to be called to filter each frame of the asset's first enabled video track. The handler block should use the properties of the provided AVAsynchronousCIImageFilteringRequest and respond using finishWithImage:context: with a "filtered" new CIImage (or the provided source image for no affect). In the event of an error, respond to the request using finishWithError:. The error can be observed via AVPlayerItemFailedToPlayToEndTimeNotification, see AVPlayerItemFailedToPlayToEndTimeErrorKey in notification payload. NOTE: The returned AVVideoComposition's properties are private and support only CIFilter-based operations. Mutations are not supported, either in the values of properties of the AVVideoComposition itself or in its private instructions. If rotations or other transformations are desired, they must be accomplished via the application of CIFilters during the execution of your specified handler. The video composition will also have the following values for its properties: - The original timing of the asset's first enabled video track will be used. - A renderSize that encompasses the asset's first enabled video track respecting the track's preferredTransform. - A renderScale of 1.0. The default CIContext has the following properties: - iOS: Device RGB color space - macOS: sRGB color space Example usage: ```objc playerItem.videoComposition = [AVVideoComposition videoCompositionWithAsset:srcAsset applyingCIFiltersWithHandler: ^(AVAsynchronousCIImageFilteringRequest *request) { NSError *err = nil; CIImage *filtered = myRenderer(request, &err); if (filtered) [request finishWithImage:filtered context:nil]; else [request finishWithError:err]; }]; ``` - Parameter asset: An instance of AVAsset. For best performance, ensure that the duration and tracks properties of the asset are already loaded before invoking this method. - Returns: An instance of AVVideoComposition. Deprecated: Use videoCompositionWithAsset:applyingCIFiltersWithHandler:completionHandler: instead

func AVVideoCompositionVideoCompositionWithPropertiesOfAsset ¶

func AVVideoCompositionVideoCompositionWithPropertiesOfAsset(asset *AVAsset) *AVVideoComposition

Returns a new instance of AVVideoComposition with values and instructions suitable for presenting the video tracks of the specified asset according to its temporal and geometric properties and those of its tracks. The returned AVVideoComposition will have instructions that respect the spatial properties and timeRanges of the specified asset's video tracks. It will also have the following values for its properties: - If the asset has exactly one video track, the original timing of the source video track will be used. If the asset has more than one video track, and the nominal frame rate of any of video tracks is known, the reciprocal of the greatest known nominalFrameRate will be used as the value of frameDuration. Otherwise, a default framerate of 30fps is used. - If the specified asset is an instance of AVComposition, the renderSize will be set to the naturalSize of the AVComposition; otherwise the renderSize will be set to a value that encompasses all of the asset's video tracks. - A renderScale of 1.0. - A nil animationTool. If the specified asset has no video tracks, this method will return an AVVideoComposition instance with an empty collection of instructions. - Parameter asset: An instance of AVAsset. Ensure that the duration and tracks properties of the asset are already loaded before invoking this method. - Returns: An instance of AVVideoComposition. Deprecated: Use videoCompositionWithPropertiesOfAsset:completionHandler: instead

func (*AVVideoComposition) AnimationTool ¶

Indicates a special video composition tool for use of Core Animation; may be nil

func (*AVVideoComposition) ColorPrimaries ¶

func (o *AVVideoComposition) ColorPrimaries() *foundation.NSString

Rendering will use these primaries and frames will be tagged as such. If the value of this property is nil then the source's primaries will be propagated and used. Default is nil. Valid values are those suitable for AVVideoColorPrimariesKey. Generally set as a triple along with colorYCbCrMatrix and colorTransferFunction.

func (*AVVideoComposition) ColorTransferFunction ¶

func (o *AVVideoComposition) ColorTransferFunction() *foundation.NSString

Rendering will use this transfer function and frames will be tagged as such. If the value of this property is nil then the source's transfer function will be propagated and used. Default is nil. Valid values are those suitable for AVVideoTransferFunctionKey. Generally set as a triple along with colorYCbCrMatrix and colorYCbCrMatrix.

func (*AVVideoComposition) ColorYCbCrMatrix ¶

func (o *AVVideoComposition) ColorYCbCrMatrix() *foundation.NSString

Rendering will use this matrix and frames will be tagged as such. If the value of this property is nil then the source's matrix will be propagated and used. Default is nil. Valid values are those suitable for AVVideoYCbCrMatrixKey. Generally set as a triple along with colorPrimaries and colorTransferFunction.

func (*AVVideoComposition) CustomVideoCompositorClass ¶

func (o *AVVideoComposition) CustomVideoCompositorClass() unsafe.Pointer

Indicates a custom compositor class to use. The class must implement the AVVideoCompositing protocol. If nil, the default, internal video compositor is used

func (*AVVideoComposition) DetermineValidityForAssetTimeRangeValidationDelegateCompletionHandler ¶

func (o *AVVideoComposition) DetermineValidityForAssetTimeRangeValidationDelegateCompletionHandler(asset *AVAsset, timeRange coremedia.CMTimeRange, validationDelegate AVVideoCompositionValidationHandling, completionHandler func(bool, unsafe.Pointer))

Determines whether the timeRanges of the receiver's instructions conform to the requirements described for them immediately above (in connection with the instructions property) and also whether all of the layer instructions have a value for trackID that corresponds either to a track of the specified asset or to the receiver's animationTool. In the course of validation, the receiver will invoke its validationDelegate with reference to any trouble spots in the video composition. An exception will be raised if the delegate modifies the receiver's array of instructions or the array of layerInstructions of any AVVideoCompositionInstruction contained therein during validation. - Parameter asset: Pass a reference to an AVAsset if you wish to validate the timeRanges of the instructions against the duration of the asset and the trackIDs of the layer instructions against the asset's tracks. Pass nil to skip that validation. - Parameter timeRange: A CMTimeRange. Only those instructions with timeRanges that overlap with the specified timeRange will be validated. To validate all instructions that may be used for playback or other processing, regardless of timeRange, pass CMTimeRangeMake(kCMTimeZero, kCMTimePositiveInfinity). - Parameter validationDelegate: Indicates an object implementing the AVVideoCompositionValidationHandling protocol to receive information about troublesome portions of a video composition during processing of -determineValidityForAsset:. May be nil. - Parameter completionHandler: A block that is invoked when a determination is made about whether the video composition is valid. If the `isValid` parameter is NO, either the video composition is not valid, in which case the `error` parameter will be nil, or the answer could not be determined, in which case the `error` parameter will be non-nil and describe the failure that occurred. Deprecated: since macOS 15.0.

func (*AVVideoComposition) FrameDuration ¶

func (o *AVVideoComposition) FrameDuration() coremedia.CMTime

Indicates the interval which the video composition, when enabled, should render composed video frames

func (*AVVideoComposition) Instructions ¶

Indicates instructions for video composition via an NSArray of instances of classes implementing the AVVideoCompositionInstruction protocol. For the first instruction in the array, timeRange.start must be less than or equal to the earliest time for which playback or other processing will be attempted (note that this will typically be kCMTimeZero). For subsequent instructions, timeRange.start must be equal to the prior instruction's end time. The end time of the last instruction must be greater than or equal to the latest time for which playback or other processing will be attempted (note that this will often be the duration of the asset with which the instance of AVVideoComposition is associated).

func (*AVVideoComposition) IsValidForAssetTimeRangeValidationDelegate ¶

func (o *AVVideoComposition) IsValidForAssetTimeRangeValidationDelegate(asset *AVAsset, timeRange coremedia.CMTimeRange, validationDelegate AVVideoCompositionValidationHandling) bool

Indicates whether the timeRanges of the receiver's instructions conform to the requirements described for them immediately above (in connection with the instructions property) and also whether all of the layer instructions have a value for trackID that corresponds either to a track of the specified asset or to the receiver's animationTool. In the course of validation, the receiver will invoke its validationDelegate with reference to any trouble spots in the video composition. An exception will be raised if the delegate modifies the receiver's array of instructions or the array of layerInstructions of any AVVideoCompositionInstruction contained therein during validation. - Parameter asset: Pass a reference to an AVAsset if you wish to validate the timeRanges of the instructions against the duration of the asset and the trackIDs of the layer instructions against the asset's tracks. Pass nil to skip that validation. Clients should ensure that the keys @"tracks" and @"duration" are already loaded on the AVAsset before validation is attempted. - Parameter timeRange: A CMTimeRange. Only those instructions with timeRanges that overlap with the specified timeRange will be validated. To validate all instructions that may be used for playback or other processing, regardless of timeRange, pass CMTimeRangeMake(kCMTimeZero, kCMTimePositiveInfinity). - Parameter validationDelegate: Indicates an object implementing the AVVideoCompositionValidationHandling protocol to receive information about troublesome portions of a video composition during processing of -isValidForAsset:. May be nil. Deprecated: Use isValidForTracks:assetDuration:timeRange:validationDelegate: instead

func (*AVVideoComposition) IsValidForTracksAssetDurationTimeRangeValidationDelegate ¶

func (o *AVVideoComposition) IsValidForTracksAssetDurationTimeRangeValidationDelegate(tracks *foundation.NSArray[*AVAssetTrack], duration coremedia.CMTime, timeRange coremedia.CMTimeRange, validationDelegate AVVideoCompositionValidationHandling) bool

Indicates whether the timeRanges of the receiver's instructions conform to the requirements described for them immediately above (in connection with the instructions property) and also whether all of the layer instructions have a value for trackID that corresponds either to a track of the specified asset or to the receiver's animationTool. In the course of validation, the receiver will invoke its validationDelegate with reference to any trouble spots in the video composition. An exception will be raised if the delegate modifies the receiver's array of instructions or the array of layerInstructions of any AVVideoCompositionInstruction contained therein during validation. - Parameter tracks: Pass a reference to an AVAsset's tracks if you wish to validate the trackIDs of the layer instructions against the asset's tracks. Pass nil to skip that validation. This method throws an exception if the tracks are not all from the same asset. - Parameter duration: Pass an AVAsset if you wish to validate the timeRanges of the instructions against the duration of the asset. Pass kCMTimeInvalid to skip that validation. - Parameter timeRange: A CMTimeRange. Only those instructions with timeRanges that overlap with the specified timeRange will be validated. To validate all instructions that may be used for playback or other processing, regardless of timeRange, pass CMTimeRangeMake(kCMTimeZero, kCMTimePositiveInfinity). - Parameter validationDelegate: Indicates an object implementing the AVVideoCompositionValidationHandling protocol to receive information about troublesome portions of a video composition during processing of -isValidForAsset:. May be nil.

func (*AVVideoComposition) OutputBufferDescription ¶

func (o *AVVideoComposition) OutputBufferDescription() *foundation.NSArray[objc.ID]

The output buffers of the video composition can be specified with the outputBufferDescription. The value is an array of CMTagCollectionRef objects that describes the output buffers. If the video composition will output tagged buffers, the details of those buffers should be specified with CMTags. Specifically, the StereoView (eyes) and ProjectionKind must be specified. The behavior is undefined if the output tagged buffers do not match the outputBufferDescription. The default is nil, which means monoscopic output. Note that an empty array is not valid. An exception will be thrown if the objects in the array are not of type CMTagCollectionRef. Note that tagged buffers are only supported for custom compositors.

func (*AVVideoComposition) PerFrameHDRDisplayMetadataPolicy ¶

func (o *AVVideoComposition) PerFrameHDRDisplayMetadataPolicy() *foundation.NSString

Configures policy for per frame HDR display metadata on the rendered frame Allows the system to identify situations where HDR metadata can be generated and attached to the rendered video frame. Default is AVVideoCompositionPerFrameHDRDisplayMetadataPolicyPropagate. Any HDR metadata attached to the composed frame will be propagated to the rendered video frames.

func (*AVVideoComposition) RenderScale ¶

func (o *AVVideoComposition) RenderScale() float32

Indicates the scale at which the video composition should render. May only be other than 1.0 for a video composition set on an AVPlayerItem

func (*AVVideoComposition) RenderSize ¶

func (o *AVVideoComposition) RenderSize() corefoundation.CGSize

Indicates the size at which the video composition, when enabled, should render

func (*AVVideoComposition) SourceSampleDataTrackIDs ¶

func (o *AVVideoComposition) SourceSampleDataTrackIDs() *foundation.NSArray[*foundation.NSNumber]

List of all track IDs for tracks from which sample data should be presented to the compositor at any point in the overall composition. The sample data will be delivered to the custom compositor via AVAsynchronousVideoCompositionRequest.

func (*AVVideoComposition) SourceTrackIDForFrameTiming ¶

func (o *AVVideoComposition) SourceTrackIDForFrameTiming() int32

If sourceTrackIDForFrameTiming is not kCMPersistentTrackID_Invalid, frame timing for the video composition is derived from the source asset's track with the corresponding ID. This may be used to preserve a source asset's variable frame timing. If an empty edit is encountered in the source asset’s track, the compositor composes frames as needed up to the frequency specified in frameDuration property. */

func (*AVVideoComposition) SpatialVideoConfigurations ¶

func (o *AVVideoComposition) SpatialVideoConfigurations() *foundation.NSArray[*AVSpatialVideoConfiguration]

Indicates the spatial configurations that are available to associate with the output of the video composition. A custom compositor can output spatial video by specifying one of these spatial configurations. A spatial configuration with all nil values indicates the video is not spatial. A nil spatial configuration also indicates the video is not spatial. The value can be nil, which indicates the output will not be spatial. NOTE: If this property is not empty, then the client must attach one of the spatial configurations in this array to all of the pixel buffers, otherwise an exception will be thrown.

type AVVideoCompositionCoreAnimationTool ¶

type AVVideoCompositionCoreAnimationTool struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideocompositioncoreanimationtool

func AVVideoCompositionCoreAnimationToolFromID ¶

func AVVideoCompositionCoreAnimationToolFromID(id objc.ID) *AVVideoCompositionCoreAnimationTool

func AVVideoCompositionCoreAnimationToolVideoCompositionCoreAnimationToolWithAdditionalLayerAsTrackID ¶

func AVVideoCompositionCoreAnimationToolVideoCompositionCoreAnimationToolWithAdditionalLayerAsTrackID(layer *quartzcore.CALayer, trackID int32) *AVVideoCompositionCoreAnimationTool

Add a Core Animation layer to the video composition Include a Core Animation layer as an individual track input in video composition. This layer should not come from, or be added to, another layer tree. trackID should not match any real trackID in the source. Use -[AVAsset unusedTrackID] to obtain a trackID that's guaranteed not to coincide with the trackID of any track of the asset. AVVideoCompositionInstructions should reference trackID where the rendered animation should be included. For best performance, no transform should be set in the AVVideoCompositionLayerInstruction for this trackID. Be aware that on iOS, CALayers backing a UIView usually have their content flipped (as defined by the -contentsAreFlipped method). It may be required to insert a CALayer with its geometryFlipped property set to YES in the layer hierarchy to get the same result when attaching a CALayer to a AVVideoCompositionCoreAnimationTool as when using it to back a UIView.

func AVVideoCompositionCoreAnimationToolVideoCompositionCoreAnimationToolWithPostProcessingAsVideoLayerInLayer ¶

func AVVideoCompositionCoreAnimationToolVideoCompositionCoreAnimationToolWithPostProcessingAsVideoLayerInLayer(videoLayer *quartzcore.CALayer, animationLayer *quartzcore.CALayer) *AVVideoCompositionCoreAnimationTool

Compose the composited video frames with the Core Animation layer Place composited video frames in videoLayer and render animationLayer to produce the final frame. Normally videoLayer should be in animationLayer's sublayer tree. The animationLayer should not come from, or be added to, another layer tree. Be aware that on iOS, CALayers backing a UIView usually have their content flipped (as defined by the -contentsAreFlipped method). It may be required to insert a CALayer with its geometryFlipped property set to YES in the layer hierarchy to get the same result when attaching a CALayer to a AVVideoCompositionCoreAnimationTool as when using it to back a UIView.

func AVVideoCompositionCoreAnimationToolVideoCompositionCoreAnimationToolWithPostProcessingAsVideoLayersInLayer ¶

func AVVideoCompositionCoreAnimationToolVideoCompositionCoreAnimationToolWithPostProcessingAsVideoLayersInLayer(videoLayers *foundation.NSArray[*quartzcore.CALayer], animationLayer *quartzcore.CALayer) *AVVideoCompositionCoreAnimationTool

Compose the composited video frames with the Core Animation layer Duplicate the composited video frames in each videoLayer and render animationLayer to produce the final frame. Normally videoLayers should be in animationLayer's sublayer tree. The animationLayer should not come from, or be added to, another layer tree. Be aware that on iOS, CALayers backing a UIView usually have their content flipped (as defined by the -contentsAreFlipped method). It may be required to insert a CALayer with its geometryFlipped property set to YES in the layer hierarchy to get the same result when attaching a CALayer to a AVVideoCompositionCoreAnimationTool as when using it to back a UIView.

type AVVideoCompositionInstruction ¶

type AVVideoCompositionInstruction struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideocompositioninstruction

func AVVideoCompositionInstructionFromID ¶

func AVVideoCompositionInstructionFromID(id objc.ID) *AVVideoCompositionInstruction

func (*AVVideoCompositionInstruction) BackgroundColor ¶

func (o *AVVideoCompositionInstruction) BackgroundColor() unsafe.Pointer

Indicates the background color of the composition. Solid BGRA colors only are supported; patterns and other color refs that are not supported will be ignored. - If the background color is not specified the video compositor will use a default backgroundColor of opaque black. - If the rendered pixel buffer does not have alpha, the alpha value of the backgroundColor will be ignored.

func (*AVVideoCompositionInstruction) EnablePostProcessing ¶

func (o *AVVideoCompositionInstruction) EnablePostProcessing() bool

If NO, indicates that post-processing should be skipped for the duration of this instruction. YES by default. See +[AVVideoCompositionCoreAnimationTool videoCompositionToolWithPostProcessingAsVideoLayer:inLayer:].

func (*AVVideoCompositionInstruction) LayerInstructions ¶

Provides an array of instances of AVVideoCompositionLayerInstruction that specify how video frames from source tracks should be layered and composed. Tracks are layered in the composition according to the top-to-bottom order of the layerInstructions array; the track with trackID of the first instruction in the array will be layered on top, with the track with the trackID of the second instruction immediately underneath, etc. If this key is nil, the output will be a fill of the background color.

func (*AVVideoCompositionInstruction) PassthroughTrackID ¶

func (o *AVVideoCompositionInstruction) PassthroughTrackID() int32

If the video composition result is one of the source frames for the duration of the instruction, this property returns the corresponding track ID. The compositor won't be run for the duration of the instruction and the proper source frame will be used instead. The value of this property is computed from the layer instructions

func (*AVVideoCompositionInstruction) RequiredSourceSampleDataTrackIDs ¶

func (o *AVVideoCompositionInstruction) RequiredSourceSampleDataTrackIDs() *foundation.NSArray[*foundation.NSNumber]

List of track IDs for which sample data should be presented to the compositor for this instruction.

func (*AVVideoCompositionInstruction) RequiredSourceTrackIDs ¶

func (o *AVVideoCompositionInstruction) RequiredSourceTrackIDs() *foundation.NSArray[*foundation.NSValue]

List of video track IDs required to compose frames for this instruction. The value of this property is computed from the layer instructions.

type AVVideoCompositionInstructionProtocol ¶

type AVVideoCompositionInstructionProtocol interface {
	TimeRange() coremedia.CMTimeRange
	EnablePostProcessing() bool
	ContainsTweening() bool
	RequiredSourceTrackIDs() *foundation.NSArray[*foundation.NSValue]
	PassthroughTrackID() int32
}

AVVideoCompositionInstructionProtocol wraps the ObjC protocol AVVideoCompositionInstruction.

type AVVideoCompositionLayerInstruction ¶

type AVVideoCompositionLayerInstruction struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideocompositionlayerinstruction

func AVVideoCompositionLayerInstructionFromID ¶

func AVVideoCompositionLayerInstructionFromID(id objc.ID) *AVVideoCompositionLayerInstruction

func (*AVVideoCompositionLayerInstruction) GetCropRectangleRampForTimeStartCropRectangleEndCropRectangleTimeRange ¶

func (o *AVVideoCompositionLayerInstruction) GetCropRectangleRampForTimeStartCropRectangleEndCropRectangleTimeRange(time_ coremedia.CMTime, startCropRectangle *corefoundation.CGRect, endCropRectangle *corefoundation.CGRect, timeRange *coremedia.CMTimeRange) bool

Obtains the crop rectangle ramp that includes the specified time. - Parameter time: If a ramp with a timeRange that contains the specified time has been set, information about the effective ramp for that time is supplied. Otherwise, information about the first ramp that starts after the specified time is supplied. - Parameter startCropRectangle: A pointer to a CGRect to receive the starting crop rectangle value for the crop rectangle ramp. May be NULL. - Parameter endCropRecrangle: A pointer to a CGRect to receive the ending crop rectangle value for the crop rectangle ramp. May be NULL. - Parameter timeRange: A pointer to a CMTimeRange to receive the timeRange of the crop rectangle ramp. May be NULL. - Returns: An indication of success. NO will be returned if the specified time is beyond the duration of the last crop rectangle ramp that has been set.

func (*AVVideoCompositionLayerInstruction) GetOpacityRampForTimeStartOpacityEndOpacityTimeRange ¶

func (o *AVVideoCompositionLayerInstruction) GetOpacityRampForTimeStartOpacityEndOpacityTimeRange(time_ coremedia.CMTime, startOpacity *float32, endOpacity *float32, timeRange *coremedia.CMTimeRange) bool

Obtains the opacity ramp that includes the specified time. - Parameter time: If a ramp with a timeRange that contains the specified time has been set, information about the effective ramp for that time is supplied. Otherwise, information about the first ramp that starts after the specified time is supplied. - Parameter startOpacity: A pointer to a float to receive the starting opacity value for the opacity ramp. May be NULL. - Parameter endOpacity: A pointer to a float to receive the ending opacity value for the opacity ramp. May be NULL. - Parameter timeRange: A pointer to a CMTimeRange to receive the timeRange of the opacity ramp. May be NULL. - Returns: An indication of success. NO will be returned if the specified time is beyond the duration of the last opacity ramp that has been set.

func (*AVVideoCompositionLayerInstruction) GetTransformRampForTimeStartTransformEndTransformTimeRange ¶

func (o *AVVideoCompositionLayerInstruction) GetTransformRampForTimeStartTransformEndTransformTimeRange(time_ coremedia.CMTime, startTransform *corefoundation.CGAffineTransform, endTransform *corefoundation.CGAffineTransform, timeRange *coremedia.CMTimeRange) bool

Obtains the transform ramp that includes the specified time. - Parameter time: If a ramp with a timeRange that contains the specified time has been set, information about the effective ramp for that time is supplied. Otherwise, information about the first ramp that starts after the specified time is supplied. - Parameter startTransform: A pointer to a float to receive the starting transform value for the transform ramp. May be NULL. - Parameter endTransform: A pointer to a float to receive the ending transform value for the transform ramp. May be NULL. - Parameter timeRange: A pointer to a CMTimeRange to receive the timeRange of the transform ramp. May be NULL. - Returns: An indication of success. NO will be returned if the specified time is beyond the duration of the last transform ramp that has been set.

type AVVideoCompositionRenderContext ¶

type AVVideoCompositionRenderContext struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideocompositionrendercontext

func AVVideoCompositionRenderContextFromID ¶

func AVVideoCompositionRenderContextFromID(id objc.ID) *AVVideoCompositionRenderContext

func (*AVVideoCompositionRenderContext) EdgeWidths ¶

Indicates the thickness of the edge processing region on the left, top, right and bottom edges, in pixels.

func (*AVVideoCompositionRenderContext) HighQualityRendering ¶

func (o *AVVideoCompositionRenderContext) HighQualityRendering() bool

Hints the custom compositor that it may use higher quality, potentially slower algorithms. Generally true for non real time use cases.

func (*AVVideoCompositionRenderContext) NewPixelBuffer ¶

func (o *AVVideoCompositionRenderContext) NewPixelBuffer() unsafe.Pointer

Vends a CVPixelBuffer to use for rendering The buffer will have its kCVImageBufferCleanApertureKey and kCVImageBufferPixelAspectRatioKey attachments set to match the current composition processor properties.

func (*AVVideoCompositionRenderContext) PixelAspectRatio ¶

Indicates the pixel aspect ratio for rendered frames.

func (*AVVideoCompositionRenderContext) RenderScale ¶

func (o *AVVideoCompositionRenderContext) RenderScale() float32

Indicates a scaling ratio that should be applied when rendering frames.

func (*AVVideoCompositionRenderContext) RenderTransform ¶

Transform to apply to the source image to incorporate renderScale, pixelAspectRatio, edgeWidths. The coordinate system origin is the top left corner of the buffer.

func (*AVVideoCompositionRenderContext) Size ¶

Indicates the width and height for rendering frames.

func (*AVVideoCompositionRenderContext) VideoComposition ¶

func (o *AVVideoCompositionRenderContext) VideoComposition() *AVVideoComposition

The AVVideoComposition being rendered.

type AVVideoCompositionRenderHint ¶

type AVVideoCompositionRenderHint struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideocompositionrenderhint

func AVVideoCompositionRenderHintFromID ¶

func AVVideoCompositionRenderHintFromID(id objc.ID) *AVVideoCompositionRenderHint

func (*AVVideoCompositionRenderHint) EndCompositionTime ¶

func (o *AVVideoCompositionRenderHint) EndCompositionTime() coremedia.CMTime

The end time of the upcoming composition requests.

func (*AVVideoCompositionRenderHint) StartCompositionTime ¶

func (o *AVVideoCompositionRenderHint) StartCompositionTime() coremedia.CMTime

The start time of the upcoming composition requests.

type AVVideoCompositionValidationHandling ¶

type AVVideoCompositionValidationHandling interface {
}

AVVideoCompositionValidationHandling wraps the ObjC protocol AVVideoCompositionValidationHandling.

type AVVideoFieldMode ¶

type AVVideoFieldMode int64
const (
	AVVideoFieldModeBoth        AVVideoFieldMode = 0
	AVVideoFieldModeTopOnly     AVVideoFieldMode = 1
	AVVideoFieldModeBottomOnly  AVVideoFieldMode = 2
	AVVideoFieldModeDeinterlace AVVideoFieldMode = 3
)

func (AVVideoFieldMode) String ¶

func (e AVVideoFieldMode) String() string

type AVVideoOutputSpecification ¶

type AVVideoOutputSpecification struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideooutputspecification

func AVVideoOutputSpecificationFromID ¶

func AVVideoOutputSpecificationFromID(id objc.ID) *AVVideoOutputSpecification

func (*AVVideoOutputSpecification) DefaultOutputSettings ¶

@property defaultOutputSettings @abstract The default client requirements for output CVPixelBuffers related to all tag collections not explicitly set with -setOutputSettings:forTagCollection, expressed using the constants in AVVideoSettings.h. For uncompressed video output, start with kCVPixelBuffer* keys in <CoreVideo/CVPixelBuffer.h>. In addition to the keys in CVPixelBuffer.h, uncompressed video settings dictionaries may also contain the following keys: - AVVideoAllowWideColorKey @discussion NSDictionary where keys are of type NSString, values should match the type specified by the corresponding keys documentation in <AVFoundation/AVVideoSettings.h> and <CoreVideo/CVPixelBuffer.h>. @note The setter for this property throws an exception for any of the following reasons: - The settings will yield compressed output - The settings do not honor the requirements list above for outputSettings.

func (*AVVideoOutputSpecification) DefaultPixelBufferAttributes ¶

func (o *AVVideoOutputSpecification) DefaultPixelBufferAttributes() *foundation.NSDictionary[*foundation.NSString, objc.ID]

@property defaultPixelBufferAttributes @abstract The default client requirements for CVPixelBuffers related to all tag collections not explicitly set with setOutputPixelBufferAttributes:forTagCollection:, expressed using the constants in <CoreVideo/CVPixelBuffer.h>. @discussion NSDictionary where keys are of type NSString, values should match the type specified by the corresponding keys documentation in <CoreVideo/CVPixelBuffer.h> @note Pixel buffer attributes are translated into output settings, therefore, the rules of defaultOutputSettings apply to defaultPixelBufferAttributes as well. If defaultPixelBufferAttributes are set after setting defaultOutputSettings, the set output settings will be overridden and vice-versa. Deprecated: since macOS API_TO_BE_DEPRECATED.

func (*AVVideoOutputSpecification) InitWithTagCollections ¶

func (o *AVVideoOutputSpecification) InitWithTagCollections(tagCollections *foundation.NSArray[objc.ID]) *AVVideoOutputSpecification

@method initWithTagCollections: @abstract Creates an instance of AVVideoOutputSpecification initialized with the specified tag collections. @param tagCollections Expects a non-empty array of CMTagCollections. Tag collections are given priority based on their position in the array, where position i take priority over position i+1. @discussion This method throws an exception for the following reasons: - tagCollections is nil or has a count of 0. - tagCollections contains elements that are not of the type CMTagCollection.

func (*AVVideoOutputSpecification) PreferredTagCollections ¶

func (o *AVVideoOutputSpecification) PreferredTagCollections() *foundation.NSArray[objc.ID]

@property preferredTagCollections @abstract Tag collections held by AVVideoOutputSpecification. @discussion Returns an array of CMTagCollections.

func (*AVVideoOutputSpecification) SetDefaultOutputSettings ¶

func (o *AVVideoOutputSpecification) SetDefaultOutputSettings(defaultOutputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID])

@property defaultOutputSettings @abstract The default client requirements for output CVPixelBuffers related to all tag collections not explicitly set with -setOutputSettings:forTagCollection, expressed using the constants in AVVideoSettings.h. For uncompressed video output, start with kCVPixelBuffer* keys in <CoreVideo/CVPixelBuffer.h>. In addition to the keys in CVPixelBuffer.h, uncompressed video settings dictionaries may also contain the following keys: - AVVideoAllowWideColorKey @discussion NSDictionary where keys are of type NSString, values should match the type specified by the corresponding keys documentation in <AVFoundation/AVVideoSettings.h> and <CoreVideo/CVPixelBuffer.h>. @note The setter for this property throws an exception for any of the following reasons: - The settings will yield compressed output - The settings do not honor the requirements list above for outputSettings.

func (*AVVideoOutputSpecification) SetDefaultPixelBufferAttributes ¶

func (o *AVVideoOutputSpecification) SetDefaultPixelBufferAttributes(defaultPixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID])

@property defaultPixelBufferAttributes @abstract The default client requirements for CVPixelBuffers related to all tag collections not explicitly set with setOutputPixelBufferAttributes:forTagCollection:, expressed using the constants in <CoreVideo/CVPixelBuffer.h>. @discussion NSDictionary where keys are of type NSString, values should match the type specified by the corresponding keys documentation in <CoreVideo/CVPixelBuffer.h> @note Pixel buffer attributes are translated into output settings, therefore, the rules of defaultOutputSettings apply to defaultPixelBufferAttributes as well. If defaultPixelBufferAttributes are set after setting defaultOutputSettings, the set output settings will be overridden and vice-versa. Deprecated: since macOS API_TO_BE_DEPRECATED.

func (*AVVideoOutputSpecification) SetOutputPixelBufferAttributesForTagCollection ¶

func (o *AVVideoOutputSpecification) SetOutputPixelBufferAttributesForTagCollection(pixelBufferAttributes *foundation.NSDictionary[*foundation.NSString, objc.ID], tagCollection unsafe.Pointer)

@method setOutputPixelBufferAttributes:forTagCollection: @abstract Specifies a mapping between a tag collection and a set of pixel buffer attributes. @param pixelBufferAttributes The client requirements for CVPixelBuffers related to the tags in tagCollection, expressed using the constants in <CoreVideo/CVPixelBuffer.h>. @param tagCollection A single tag collection for which these pixel buffer attributes should map to. @discussion If this method is called twice on the same tag collection, the first requested pixel buffer attributes will be overridden. @note Pixel buffer attributes are translated into output settings, therefore, the rules of `-setOutputSettings:forTagCollection` apply to this method as well. Namely, if you set pixel buffer attributes for a tag collection and then output settings for that same tag collection, your pixel buffer attributes will be overridden and vice-versa. Deprecated: since macOS API_TO_BE_DEPRECATED.

func (*AVVideoOutputSpecification) SetOutputSettingsForTagCollection ¶

func (o *AVVideoOutputSpecification) SetOutputSettingsForTagCollection(outputSettings *foundation.NSDictionary[*foundation.NSString, objc.ID], tagCollection unsafe.Pointer)

@method setOutputSettings:forTagCollection @abstract Specifies a mapping between a tag collection and a set of output settings. @param outputSettings The client requirements for output CVPixelBuffers related to the tags in tagCollection, expressed using the constants in AVVideoSettings.h. For uncompressed video output, start with kCVPixelBuffer* keys in <CoreVideo/CVPixelBuffer.h>. In addition to the keys in CVPixelBuffer.h, uncompressed video settings dictionaries may also contain the following keys: - AVVideoAllowWideColorKey @param tagCollection A single tag collection for which these output settings should map to. @discussion If this method is called twice on the same tag collection, the first requested output settings will be overridden. @note This method throws an exception for any of the following reasons: - The settings will yield compressed output - The settings do not honor the requirements list above for outputSettings. - tagCollection does not match with any tag collection in -preferredTagCollections.

type AVVideoPerformanceMetrics ¶

type AVVideoPerformanceMetrics struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avvideoperformancemetrics

func AVVideoPerformanceMetricsFromID ¶

func AVVideoPerformanceMetricsFromID(id objc.ID) *AVVideoPerformanceMetrics

func (*AVVideoPerformanceMetrics) NumberOfCorruptedFrames ¶

func (o *AVVideoPerformanceMetrics) NumberOfCorruptedFrames() int

@property numberOfCorruptedFrames @abstract [SPI] The total number of corrupted frames that have been detected.

func (*AVVideoPerformanceMetrics) NumberOfDroppedFrames ¶

func (o *AVVideoPerformanceMetrics) NumberOfDroppedFrames() int

@property numberOfDroppedFrames @abstract [SPI] The total number of frames dropped prior to decoding or dropped because a frame missed its display deadline.

func (*AVVideoPerformanceMetrics) NumberOfFramesDisplayedUsingOptimizedCompositing ¶

func (o *AVVideoPerformanceMetrics) NumberOfFramesDisplayedUsingOptimizedCompositing() int

@property numberOfFramesDisplayedUsingOptimizedCompositing @abstract [SPI] The total number of full screen frames that were rendered in a special power-efficient mode that didn't require the frame to be composited with other UI elements.

func (*AVVideoPerformanceMetrics) TotalAccumulatedFrameDelay ¶

func (o *AVVideoPerformanceMetrics) TotalAccumulatedFrameDelay() float64

@property totalAccumulatedFrameDelay @abstract [SPI] The accumulated amount of time between the prescribed presentation times of displayed video frames and the actual time at which they were displayed. @discussion This delay is always greater than or equal to zero since frames must never be displayed before their presentation time. Non-zero delays are a sign of playback jitter and possible loss of A/V sync.

func (*AVVideoPerformanceMetrics) TotalNumberOfFrames ¶

func (o *AVVideoPerformanceMetrics) TotalNumberOfFrames() int

@property totalNumberOfFrames @abstract [SPI] The total number of frames that would have been displayed if no frames are dropped.

type AVZoomRange ¶

type AVZoomRange struct {
	foundation.NSObject
}

Apple documentation: https://developer.apple.com/documentation/avfoundation/avzoomrange

func AVZoomRangeFromID ¶

func AVZoomRangeFromID(id objc.ID) *AVZoomRange

func (*AVZoomRange) ContainsZoomFactor ¶

func (o *AVZoomRange) ContainsZoomFactor(zoomFactor float64) bool

@method containsZoomFactor: @abstract Tests if a given zoom factor is within the zoom range. @param zoomFactor The zoom factor to test. @result Returns YES if the given zoom factor is within the zoom range, NO otherwise. @discussion Note that the zoom ranges are inclusive.

func (*AVZoomRange) MaxZoomFactor ¶

func (o *AVZoomRange) MaxZoomFactor() float64

@property maxZoomFactor @abstract A CGFloat indicating the maximum zoom factor supported by this range.

func (*AVZoomRange) MinZoomFactor ¶

func (o *AVZoomRange) MinZoomFactor() float64

@property minZoomFactor @abstract A CGFloat indicating the minimum zoom factor supported by this range.

type Acl_entry_id_t ¶

type Acl_entry_id_t int64
const (
	ACL_FIRST_ENTRY Acl_entry_id_t = 0
	ACL_NEXT_ENTRY  Acl_entry_id_t = -1
	ACL_LAST_ENTRY  Acl_entry_id_t = -2
)

func (Acl_entry_id_t) String ¶

func (e Acl_entry_id_t) String() string

type Acl_flag_t ¶

type Acl_flag_t int64
const (
	ACL_FLAG_DEFER_INHERIT      Acl_flag_t = 1
	ACL_FLAG_NO_INHERIT         Acl_flag_t = 131072
	ACL_ENTRY_INHERITED         Acl_flag_t = 16
	ACL_ENTRY_FILE_INHERIT      Acl_flag_t = 32
	ACL_ENTRY_DIRECTORY_INHERIT Acl_flag_t = 64
	ACL_ENTRY_LIMIT_INHERIT     Acl_flag_t = 128
	ACL_ENTRY_ONLY_INHERIT      Acl_flag_t = 256
)

func (Acl_flag_t) String ¶

func (e Acl_flag_t) String() string

type Acl_perm_t ¶

type Acl_perm_t int64
const (
	ACL_READ_DATA           Acl_perm_t = 2
	ACL_LIST_DIRECTORY      Acl_perm_t = 2
	ACL_WRITE_DATA          Acl_perm_t = 4
	ACL_ADD_FILE            Acl_perm_t = 4
	ACL_EXECUTE             Acl_perm_t = 8
	ACL_SEARCH              Acl_perm_t = 8
	ACL_DELETE              Acl_perm_t = 16
	ACL_APPEND_DATA         Acl_perm_t = 32
	ACL_ADD_SUBDIRECTORY    Acl_perm_t = 32
	ACL_DELETE_CHILD        Acl_perm_t = 64
	ACL_READ_ATTRIBUTES     Acl_perm_t = 128
	ACL_WRITE_ATTRIBUTES    Acl_perm_t = 256
	ACL_READ_EXTATTRIBUTES  Acl_perm_t = 512
	ACL_WRITE_EXTATTRIBUTES Acl_perm_t = 1024
	ACL_READ_SECURITY       Acl_perm_t = 2048
	ACL_WRITE_SECURITY      Acl_perm_t = 4096
	ACL_CHANGE_OWNER        Acl_perm_t = 8192
	ACL_SYNCHRONIZE         Acl_perm_t = 1048576
)

func (Acl_perm_t) String ¶

func (e Acl_perm_t) String() string

type Acl_tag_t ¶

type Acl_tag_t int64
const (
	ACL_UNDEFINED_TAG  Acl_tag_t = 0
	ACL_EXTENDED_ALLOW Acl_tag_t = 1
	ACL_EXTENDED_DENY  Acl_tag_t = 2
)

func (Acl_tag_t) String ¶

func (e Acl_tag_t) String() string

type Acl_type_t ¶

type Acl_type_t int64
const (
	ACL_TYPE_EXTENDED Acl_type_t = 256
	ACL_TYPE_ACCESS   Acl_type_t = 0
	ACL_TYPE_DEFAULT  Acl_type_t = 1
	ACL_TYPE_AFS      Acl_type_t = 2
	ACL_TYPE_CODA     Acl_type_t = 3
	ACL_TYPE_NTFS     Acl_type_t = 4
	ACL_TYPE_NWFS     Acl_type_t = 5
)

func (Acl_type_t) String ¶

func (e Acl_type_t) String() string

type CGLCPContextPriorityRequest ¶

type CGLCPContextPriorityRequest int64
const (
	KCGLCPContextPriorityRequestHigh   CGLCPContextPriorityRequest = 0
	KCGLCPContextPriorityRequestNormal CGLCPContextPriorityRequest = 1
	KCGLCPContextPriorityRequestLow    CGLCPContextPriorityRequest = 2
)

func (CGLCPContextPriorityRequest) String ¶

type CMTagCollectionVideoOutputPreset ¶

type CMTagCollectionVideoOutputPreset int64
const (
	KCMTagCollectionVideoOutputPreset_Monoscopic   CMTagCollectionVideoOutputPreset = 0
	KCMTagCollectionVideoOutputPreset_Stereoscopic CMTagCollectionVideoOutputPreset = 1
)

func (CMTagCollectionVideoOutputPreset) String ¶

type Clockid_t ¶

type Clockid_t int64

func (Clockid_t) String ¶

func (e Clockid_t) String() string

type Dispatch_autorelease_frequency_t ¶

type Dispatch_autorelease_frequency_t uint64
const (
	DISPATCH_AUTORELEASE_FREQUENCY_INHERIT   Dispatch_autorelease_frequency_t = 0
	DISPATCH_AUTORELEASE_FREQUENCY_WORK_ITEM Dispatch_autorelease_frequency_t = 1
	DISPATCH_AUTORELEASE_FREQUENCY_NEVER     Dispatch_autorelease_frequency_t = 2
)

func (Dispatch_autorelease_frequency_t) String ¶

type Dispatch_block_flags_t ¶

type Dispatch_block_flags_t uint64
const (
	DISPATCH_BLOCK_BARRIER           Dispatch_block_flags_t = 1
	DISPATCH_BLOCK_DETACHED          Dispatch_block_flags_t = 2
	DISPATCH_BLOCK_ASSIGN_CURRENT    Dispatch_block_flags_t = 4
	DISPATCH_BLOCK_NO_QOS_CLASS      Dispatch_block_flags_t = 8
	DISPATCH_BLOCK_INHERIT_QOS_CLASS Dispatch_block_flags_t = 16
	DISPATCH_BLOCK_ENFORCE_QOS_CLASS Dispatch_block_flags_t = 32
)

func (Dispatch_block_flags_t) String ¶

func (e Dispatch_block_flags_t) String() string

type EvCmd ¶

type EvCmd int64
const (
	EVNOP   EvCmd = 0
	EVHIDE  EvCmd = 1
	EVSHOW  EvCmd = 2
	EVMOVE  EvCmd = 3
	EVLEVEL EvCmd = 4
)

func (EvCmd) String ¶

func (e EvCmd) String() string

type Filesec_property_t ¶

type Filesec_property_t int64
const (
	FILESEC_OWNER         Filesec_property_t = 1
	FILESEC_GROUP         Filesec_property_t = 2
	FILESEC_UUID          Filesec_property_t = 3
	FILESEC_MODE          Filesec_property_t = 4
	FILESEC_ACL           Filesec_property_t = 5
	FILESEC_GRPUUID       Filesec_property_t = 6
	FILESEC_ACL_RAW       Filesec_property_t = 100
	FILESEC_ACL_ALLOCSIZE Filesec_property_t = 101
)

func (Filesec_property_t) String ¶

func (e Filesec_property_t) String() string

type Idtype_t ¶

type Idtype_t int64
const (
	P_ALL  Idtype_t = 0
	P_PID  Idtype_t = 1
	P_PGID Idtype_t = 2
)

func (Idtype_t) String ¶

func (e Idtype_t) String() string

type Ipc_info_object_type_t ¶

type Ipc_info_object_type_t int64
const (
	IPC_OTYPE_NONE                 Ipc_info_object_type_t = 0
	IPC_OTYPE_THREAD_CONTROL       Ipc_info_object_type_t = 1
	IPC_OTYPE_TASK_CONTROL         Ipc_info_object_type_t = 2
	IPC_OTYPE_HOST                 Ipc_info_object_type_t = 3
	IPC_OTYPE_HOST_PRIV            Ipc_info_object_type_t = 4
	IPC_OTYPE_PROCESSOR            Ipc_info_object_type_t = 5
	IPC_OTYPE_PROCESSOR_SET        Ipc_info_object_type_t = 6
	IPC_OTYPE_PROCESSOR_SET_NAME   Ipc_info_object_type_t = 7
	IPC_OTYPE_TIMER                Ipc_info_object_type_t = 8
	IPC_OTYPE_PORT_SUBST_ONCE      Ipc_info_object_type_t = 9
	IPC_OTYPE_MIG                  Ipc_info_object_type_t = 10
	IPC_OTYPE_MEMORY_OBJECT        Ipc_info_object_type_t = 11
	IPC_OTYPE_XMM_PAGER            Ipc_info_object_type_t = 12
	IPC_OTYPE_XMM_KERNEL           Ipc_info_object_type_t = 13
	IPC_OTYPE_XMM_REPLY            Ipc_info_object_type_t = 14
	IPC_OTYPE_UND_REPLY            Ipc_info_object_type_t = 15
	IPC_OTYPE_HOST_NOTIFY          Ipc_info_object_type_t = 16
	IPC_OTYPE_HOST_SECURITY        Ipc_info_object_type_t = 17
	IPC_OTYPE_LEDGER               Ipc_info_object_type_t = 18
	IPC_OTYPE_MAIN_DEVICE          Ipc_info_object_type_t = 19
	IPC_OTYPE_TASK_NAME            Ipc_info_object_type_t = 20
	IPC_OTYPE_SUBSYSTEM            Ipc_info_object_type_t = 21
	IPC_OTYPE_IO_DONE_QUEUE        Ipc_info_object_type_t = 22
	IPC_OTYPE_SEMAPHORE            Ipc_info_object_type_t = 23
	IPC_OTYPE_LOCK_SET             Ipc_info_object_type_t = 24
	IPC_OTYPE_CLOCK                Ipc_info_object_type_t = 25
	IPC_OTYPE_CLOCK_CTRL           Ipc_info_object_type_t = 26
	IPC_OTYPE_IOKIT_IDENT          Ipc_info_object_type_t = 27
	IPC_OTYPE_NAMED_ENTRY          Ipc_info_object_type_t = 28
	IPC_OTYPE_IOKIT_CONNECT        Ipc_info_object_type_t = 29
	IPC_OTYPE_IOKIT_OBJECT         Ipc_info_object_type_t = 30
	IPC_OTYPE_UPL                  Ipc_info_object_type_t = 31
	IPC_OTYPE_MEM_OBJ_CONTROL      Ipc_info_object_type_t = 32
	IPC_OTYPE_AU_SESSIONPORT       Ipc_info_object_type_t = 33
	IPC_OTYPE_FILEPORT             Ipc_info_object_type_t = 34
	IPC_OTYPE_LABELH               Ipc_info_object_type_t = 35
	IPC_OTYPE_TASK_RESUME          Ipc_info_object_type_t = 36
	IPC_OTYPE_VOUCHER              Ipc_info_object_type_t = 37
	IPC_OTYPE_VOUCHER_ATTR_CONTROL Ipc_info_object_type_t = 38
	IPC_OTYPE_WORK_INTERVAL        Ipc_info_object_type_t = 39
	IPC_OTYPE_UX_HANDLER           Ipc_info_object_type_t = 40
	IPC_OTYPE_UEXT_OBJECT          Ipc_info_object_type_t = 41
	IPC_OTYPE_ARCADE_REG           Ipc_info_object_type_t = 42
	IPC_OTYPE_EVENTLINK            Ipc_info_object_type_t = 43
	IPC_OTYPE_TASK_INSPECT         Ipc_info_object_type_t = 44
	IPC_OTYPE_TASK_READ            Ipc_info_object_type_t = 45
	IPC_OTYPE_THREAD_INSPECT       Ipc_info_object_type_t = 46
	IPC_OTYPE_THREAD_READ          Ipc_info_object_type_t = 47
	IPC_OTYPE_SUID_CRED            Ipc_info_object_type_t = 48
	IPC_OTYPE_HYPERVISOR           Ipc_info_object_type_t = 49
	IPC_OTYPE_TASK_ID_TOKEN        Ipc_info_object_type_t = 50
	IPC_OTYPE_TASK_FATAL           Ipc_info_object_type_t = 51
	IPC_OTYPE_KCDATA               Ipc_info_object_type_t = 52
	IPC_OTYPE_EXCLAVES_RESOURCE    Ipc_info_object_type_t = 53
	IPC_OTYPE_THREAD_RESUME        Ipc_info_object_type_t = 54
	IPC_OTYPE_UNKNOWN              Ipc_info_object_type_t = 4294967295
)

func (Ipc_info_object_type_t) String ¶

func (e Ipc_info_object_type_t) String() string

type Launch_data_type_t ¶

type Launch_data_type_t int64
const (
	LAUNCH_DATA_DICTIONARY Launch_data_type_t = 1
	LAUNCH_DATA_ARRAY      Launch_data_type_t = 2
	LAUNCH_DATA_FD         Launch_data_type_t = 3
	LAUNCH_DATA_INTEGER    Launch_data_type_t = 4
	LAUNCH_DATA_REAL       Launch_data_type_t = 5
	LAUNCH_DATA_BOOL       Launch_data_type_t = 6
	LAUNCH_DATA_STRING     Launch_data_type_t = 7
	LAUNCH_DATA_OPAQUE     Launch_data_type_t = 8
	LAUNCH_DATA_ERRNO      Launch_data_type_t = 9
	LAUNCH_DATA_MACHPORT   Launch_data_type_t = 10
)

func (Launch_data_type_t) String ¶

func (e Launch_data_type_t) String() string

type MDLabelDomain ¶

type MDLabelDomain int64

@typedef MDLabelDomain @abstract These constants are used to specify a domain to MDLabelCreate().

const (
	KMDLabelUserDomain  MDLabelDomain = 0
	KMDLabelLocalDomain MDLabelDomain = 1
)

func (MDLabelDomain) String ¶

func (e MDLabelDomain) String() string

type MDQueryOptionFlags ¶

type MDQueryOptionFlags int64
const (
	KMDQuerySynchronous        MDQueryOptionFlags = 1
	KMDQueryWantsUpdates       MDQueryOptionFlags = 4
	KMDQueryAllowFSTranslation MDQueryOptionFlags = 8
)

func (MDQueryOptionFlags) String ¶

func (e MDQueryOptionFlags) String() string

type MDQuerySortOptionFlags ¶

type MDQuerySortOptionFlags int64

@enum MDQuerySortOptionFlags @constant kMDQueryReverseSortOrderFlag Sort the attribute in reverse order.

const (
	KMDQueryReverseSortOrderFlag MDQuerySortOptionFlags = 1
)

func (MDQuerySortOptionFlags) String ¶

func (e MDQuerySortOptionFlags) String() string

type Mach_vm_range_flags_t ¶

type Mach_vm_range_flags_t int64
const (
	MACH_VM_RANGE_NONE Mach_vm_range_flags_t = 0
)

func (Mach_vm_range_flags_t) String ¶

func (e Mach_vm_range_flags_t) String() string

type Mach_vm_range_flavor_t ¶

type Mach_vm_range_flavor_t int64
const (
	MACH_VM_RANGE_FLAVOR_INVALID Mach_vm_range_flavor_t = 0
	MACH_VM_RANGE_FLAVOR_V1      Mach_vm_range_flavor_t = 1
)

func (Mach_vm_range_flavor_t) String ¶

func (e Mach_vm_range_flavor_t) String() string

type Mach_vm_range_tag_t ¶

type Mach_vm_range_tag_t int64
const (
	MACH_VM_RANGE_DEFAULT Mach_vm_range_tag_t = 0
	MACH_VM_RANGE_DATA    Mach_vm_range_tag_t = 1
	MACH_VM_RANGE_FIXED   Mach_vm_range_tag_t = 2
)

func (Mach_vm_range_tag_t) String ¶

func (e Mach_vm_range_tag_t) String() string

type Mpo_flags_t ¶

type Mpo_flags_t int64
const (
	MPO_PORT                            Mpo_flags_t = 0
	MPO_SERVICE_PORT                    Mpo_flags_t = 1024
	MPO_CONNECTION_PORT                 Mpo_flags_t = 2048
	MPO_REPLY_PORT                      Mpo_flags_t = 4096
	MPO_WEAK_REPLY_PORT                 Mpo_flags_t = 16384
	MPO_NOTIFICATION_PORT               Mpo_flags_t = 17408
	MPO_EXCEPTION_PORT                  Mpo_flags_t = 32768
	MPO_CONNECTION_PORT_WITH_PORT_ARRAY Mpo_flags_t = 65536
)

func (Mpo_flags_t) String ¶

func (e Mpo_flags_t) String() string

type NXMouseButton ¶

type NXMouseButton int64
const (
	NX_OneButton   NXMouseButton = 0
	NX_LeftButton  NXMouseButton = 1
	NX_RightButton NXMouseButton = 2
)

func (NXMouseButton) String ¶

func (e NXMouseButton) String() string

type Os_clockid_t ¶

type Os_clockid_t int64
const (
	OS_CLOCK_MACH_ABSOLUTE_TIME Os_clockid_t = 32
)

func (Os_clockid_t) String ¶

func (e Os_clockid_t) String() string

type PMPageToPaperMappingType ¶

type PMPageToPaperMappingType int64
const (
	KPMPageToPaperMappingNone       PMPageToPaperMappingType = 1
	KPMPageToPaperMappingScaleToFit PMPageToPaperMappingType = 2
)

func (PMPageToPaperMappingType) String ¶

func (e PMPageToPaperMappingType) String() string

type Ptrauth_key ¶

type Ptrauth_key int64
const (
	Ptrauth_key_none                     Ptrauth_key = -1
	Ptrauth_key_asia                     Ptrauth_key = 0
	Ptrauth_key_asib                     Ptrauth_key = 1
	Ptrauth_key_asda                     Ptrauth_key = 2
	Ptrauth_key_asdb                     Ptrauth_key = 3
	Ptrauth_key_process_independent_code Ptrauth_key = 0
	Ptrauth_key_process_dependent_code   Ptrauth_key = 1
	Ptrauth_key_process_independent_data Ptrauth_key = 2
	Ptrauth_key_process_dependent_data   Ptrauth_key = 3
	Ptrauth_key_return_address           Ptrauth_key = 1
	Ptrauth_key_frame_pointer            Ptrauth_key = 3
	Ptrauth_key_function_pointer         Ptrauth_key = 0
	Ptrauth_key_block_function           Ptrauth_key = 0
	Ptrauth_key_cxx_vtable_pointer       Ptrauth_key = 2
	Ptrauth_key_method_list_pointer      Ptrauth_key = 2
	Ptrauth_key_objc_isa_pointer         Ptrauth_key = 2
	Ptrauth_key_objc_super_pointer       Ptrauth_key = 2
	Ptrauth_key_objc_sel_pointer         Ptrauth_key = 3
	Ptrauth_key_objc_class_ro_pointer    Ptrauth_key = 2
	Ptrauth_key_block_descriptor_pointer Ptrauth_key = 2
	Ptrauth_key_init_fini_pointer        Ptrauth_key = 0
)

func (Ptrauth_key) String ¶

func (e Ptrauth_key) String() string

type Qos_class_t ¶

type Qos_class_t uint32
const (
	QOS_CLASS_USER_INTERACTIVE Qos_class_t = 33
	QOS_CLASS_USER_INITIATED   Qos_class_t = 25
	QOS_CLASS_DEFAULT          Qos_class_t = 21
	QOS_CLASS_UTILITY          Qos_class_t = 17
	QOS_CLASS_BACKGROUND       Qos_class_t = 9
	QOS_CLASS_UNSPECIFIED      Qos_class_t = 0
)

func (Qos_class_t) String ¶

func (e Qos_class_t) String() string

type Virtual_memory_guard_exception_code_t ¶

type Virtual_memory_guard_exception_code_t int64
const (
	KGUARD_EXC_DEALLOC_GAP                   Virtual_memory_guard_exception_code_t = 1
	KGUARD_EXC_RECLAIM_COPYIO_FAILURE        Virtual_memory_guard_exception_code_t = 2
	KGUARD_EXC_RECLAIM_INDEX_FAILURE         Virtual_memory_guard_exception_code_t = 4
	KGUARD_EXC_RECLAIM_DEALLOCATE_FAILURE    Virtual_memory_guard_exception_code_t = 8
	KGUARD_EXC_RECLAIM_ACCOUNTING_FAILURE    Virtual_memory_guard_exception_code_t = 9
	KGUARD_EXC_SEC_IOPL_ON_EXEC_PAGE         Virtual_memory_guard_exception_code_t = 10
	KGUARD_EXC_SEC_EXEC_ON_IOPL_PAGE         Virtual_memory_guard_exception_code_t = 11
	KGUARD_EXC_SEC_UPL_WRITE_ON_EXEC_REGION  Virtual_memory_guard_exception_code_t = 12
	KGUARD_EXC_LARGE_ALLOCATION_TELEMETRY    Virtual_memory_guard_exception_code_t = 13
	KGUARD_EXC_SEC_ACCESS_FAULT              Virtual_memory_guard_exception_code_t = 98
	KGUARD_EXC_SEC_ASYNC_ACCESS_FAULT        Virtual_memory_guard_exception_code_t = 99
	KGUARD_EXC_SEC_COPY_DENIED               Virtual_memory_guard_exception_code_t = 100
	KGUARD_EXC_SEC_SHARING_DENIED            Virtual_memory_guard_exception_code_t = 101
	KGUARD_EXC_MTE_SYNC_FAULT                Virtual_memory_guard_exception_code_t = 200
	KGUARD_EXC_MTE_ASYNC_USER_FAULT          Virtual_memory_guard_exception_code_t = 201
	KGUARD_EXC_MTE_ASYNC_KERN_FAULT          Virtual_memory_guard_exception_code_t = 202
	KGUARD_EXC_GUARD_OBJECT_ASYNC_USER_FAULT Virtual_memory_guard_exception_code_t = 203
	KGUARD_EXC_GUARD_OBJECT_ASYNC_KERN_FAULT Virtual_memory_guard_exception_code_t = 204
)

func (Virtual_memory_guard_exception_code_t) String ¶

type Xpc_listener_create_flags_t ¶

type Xpc_listener_create_flags_t int64
const (
	XPC_LISTENER_CREATE_NONE             Xpc_listener_create_flags_t = 0
	XPC_LISTENER_CREATE_INACTIVE         Xpc_listener_create_flags_t = 1
	XPC_LISTENER_CREATE_FORCE_MACH       Xpc_listener_create_flags_t = 2
	XPC_LISTENER_CREATE_FORCE_XPCSERVICE Xpc_listener_create_flags_t = 4
)

func (Xpc_listener_create_flags_t) String ¶

type Xpc_session_create_flags_t ¶

type Xpc_session_create_flags_t int64
const (
	XPC_SESSION_CREATE_NONE            Xpc_session_create_flags_t = 0
	XPC_SESSION_CREATE_INACTIVE        Xpc_session_create_flags_t = 1
	XPC_SESSION_CREATE_MACH_PRIVILEGED Xpc_session_create_flags_t = 2
)

func (Xpc_session_create_flags_t) String ¶

Source Files ¶

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL