Electrolysis/Mac
Getting multi-process working on mac:
- Adding Cocoa NPAPI -- spec shared with Safari
- Eliminate all native objects except for the graphics context, no window handles
- Need to support the carbon event model for at least one major release
- Adding CoreAnimation Drawing Model
- CoreAnimation is available on 10.5 and 10.6
- Cross-process sharing may only be available on 10.6
- Big plus is being able to use OpenGL
CoreGraphics cross-process sharing can be done on 10.5
Apple is planning on doing cross-process only for 64-bit safari: it will load 64-bit plugins out of process, and also a select whitelisted set of 32-bit plugins. 32-bit Safari will only load 32-bit plugins, and will do it only in-process.
How do you pass CoreGraphics handles across processes:
- (not sure about this, need experiments) Use multiple CGContextRefs in both processes, writing to the same CGBitmapRef from both processes...
For tab processes:
Since we're not sharing actual drawing tasks, we don't need the performance benefits of CoreAnimation: the content process will have full drawing responsibility in the content widget.
Question: will we be able to have a content process with a native widget and event loop but no dock icon? [need investigation]
Test application:
Parent process has an outer window Launches a sub process Sub process draws a movie into a child window Keep the two windows in sync/moving with eachother The menus need to be correct even when focus is in the movie...