2

I've been using VLCJ to embed a number of media players in the same window - on Windows and Linux this works fine, because they can be out of process (which they need to be to be stable - in short because of native libraries underneath there's no way round this) and just alter the window in the other process.

However, does this out of process approach work on MacOS? The information I've found seems to suggest that it's not possible the way it is on Windows / Linux, but there's possibly some native call that can be made from one process to allow it to be controlled from another. Is this the case, and if so has anyone more information on any native code that might allow it to be the case? Apologies for the sparse information, I haven't got a Mac available to test on at the moment so can't run anything to try it out and see what happens!

Michael Berry
  • 61,291
  • 17
  • 134
  • 188

1 Answers1

1

It is possible to play video out-of-process in OS X 10.6 and later. The CoreVideo IOSurface API appears to allow this capability, though documentation is very sparse. This blog post on the subject may be a good place to start.

For IPC communication, you can use NSDistributedNotificationCenter for basic (string) messages, or Distributed Objects or the new XPC framework in 10.7. I'm not sure how accessible these technologies are from Java.

Barry Wark
  • 105,416
  • 24
  • 177
  • 204
  • Thanks for the answer. I've got an out of process framework playing videos already that works on Linux or Windows which just passes the component ID around and uses that to play the video out of process. Do you know if that approach would work in OSX, or could be made to work? It'd be nice to use something along those lines if possible. As you point out though documentation is not exactly abundant! :( – Michael Berry Aug 02 '11 at 16:12