objc2-av-foundation 0.3.2

Bindings to the AVFoundation framework
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ffi::*;
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
#[cfg(feature = "objc2-core-foundation")]
use objc2_core_foundation::*;
#[cfg(feature = "objc2-core-media")]
use objc2_core_media::*;
use objc2_foundation::*;

use crate::*;

extern_class!(
    /// [Apple's documentation](https://developer.apple.com/documentation/avfoundation/avcompositiontrack?language=objc)
    #[unsafe(super(AVAssetTrack, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "AVAssetTrack")]
    pub struct AVCompositionTrack;
);

#[cfg(all(feature = "AVAssetTrack", feature = "AVAsynchronousKeyValueLoading"))]
extern_conformance!(
    unsafe impl AVAsynchronousKeyValueLoading for AVCompositionTrack {}
);

#[cfg(feature = "AVAssetTrack")]
extern_conformance!(
    unsafe impl NSCopying for AVCompositionTrack {}
);

#[cfg(feature = "AVAssetTrack")]
unsafe impl CopyingHelper for AVCompositionTrack {
    type Result = Self;
}

#[cfg(feature = "AVAssetTrack")]
extern_conformance!(
    unsafe impl NSObjectProtocol for AVCompositionTrack {}
);

#[cfg(feature = "AVAssetTrack")]
impl AVCompositionTrack {
    extern_methods!(
        #[cfg(all(feature = "AVAssetTrackSegment", feature = "AVCompositionTrackSegment"))]
        /// Provides read-only access to the array of track segments, each an instance of AVCompositionTrackSegment.
        ///
        /// Note that timeMapping.target.start of the first AVCompositionTrackSegment must be kCMTimeZero, and the timeMapping.target.start of each subsequent AVCompositionTrackSegment must equal CMTimeRangeGetEnd(the previous AVCompositionTrackSegment's timeMapping.target).
        /// Use -validateTrackSegments:error: to perform a test to ensure that an array of AVCompositionTrackSegments conforms to this rule.
        #[unsafe(method(segments))]
        #[unsafe(method_family = none)]
        pub unsafe fn segments(&self) -> Retained<NSArray<AVCompositionTrackSegment>>;

        #[cfg(all(
            feature = "AVAssetTrackSegment",
            feature = "AVCompositionTrackSegment",
            feature = "objc2-core-media"
        ))]
        /// Supplies the AVCompositionTrackSegment 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.
        ///
        /// Parameter `trackTime`: The trackTime for which an AVCompositionTrackSegment is requested.
        ///
        /// Returns: An AVCompositionTrackSegment.
        ///
        /// 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.
        #[unsafe(method(segmentForTrackTime:))]
        #[unsafe(method_family = none)]
        pub unsafe fn segmentForTrackTime(
            &self,
            track_time: CMTime,
        ) -> Option<Retained<AVCompositionTrackSegment>>;

        /// An array of AVCompositionTrackFormatDescriptionReplacement objects indicating original format descriptions and their replacements.
        ///
        /// 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.
        #[unsafe(method(formatDescriptionReplacements))]
        #[unsafe(method_family = none)]
        pub unsafe fn formatDescriptionReplacements(
            &self,
        ) -> Retained<NSArray<AVCompositionTrackFormatDescriptionReplacement>>;
    );
}

/// Methods declared on superclass `AVAssetTrack`.
#[cfg(feature = "AVAssetTrack")]
impl AVCompositionTrack {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;

        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}

extern_class!(
    /// [Apple's documentation](https://developer.apple.com/documentation/avfoundation/avmutablecompositiontrack?language=objc)
    #[unsafe(super(AVCompositionTrack, AVAssetTrack, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "AVAssetTrack")]
    pub struct AVMutableCompositionTrack;
);

#[cfg(all(feature = "AVAssetTrack", feature = "AVAsynchronousKeyValueLoading"))]
extern_conformance!(
    unsafe impl AVAsynchronousKeyValueLoading for AVMutableCompositionTrack {}
);

#[cfg(feature = "AVAssetTrack")]
extern_conformance!(
    unsafe impl NSCopying for AVMutableCompositionTrack {}
);

#[cfg(feature = "AVAssetTrack")]
unsafe impl CopyingHelper for AVMutableCompositionTrack {
    type Result = Self;
}

#[cfg(feature = "AVAssetTrack")]
extern_conformance!(
    unsafe impl NSObjectProtocol for AVMutableCompositionTrack {}
);

