|
10 | 10 | #import <ScreenCaptureKit/ScreenCaptureKit.h> |
11 | 11 |
|
12 | 12 | API_AVAILABLE(macos(12.3)) |
13 | | -@interface SCCapture : NSObject <SCStreamDelegate, SCStreamOutput> |
| 13 | +@interface SCCapture: NSObject <SCStreamDelegate, SCStreamOutput> |
14 | 14 |
|
15 | 15 | #define kMaxDisplays 32 |
16 | 16 |
|
17 | 17 | typedef bool (^VideoFrameCallbackBlock)(CMSampleBufferRef); |
18 | 18 |
|
19 | | -@property(nonatomic, assign) CGDirectDisplayID displayID; |
20 | | -@property(nonatomic, assign) int frameRate; |
21 | | -@property(nonatomic, assign) OSType pixelFormat; |
22 | | -@property(nonatomic, assign) int frameWidth; |
23 | | -@property(nonatomic, assign) int frameHeight; |
| 19 | +@property (nonatomic, assign) CGDirectDisplayID displayID; |
| 20 | +@property (nonatomic, assign) int frameRate; |
| 21 | +@property (nonatomic, assign) OSType pixelFormat; |
| 22 | +@property (nonatomic, assign) int frameWidth; |
| 23 | +@property (nonatomic, assign) int frameHeight; |
24 | 24 |
|
25 | | -@property(nonatomic, strong) SCStream *stream; |
26 | | -@property(nonatomic, strong) SCShareableContent *shareableContent; |
27 | | -@property(nonatomic, strong) dispatch_queue_t videoQueue; |
| 25 | +@property (nonatomic, strong) SCStream *stream; |
| 26 | +@property (nonatomic, strong) SCShareableContent *shareableContent; |
| 27 | +@property (nonatomic, strong) dispatch_queue_t videoQueue; |
28 | 28 |
|
29 | | -@property(nonatomic, copy) VideoFrameCallbackBlock videoCallback; |
30 | | -@property(nonatomic, strong) dispatch_semaphore_t captureSignal; |
31 | | -@property(nonatomic, assign) BOOL stopping; |
32 | | -@property(nonatomic, assign) CMSampleBufferRef lastValidSampleBuffer; |
| 29 | +@property (nonatomic, copy) VideoFrameCallbackBlock videoCallback; |
| 30 | +@property (nonatomic, strong) dispatch_semaphore_t captureSignal; |
| 31 | +@property (nonatomic, assign) BOOL stopping; |
| 32 | +@property (nonatomic, assign) CMSampleBufferRef lastValidSampleBuffer; |
33 | 33 |
|
34 | 34 | + (BOOL)isAvailable; |
35 | 35 | + (NSArray<NSDictionary *> *)displayNames; |
|
0 commit comments