When optimising the first proof of concept, a major problem shows: It works fine as long as the content to capture is onscreen. As I said, I'm streaming, I'm creating content that is not meant to be shown on the Mac screen. There is just a window controlling the scoreboard. As soon the capture window is offscreen, the output is stopped. macOS does not want to waste computing power rendering invisible screens. The interface of
SCShareableContent.excludingDesktopWindows(true, onScreenWindowsOnly: false)
is misleading here. It means "partially offscreen windows". Windows completely offscreen will not even be offered as possible content.
All I can do is keeping a pixel of the output window onscreen and change it frequently, but first of all this is tinkering around and secondly the animations get jerky.
Is there no way to prevent macOS from "optimising" the rendering this way?
And if not, what would be another approach? Forget about the macOS animations and do everything yourself?
Topic:
Graphics & Games
SubTopic:
General