#[cfg(feature = "AVAssetTrack")]
impl AVMutableCompositionTrack {
    extern_methods!(
        /// Specifies whether the track is enabled or disabled.  Default is YES.
        #[unsafe(method(isEnabled))]
        #[unsafe(method_family = none)]
        pub unsafe fn isEnabled(&self) -> bool;

        /// Setter for [`isEnabled`][Self::isEnabled].
        #[unsafe(method(setEnabled:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setEnabled(&self, enabled: bool);

        #[cfg(feature = "objc2-core-media")]
        /// Indicates a timescale in which time values for the track can be operated upon without extraneous numerical conversion.
        ///
        /// If not set, the value is the naturalTimeScale of the first non-empty edit, or 600 if there are no non-empty edits.
        /// Set to 0 to revert to default behavior.
        #[unsafe(method(naturalTimeScale))]
        #[unsafe(method_family = none)]
        pub unsafe fn naturalTimeScale(&self) -> CMTimeScale;

        #[cfg(feature = "objc2-core-media")]
        /// Setter for [`naturalTimeScale`][Self::naturalTimeScale].
        #[unsafe(method(setNaturalTimeScale:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setNaturalTimeScale(&self, natural_time_scale: CMTimeScale);

        /// Indicates the language associated with the track, as an ISO 639-2/T language code.
        ///
        /// The default value is nil.
        #[unsafe(method(languageCode))]
        #[unsafe(method_family = none)]
        pub unsafe fn languageCode(&self) -> Option<Retained<NSString>>;

        /// Setter for [`languageCode`][Self::languageCode].
        ///
        /// This is [copied][objc2_foundation::NSCopying::copy] when set.
        #[unsafe(method(setLanguageCode:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setLanguageCode(&self, language_code: Option<&NSString>);

        /// Indicates the language tag associated with the track, as an IETF BCP 47 (RFC 4646) language identifier.
        ///
        /// The default value is nil.
        #[unsafe(method(extendedLanguageTag))]
        #[unsafe(method_family = none)]
        pub unsafe fn extendedLanguageTag(&self) -> Option<Retained<NSString>>;

        /// Setter for [`extendedLanguageTag`][Self::extendedLanguageTag].
        ///
        /// This is [copied][objc2_foundation::NSCopying::copy] when set.
        #[unsafe(method(setExtendedLanguageTag:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setExtendedLanguageTag(&self, extended_language_tag: Option<&NSString>);

        #[cfg(feature = "objc2-core-foundation")]
        /// The preferred transformation of the visual media data for display purposes.
        ///
        /// The default value is CGAffineTransformIdentity.
        #[unsafe(method(preferredTransform))]
        #[unsafe(method_family = none)]
        pub unsafe fn preferredTransform(&self) -> CGAffineTransform;

        #[cfg(feature = "objc2-core-foundation")]
        /// Setter for [`preferredTransform`][Self::preferredTransform].
        #[unsafe(method(setPreferredTransform:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setPreferredTransform(&self, preferred_transform: CGAffineTransform);

        /// The preferred volume of the audible media data.
        ///
        /// The default value is 1.0.
        #[unsafe(method(preferredVolume))]
        #[unsafe(method_family = none)]
        pub unsafe fn preferredVolume(&self) -> c_float;

        /// Setter for [`preferredVolume`][Self::preferredVolume].
        #[unsafe(method(setPreferredVolume:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setPreferredVolume(&self, preferred_volume: c_float);

        #[cfg(all(feature = "AVAssetTrackSegment", feature = "AVCompositionTrackSegment"))]
        /// Provides read/write access to the array of track segments, each an instance of AVCompositionTrackSegment.
        ///
        /// Note that timeMapping.target.start of the first AVCompositionTrackSegment must be kCMTimeZero, and the timeMapping.target.start of each subsequent AVCompositionTrackSegment must equal CMTimeRangeGetEnd(the previous AVCompositionTrackSegment's timeMapping.target).
        /// Use -validateTrackSegments:error: to perform a test to ensure that an array of AVCompositionTrackSegments conforms to this rule.
        #[unsafe(method(segments))]
        #[unsafe(method_family = none)]
        pub unsafe fn segments(&self) -> Retained<NSArray<AVCompositionTrackSegment>>;

        #[cfg(all(feature = "AVAssetTrackSegment", feature = "AVCompositionTrackSegment"))]
        /// Setter for [`segments`][Self::segments].
        ///
        /// This is [copied][objc2_foundation::NSCopying::copy] when set.
        #[unsafe(method(setSegments:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setSegments(&self, segments: Option<&NSArray<AVCompositionTrackSegment>>);

        #[cfg(feature = "objc2-core-media")]
        /// Inserts a timeRange of a source track into a track of a composition.
        ///
        /// Parameter `timeRange`: Specifies the timeRange of the track to be inserted.
        ///
        /// Parameter `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).
        ///
        /// Parameter `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.
        ///
        /// Parameter `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.
        ///
        /// Returns: A BOOL value indicating the success of the insertion.
        ///
        /// 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:.
        #[unsafe(method(insertTimeRange:ofTrack:atTime:error:_))]
        #[unsafe(method_family = none)]
        pub unsafe fn insertTimeRange_ofTrack_atTime_error(
            &self,
            time_range: CMTimeRange,
            track: &AVAssetTrack,
            start_time: CMTime,
        ) -> Result<(), Retained<NSError>>;

        #[cfg(feature = "objc2-core-media")]
        /// Inserts the timeRanges of multiple source tracks into a track of a composition.
        ///
        /// Parameter `timeRanges`: Specifies the timeRanges to be inserted. An NSArray of NSValues containing CMTimeRange. (See +[NSValue valueWithCMTimeRange:] in AVTime.h.)
        ///
        /// Parameter `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).
        ///
        /// Parameter `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.
        ///
        /// Parameter `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.
        ///
        /// Returns: A BOOL value indicating the success of the insertion.
        ///
        /// 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.
        #[unsafe(method(insertTimeRanges:ofTracks:atTime:error:_))]
        #[unsafe(method_family = none)]
        pub unsafe fn insertTimeRanges_ofTracks_atTime_error(
            &self,
            time_ranges: &NSArray<NSValue>,
            tracks: &NSArray<AVAssetTrack>,
            start_time: CMTime,
        ) -> Result<(), Retained<NSError>>;

        #[cfg(feature = "objc2-core-media")]
        /// Adds or extends an empty timeRange within the composition track.
        ///
        /// Parameter `timeRange`: Specifies the empty timeRange to be inserted.
        ///
        /// 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.
        #[unsafe(method(insertEmptyTimeRange:))]
        #[unsafe(method_family = none)]
        pub unsafe fn insertEmptyTimeRange(&self, time_range: CMTimeRange);

        #[cfg(feature = "objc2-core-media")]
        /// Removes a specified timeRange from the track.
        ///
        /// Parameter `timeRange`: Specifies the timeRange to be removed.
        ///
        /// 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.
        #[unsafe(method(removeTimeRange:))]
        #[unsafe(method_family = none)]
        pub unsafe fn removeTimeRange(&self, time_range: CMTimeRange);

        #[cfg(feature = "objc2-core-media")]
        /// Changes the duration of a timeRange of the track.
        ///
        /// Parameter `timeRange`: Specifies the timeRange of the track to be scaled.
        ///
        /// Parameter `duration`: Specifies the new duration of the timeRange.
        ///
        /// Each trackSegment affected by the scaling operation will be presented at a rate equal to source.duration / target.duration of its resulting timeMapping.
        #[unsafe(method(scaleTimeRange:toDuration:))]
        #[unsafe(method_family = none)]
        pub unsafe fn scaleTimeRange_toDuration(&self, time_range: CMTimeRange, duration: CMTime);

        #[cfg(all(feature = "AVAssetTrackSegment", feature = "AVCompositionTrackSegment"))]
        /// Tests an array of AVCompositionTrackSegments to determine whether they conform to the timing rules noted above (see the property key
        /// "
        /// trackSegments").
        ///
        /// Parameter `trackSegments`: The array of AVCompositionTrackSegments to be validated.
        ///
        /// Parameter `error`: If validation fais, returns information about the failure.
        ///
        /// Returns: YES if validation suceeds, otherwise NO.
        ///
        /// 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:.
        #[unsafe(method(validateTrackSegments:error:_))]
        #[unsafe(method_family = none)]
        pub unsafe fn validateTrackSegments_error(
            &self,
            track_segments: &NSArray<AVCompositionTrackSegment>,
        ) -> Result<(), Retained<NSError>>;

        /// Establishes a track association of a specific type between two tracks.
        ///
        /// Parameter `compositionTrack`: An AVCompositionTrack object that is to be associated with the receiver.
        ///
        /// Parameter `trackAssociationType`: The type of track association to add between the receiver and the specified compositionTrack (for instance, AVTrackAssociationTypeChapterList).
        #[unsafe(method(addTrackAssociationToTrack:type:))]
        #[unsafe(method_family = none)]
        pub unsafe fn addTrackAssociationToTrack_type(
            &self,
            composition_track: &AVCompositionTrack,
            track_association_type: &AVTrackAssociationType,
        );

        /// Removes a track association of a specific type between two tracks.
        ///
        /// Parameter `compositionTrack`: An AVCompositionTrack object that is associated with the receiver.
        ///
        /// Parameter `trackAssociationType`: The type of track association to remove between the receiver and the specified compositionTrack (for instance, AVTrackAssociationTypeChapterList).
        #[unsafe(method(removeTrackAssociationToTrack:type:))]
        #[unsafe(method_family = none)]
        pub unsafe fn removeTrackAssociationToTrack_type(
            &self,
            composition_track: &AVCompositionTrack,
            track_association_type: &AVTrackAssociationType,
        );
    );
}

