Skip to content

Additional PRs to core-foundation-rs #462

Open
@xanathar

Description

@xanathar

Hi,
I'm the author of #459 and #460 (which, incidentally, are blocked because the CI timed out - my guess is that it timed out independently of the PRs).

I've authored three further wrappers you might be interested into, but, given that they have a scope which is a bit broader than what's in the repo now and there are some caveats (additional dependencies or undocumented APIs), I'm asking if they are welcome or not before spending time polishing them for PR.

CGDisplayStream
Both sys and rusty wrappers around the CGDisplayStream family of APIs which allow the display contents to be streamed to an IOSurface at high speed / low cpu usage. These are documented APIs, and I think they can be of interest, but they require a couple of dependencies, as it's a CG API that directly refers IOSurface, plus it uses objective-c blocks (and so needs block crate ).

CGS Display calls
These are wrappers around Display calls starting with "CGS"; they are undocumented API calls which are generally useful to manipulate displays on MacOS. Examples are enumerating all the displays, or getting access to video modes which are not exposed to the UI. There are both the sys/ffi wrappers and the "rusty" ones, but the calls are, again, not documented by Apple.

CGVirtualDisplay
Again, a wrapper over undocumented APIs which allow to create virtual displays on MacOS; I think they are the APIs Apple uses to support Sidecar. Controversy here is the undocumented status.

Let me know if you are interested in a PR for any subset of them, and I'll open those.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions