WIP
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import Foundation
|
||||
import LiveKit
|
||||
import WebRTC
|
||||
import ScreenCaptureKit
|
||||
|
||||
class LKRoomDelegate: RoomDelegate {
|
||||
var data: UnsafeRawPointer
|
||||
@@ -154,3 +155,19 @@ public func LKDisplaySources(data: UnsafeRawPointer, callback: @escaping @conven
|
||||
callback(data, nil, error.localizedDescription as CFString)
|
||||
}
|
||||
}
|
||||
|
||||
@_cdecl("LKDisplays")
|
||||
public func LKDisplays() {
|
||||
if #available(macOS 12.3, *) {
|
||||
Task.init {
|
||||
let content = try await SCShareableContent.current
|
||||
print(content.displays.count)
|
||||
}
|
||||
|
||||
// SCShareableContent.getWithCompletionHandler { content, error in
|
||||
// print(content!.displays.count)
|
||||
// }
|
||||
} else {
|
||||
print("OOOPS")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user