/// Methods declared on superclass `AVAssetTrack`.
#[cfg(feature = "AVAssetTrack")]
impl AVMutableCompositionTrack {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;

        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}

extern_class!(
    /// A format description and its replacement.
    ///
    /// Subclasses of this type that are used from Swift must fulfill the requirements of a Sendable type.
    ///
    /// See also [Apple's documentation](https://developer.apple.com/documentation/avfoundation/avcompositiontrackformatdescriptionreplacement?language=objc)
    #[unsafe(super(NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    pub struct AVCompositionTrackFormatDescriptionReplacement;
);

unsafe impl Send for AVCompositionTrackFormatDescriptionReplacement {}

unsafe impl Sync for AVCompositionTrackFormatDescriptionReplacement {}

extern_conformance!(
    unsafe impl NSCoding for AVCompositionTrackFormatDescriptionReplacement {}
);

extern_conformance!(
    unsafe impl NSObjectProtocol for AVCompositionTrackFormatDescriptionReplacement {}
);

extern_conformance!(
    unsafe impl NSSecureCoding for AVCompositionTrackFormatDescriptionReplacement {}
);

impl AVCompositionTrackFormatDescriptionReplacement {
    extern_methods!(
        #[cfg(feature = "objc2-core-media")]
        /// The original format description.
        #[unsafe(method(originalFormatDescription))]
        #[unsafe(method_family = none)]
        pub unsafe fn originalFormatDescription(&self) -> Retained<CMFormatDescription>;

        #[cfg(feature = "objc2-core-media")]
        /// The replacement format description.
        #[unsafe(method(replacementFormatDescription))]
        #[unsafe(method_family = none)]
        pub unsafe fn replacementFormatDescription(&self) -> Retained<CMFormatDescription>;
    );
}

