![]() |
![]() |
![]() |
Mx Toolkit Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Implemented Interfaces | Properties |
struct MxOffscreen; struct MxOffscreenClass; ClutterActor * mx_offscreen_new (void
); void mx_offscreen_set_child (MxOffscreen *offscreen
,ClutterActor *actor
); ClutterActor * mx_offscreen_get_child (MxOffscreen *offscreen
); void mx_offscreen_set_pick_child (MxOffscreen *offscreen
,gboolean pick
); gboolean mx_offscreen_get_pick_child (MxOffscreen *offscreen
); void mx_offscreen_set_auto_update (MxOffscreen *offscreen
,gboolean auto_update
); gboolean mx_offscreen_get_auto_update (MxOffscreen *offscreen
); void mx_offscreen_set_redirect_enabled (MxOffscreen *offscreen
,gboolean enabled
); gboolean mx_offscreen_get_redirect_enabled (MxOffscreen *offscreen
); CoglHandle mx_offscreen_get_buffer (MxOffscreen *offscreen
); void mx_offscreen_update (MxOffscreen *offscreen
); void mx_offscreen_set_accumulation_enabled (MxOffscreen *offscreen
,gboolean enable
); gboolean mx_offscreen_get_accumulation_enabled (MxOffscreen *offscreen
); CoglHandle mx_offscreen_get_accumulation_material (MxOffscreen *offscreen
);
GObject +----GInitiallyUnowned +----ClutterActor +----ClutterTexture +----MxOffscreen
MxOffscreen implements ClutterContainer, ClutterScriptable, ClutterAnimatable, AtkImplementorIface and MxFocusable.
"accumulation-enabled" gboolean : Read / Write "accumulation-material" gpointer : Read "auto-update" gboolean : Read / Write "buffer" gpointer : Read "child" ClutterActor* : Read / Write "pick-child" gboolean : Read / Write "redirect-enabled" gboolean : Read / Write
MxOffscreen allows you to redirect the painting of a ClutterActor to a texture. It can either contain this actor, or optionally, it can redirect the painting of an actor that it does not contain.
This is often useful for applying a ClutterShader effect to an actor or group of actors that is not a texture.
struct MxOffscreen;
The contents of this structure is private and should only be accessed using the provided API.
struct MxOffscreenClass { ClutterTextureClass parent_class; /* vfuncs */ void (* paint_child) (MxOffscreen *self); /* padding for future expansion */ void (*_padding_0) (void); void (*_padding_1) (void); void (*_padding_2) (void); void (*_padding_3) (void); void (*_padding_4) (void); };
ClutterActor * mx_offscreen_new (void
);
Creates a new MxOffscreen.
Returns : |
a newly allocated MxOffscreen |
void mx_offscreen_set_child (MxOffscreen *offscreen
,ClutterActor *actor
);
Redirects the painting of actor
to the offscreen surface owned by
offscreen
. In the event that actor
is unparented, it will be parented
to offscreen
. Note that when you redirect the painting of actor
, it
will no longer be painted in its original position in the scenegraph.
|
A MxOffscreen |
|
A ClutterActor |
ClutterActor * mx_offscreen_get_child (MxOffscreen *offscreen
);
Gets the value of the "child" property.
|
A MxOffscreen |
Returns : |
The child of the offscreen widget. [transfer none] |
void mx_offscreen_set_pick_child (MxOffscreen *offscreen
,gboolean pick
);
Enable picking of the child actor.
|
A MxOffscreen |
|
TRUE to enable picking of the child actor |
gboolean mx_offscreen_get_pick_child (MxOffscreen *offscreen
);
Gets the value of the "pick-child" property.
|
A MxOffscreen |
Returns : |
TRUE if picking of the child is enabled. |
void mx_offscreen_set_auto_update (MxOffscreen *offscreen
,gboolean auto_update
);
Enable automatic updating of the offscreen surface when the child is updated.
|
A MxOffscreen |
|
TRUE if the offscreen surface should be automatically updated |
gboolean mx_offscreen_get_auto_update (MxOffscreen *offscreen
);
Gets the value of the "auto-update" property.
|
A MxOffscreen |
Returns : |
TRUE if automatic updating of the offscreen surface is enabled |
void mx_offscreen_set_redirect_enabled (MxOffscreen *offscreen
,gboolean enabled
);
Sets the value of the "redirect-enabled" property. When
redirection is enabled, the painting of the child of offscreen
will be
redirected to the texture of offscreen
.
|
A MxOffscreen |
|
TRUE if redirection to the offscreen surface should be enabled |
Since 1.2
gboolean mx_offscreen_get_redirect_enabled (MxOffscreen *offscreen
);
Gets the value of the "redirect-enabled" property.
|
A MxOffscreen |
Returns : |
TRUE if offscreen redirection is enabled |
Since 1.2
CoglHandle mx_offscreen_get_buffer (MxOffscreen *offscreen
);
Gets the value of the "buffer" property.
|
A MxOffscreen |
Returns : |
the CoglHandle for the offscreen buffer object. [transfer none] |
Since 1.2
void mx_offscreen_update (MxOffscreen *offscreen
);
Updates the offscreen surface. This causes the child of offscreen
to be
drawn into the texture of offscreen
.
|
A MxOffscreen |
void mx_offscreen_set_accumulation_enabled (MxOffscreen *offscreen
,gboolean enable
);
Sets whether the accumulation buffer is enabled. When enabled, an extra offscreen buffer is allocated, and the contents of the offscreen texture are blended with this accumulation buffer. By default, the blend function is set to blend the contents of the offscreen texture with the accumulation buffer at the opacity specified in the alpha component of the blend constant. This opacity is 50% by default.
|
A MxOffscreen |
|
TRUE to enable an accumulation buffer |
Since 1.2
gboolean mx_offscreen_get_accumulation_enabled
(MxOffscreen *offscreen
);
Gets the value of the "accumulation-enabled" property.
|
A MxOffscreen |
Returns : |
TRUE if the accumulation buffer is enabled |
Since 1.2
CoglHandle mx_offscreen_get_accumulation_material
(MxOffscreen *offscreen
);
Gets the "accumulation-material" property.
|
A MxOffscreen |
Returns : |
The CoglHandle for the material used for the accumulation buffer. [transfer none] |
Since 1.2
"accumulation-enabled"
property "accumulation-enabled" gboolean : Read / Write
Enable an accumulation buffer via a secondary buffer.
Default value: FALSE
"accumulation-material"
property "accumulation-material" gpointer : Read
Material used for the accumulation buffer.
"auto-update"
property "auto-update" gboolean : Read / Write
Update child actor automatically when painting.
Default value: TRUE
"pick-child"
property "pick-child" gboolean : Read / Write
Whether to pick the child.
Default value: FALSE