objc2_av_foundation/generated/AVVideoPerformanceMetrics.rs
1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 /// [SPI] An instance of AVVideoPerformanceMetrics provides current performance metrics.
12 ///
13 /// An instance of AVVideoPerformanceMetrics provides named properties for accessing the video playback quality metrics.
14 /// Subclasses of this type that are used from Swift must fulfill the requirements of a Sendable type.
15 ///
16 /// See also [Apple's documentation](https://developer.apple.com/documentation/avfoundation/avvideoperformancemetrics?language=objc)
17 #[unsafe(super(NSObject))]
18 #[derive(Debug, PartialEq, Eq, Hash)]
19 pub struct AVVideoPerformanceMetrics;
20);
21
22unsafe impl Send for AVVideoPerformanceMetrics {}
23
24unsafe impl Sync for AVVideoPerformanceMetrics {}
25
26unsafe impl NSObjectProtocol for AVVideoPerformanceMetrics {}
27
28impl AVVideoPerformanceMetrics {
29 extern_methods!(
30 #[unsafe(method(init))]
31 #[unsafe(method_family = init)]
32 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
33
34 #[unsafe(method(new))]
35 #[unsafe(method_family = new)]
36 pub unsafe fn new() -> Retained<Self>;
37
38 /// [SPI] The total number of frames that would have been displayed if no frames are dropped.
39 #[unsafe(method(totalNumberOfFrames))]
40 #[unsafe(method_family = none)]
41 pub unsafe fn totalNumberOfFrames(&self) -> NSInteger;
42
43 /// [SPI] The total number of frames dropped prior to decoding or dropped because a frame missed its display deadline.
44 #[unsafe(method(numberOfDroppedFrames))]
45 #[unsafe(method_family = none)]
46 pub unsafe fn numberOfDroppedFrames(&self) -> NSInteger;
47
48 /// [SPI] The total number of corrupted frames that have been detected.
49 #[unsafe(method(numberOfCorruptedFrames))]
50 #[unsafe(method_family = none)]
51 pub unsafe fn numberOfCorruptedFrames(&self) -> NSInteger;
52
53 /// [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.
54 #[unsafe(method(numberOfFramesDisplayedUsingOptimizedCompositing))]
55 #[unsafe(method_family = none)]
56 pub unsafe fn numberOfFramesDisplayedUsingOptimizedCompositing(&self) -> NSInteger;
57
58 /// [SPI] The accumulated amount of time between the prescribed presentation times of displayed video frames and the actual time at which they were displayed.
59 ///
60 /// 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.
61 #[unsafe(method(totalAccumulatedFrameDelay))]
62 #[unsafe(method_family = none)]
63 pub unsafe fn totalAccumulatedFrameDelay(&self) -> NSTimeInterval;
64
65 /// [SPI] The total number of frames that would have been displayed if no frames are dropped. Same as totalNumberOfFrames.
66 #[unsafe(method(totalNumberOfVideoFrames))]
67 #[unsafe(method_family = none)]
68 pub unsafe fn totalNumberOfVideoFrames(&self) -> c_ulong;
69
70 /// [SPI] The total number of frames dropped prior to decoding or dropped because a frame missed its display deadline. Same as numberOfDroppedFrames.
71 #[unsafe(method(numberOfDroppedVideoFrames))]
72 #[unsafe(method_family = none)]
73 pub unsafe fn numberOfDroppedVideoFrames(&self) -> c_ulong;
74
75 /// [SPI] The total number of corrupted frames that have been detected. Same as numberOfCorruptedFrames.
76 #[unsafe(method(numberOfCorruptedVideoFrames))]
77 #[unsafe(method_family = none)]
78 pub unsafe fn numberOfCorruptedVideoFrames(&self) -> c_ulong;
79
80 /// [SPI] The total number of frames that were composited in detached mode. Same as numberOfFramesDisplayedUsingOptimizedCompositing.
81 #[unsafe(method(numberOfDisplayCompositedVideoFrames))]
82 #[unsafe(method_family = none)]
83 pub unsafe fn numberOfDisplayCompositedVideoFrames(&self) -> c_ulong;
84
85 /// [SPI] The total number of frames that were composited in undetached mode.
86 #[unsafe(method(numberOfNonDisplayCompositedVideoFrames))]
87 #[unsafe(method_family = none)]
88 pub unsafe fn numberOfNonDisplayCompositedVideoFrames(&self) -> c_ulong;
89
90 /// [SPI] The accumulated amount of time, in microseconds, between the prescribed presentation times of displayed video frames and the actual time at which they were displayed.
91 ///
92 /// 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. Same as totalAccumulatedFrameDelay.
93 #[unsafe(method(totalFrameDelay))]
94 #[unsafe(method_family = none)]
95 pub unsafe fn totalFrameDelay(&self) -> c_double;
96 );
97}