mirror of
https://github.com/brl/mutter.git
synced 2024-11-13 01:36:10 -05:00
paint_volume: Adds _clutter_paint_volume_set_from_volume
This adds a way to initialize a paint volume from another source paint volume. This lets us for instance pass the contents of one paint volume back through the out param of a get_paint_volume implementation.
This commit is contained in:
parent
bfacca3011
commit
2d895816be
@ -150,6 +150,18 @@ clutter_paint_volume_copy (const ClutterPaintVolume *pv)
|
||||
return copy;
|
||||
}
|
||||
|
||||
void
|
||||
_clutter_paint_volume_set_from_volume (ClutterPaintVolume *pv,
|
||||
const ClutterPaintVolume *src)
|
||||
{
|
||||
if (src->actor != pv->actor)
|
||||
{
|
||||
g_object_unref (pv->actor);
|
||||
g_object_ref (src->actor);
|
||||
}
|
||||
memcpy (pv, src, sizeof (ClutterPaintVolume));
|
||||
}
|
||||
|
||||
/**
|
||||
* clutter_paint_volume_free:
|
||||
* @pv: a #ClutterPaintVolume
|
||||
|
@ -510,6 +510,9 @@ void _clutter_paint_volume_init_static (ClutterActor *actor,
|
||||
ClutterPaintVolume *_clutter_paint_volume_new (ClutterActor *actor);
|
||||
void _clutter_paint_volume_copy_static (const ClutterPaintVolume *src_pv,
|
||||
ClutterPaintVolume *dst_pv);
|
||||
void _clutter_paint_volume_set_from_volume (ClutterPaintVolume *pv,
|
||||
const ClutterPaintVolume *src);
|
||||
|
||||
void _clutter_paint_volume_complete (ClutterPaintVolume *pv);
|
||||
void _clutter_paint_volume_transform (ClutterPaintVolume *pv,
|
||||
const CoglMatrix *matrix);
|
||||
|
Loading…
Reference in New Issue
Block a user