/// Methods declared on superclass `NSObject`.
impl AVCompositionTrackFormatDescriptionReplacement {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;

        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}

/// AVMutableCompositionTrackFormatDescriptionReplacement.
#[cfg(feature = "AVAssetTrack")]
impl AVMutableCompositionTrack {
    extern_methods!(
        #[cfg(feature = "objc2-core-media")]
        /// Replaces one of the receiver's format descriptions with another format description or cancels a previous replacement.
        ///
        /// Parameter `originalFormatDescription`: A CMFormatDescription occurring in the underlying asset track.
        ///
        /// Parameter `replacementFormatDescription`: A CMFormatDescription to replace the specified format description or NULL to indicate that a previous replacement of originalFormatDescription should be cancelled.
        ///
        /// 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.
        #[unsafe(method(replaceFormatDescription:withFormatDescription:))]
        #[unsafe(method_family = none)]
        pub unsafe fn replaceFormatDescription_withFormatDescription(
            &self,
            original_format_description: &CMFormatDescription,
            replacement_format_description: Option<&CMFormatDescription>,
        );
    );
}

/// SynchronousTrackInterface.
///
/// Redeclarations of async-only AVAssetTrack interfaces to allow synchronous usage in the synchronous subclass.
///
/// See AVAssetTrack's interface for more information about these interfaces.
#[cfg(feature = "AVAssetTrack")]
impl AVCompositionTrack {
    extern_methods!(
        #[cfg(feature = "AVMediaFormat")]
        #[unsafe(method(hasMediaCharacteristic:))]
        #[unsafe(method_family = none)]
        pub unsafe fn hasMediaCharacteristic(
            &self,
            media_characteristic: &AVMediaCharacteristic,
        ) -> bool;

        #[cfg(feature = "objc2-core-media")]
        #[unsafe(method(samplePresentationTimeForTrackTime:))]
        #[unsafe(method_family = none)]
        pub unsafe fn samplePresentationTimeForTrackTime(&self, track_time: CMTime) -> CMTime;

        #[cfg(all(feature = "AVMetadataFormat", feature = "AVMetadataItem"))]
        #[unsafe(method(metadataForFormat:))]
        #[unsafe(method_family = none)]
        pub unsafe fn metadataForFormat(
            &self,
            format: &AVMetadataFormat,
        ) -> Retained<NSArray<AVMetadataItem>>;

        #[unsafe(method(associatedTracksOfType:))]
        #[unsafe(method_family = none)]
        pub unsafe fn associatedTracksOfType(
            &self,
            track_association_type: &AVTrackAssociationType,
        ) -> Retained<NSArray<AVAssetTrack>>;
    );
}