zakk4223 / CSVirtualCamera

CocoaSplit Virtual Camera plugin
Other
13 stars 0 forks source link

Issue while connecting to plugin using XPC #4

Closed sivrish closed 3 years ago

sivrish commented 4 years ago

I'm trying to connect to your plugin from my mac app using your code on SDK folder. But I'm getting the following error while trying to do it.

Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service on pid 0 named com.sivrish.vcam.assistant was invalidated." UserInfo={NSDebugDescription=The connection to service on pid 0 named com.sivrish.vcam.assistant was invalidated.}

Have you ever faced this issue ? I've also attached screenshots of my LaunchAgents plist and also my app entitlement file here.

Entitlement LaunchAgentsPlist

Also, this plugin is not identified by any apps or even cameo ( https://github.com/lvsti/Cameo )

Tested on macOS 10.15.7 & Xcode 11.7, 12.0.1

Thanks in advance.

zakk4223 commented 4 years ago

Did you compile your own version of the XPC service? Unfortunately the program that LaunchAgent launches has to create the mach service with the same name as the one in the plist. So if you're using the provided binaries you can't just arbitrarily change the mach service name in the LaunchAgent config.

Maybe it would be a good idea to modify the launch agent code so it can take the mach service name as a command line argument...

sivrish commented 4 years ago

I'm trying to replicate what you did with https://github.com/johnboiles/coremediaio-dal-minimal-example and add an assistant just like you did on your project. can you help me with understanding when and how the assistant is getting started ?