Peter Amstutz has done some work which may help.

You can find his Mozilla patch here
<http://interreality.org/wwwvos/projects/crystalzilla> - it adds new
gfx and widget components for Mozilla that rendered to an off-screen
buffer. The code is apparently about 6 months old, so you may have
trouble integrating it with the current source base.

The big problem, as with any of the other solutions I've found, is
plugins. These use a relatively old Netscape API, which is very
window-centric. The upshot of which is that it's a bit hard to capture
the output of plugins. You may or may not care about this!

If you aren't tied to a Win32 platform, some people have mentioned
X-Windows as a possible solution. I haven't pursued this personally as
I am tied to Win32!

The solution I'm aiming for right now is a plain old screen-capture -
just grab the output of the Mozilla window back from the screen once
it's done it's drawing. It's a bit of an ugly hack, and has problems.
For animations you need to be able to detect when a plugin has drawn
some new content into the window, and I haven't been able to figure out
how to do it. You can obviously try to just keep capturing the whole
window as often as possible, but the danger is that you'll get tearing
effects because you might capture the window when a plugin is halfway
through updating it.

If anyone knows where in the source code Mozilla gives time to plugins
to do their rendering (if indeed it works that way), that would be a
helpful bit of information! It may be that plugins do their rendering
asynchronously, in which case I'm probably in trouble!

_______________________________________________
mozilla-embedding mailing list
[email protected]
http://mail.mozilla.org/listinfo/mozilla-embedding

Reply via email to