seanchas116 / SimpleDALPlugin

Simple CoreMediaIO DAL virtual camera plugin example written in Swift
MIT License
149 stars 19 forks source link

How to send a stream from an other application into the plugin #9

Open maxencedouet opened 4 years ago

maxencedouet commented 4 years ago

Hello Ryohei,

First, thank you very much for this simple exemple simply customisable.

I would love to use this plugin in an other application in order to be able to send stream into it. (node best but swift app ok)

Do you know how I could do ?

Thank you very much for your help

Maxence

sivrish commented 4 years ago

I've similar question. I know that we have to use some IPC to do it. but my question is how xpc will deliver the frames received from the app to the plugin ?

ldenoue commented 4 years ago

What I ended up doing was capturing a NSWindow from inside the Plugin, at an interval. That's because my application needed to send the contents of a NSWindow opened on the desktop in an accompanying Mac OS app. Note that this window being captured by the plugin needs not be visible: so you could do all your composition in this "hidden" NSWindow, and your plugin would still be able to capture its bitmap.

Raj123456788 commented 4 years ago

@sivrish: May be this will be helpful https://github.com/PhilippMatthes/neural-greenscreen

sivrish commented 4 years ago

@Raj123456788 thanks, but I want to implement something like SnapChat did on their Snap Camera. They used XPC to communicate between the App and the plugin. But I'm confused on how to create a connection using that.

Raj123456788 commented 4 years ago

@sivrish: Is there a repository where I can look into your code? I was trying the same but never got a headway. See if this helps: https://github.com/zakk4223/CSVirtualCamera/issues/3

sivrish commented 3 years ago

@Raj123456788 have you implemented the vcam successfully ?

Raj123456788 commented 3 years ago

Hi @sivrish : I followed https://github.com/knightbenax/Cobalt and it works.

sivrish commented 3 years ago

That's a great news! @Raj123456788 Can you DM me on twitter @sivrish and I have to ask few details about vcam instead of me spamming the issue section here ?

adamgf commented 3 years ago

How do I add a microphone?