On Sat, 2009-01-31 at 00:16 +0100, Jörn Reder wrote:
> Hiho,
>
> two weeks ago I resurrected an old thread ("Transparent stage?...")
> about how to manage a fully transparent Clutter toplevel window to do
> OSD like stuff on a composited X11 desktop. Unfortunately responds were
> rare (not to say none ;). I know you guys are busy (for example to
> publish the 0.9 release ;), but since this issue gets more important for
> me I just give it another try.
>
> The story so far: at that time Emmanuele suggested creating an ARGB
> window and use clutter_x11_set_stage_foreign() on it. Since I like to do
> this with the Perl bindings and this function is not bound
it is not bound because there is no C based binding for the X libraries
-- only a Perl reimplementation of the X11 protocol. while sharing might
be possible (though I haven't investigated it) it could lead to weird
results and I don't want to commit myself to support something that I
can't verify as working.
if you provide a patch for the clutter-perl bindings to expose those
methods (under the Clutter::X11 namespace, for instance) and you verify
that they work, then I'll consider pushing it upstream.
> I tried
> Gtk2::ClutterEmbed (which internally uses
> clutter_x11_set_stage_foreign() to attach the clutter stage to the embed
> window). But this didn't work,
yes, because Gtk2::ClutterEmbed uses its own window -- and it does so
internally on two different platforms.
you cannot reuse Gtk2::ClutterEmbed, but you can use the GtkClutterEmbed
code in C and then provide Perl bindings for it.
what you need to do is create a small C library that implements a
subclass of ClutterStage and calls clutter_x11_stage_set_foreign()
inside the realize() virtual function -- after you chained up to the
parent implementation.
then write the Perl bindings using the perl-Glib machinery that
clutter-perl uses, and use the custom class inside your Perl code.
ciao,
Emmanuele.
--
Emmanuele Bassi, Intel Open Source Technology Center
--
To unsubscribe send a mail to [email protected]