WIP
This commit is contained in:
parent
9b8e6cce02
commit
db8b8ef66b
5 changed files with 30 additions and 0 deletions
|
@ -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")
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue