mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice-common
synced 2025-12-26 05:26:09 +00:00
region: add region_extents
This commit is contained in:
parent
cbf423f833
commit
178c7eaff6
@ -386,6 +386,17 @@ void region_ret_rects(const QRegion *rgn, SpiceRect *rects, uint32_t num_rects)
|
||||
}
|
||||
}
|
||||
|
||||
void region_extents(const QRegion *rgn, SpiceRect *r)
|
||||
{
|
||||
pixman_box32_t *extents;
|
||||
|
||||
extents = pixman_region32_extents((pixman_region32_t *)rgn);
|
||||
|
||||
r->left = extents->x1;
|
||||
r->top = extents->y1;
|
||||
r->right = extents->x2;
|
||||
r->bottom = extents->y2;
|
||||
}
|
||||
|
||||
int region_is_equal(const QRegion *rgn1, const QRegion *rgn2)
|
||||
{
|
||||
|
||||
@ -41,6 +41,7 @@ void region_destroy(QRegion *rgn);
|
||||
void region_clone(QRegion *dest, const QRegion *src);
|
||||
SpiceRect *region_dup_rects(const QRegion *rgn, uint32_t *num_rects);
|
||||
void region_ret_rects(const QRegion *rgn, SpiceRect *rects, uint32_t num_rects);
|
||||
void region_extents(const QRegion *rgn, SpiceRect *r);
|
||||
|
||||
int region_test(const QRegion *rgn, const QRegion *other_rgn, int query);
|
||||
int region_is_valid(const QRegion *rgn);
|
||||
@ -61,6 +62,7 @@ void region_remove(QRegion *rgn, const SpiceRect *r);
|
||||
|
||||
void region_offset(QRegion *rgn, int32_t dx, int32_t dy);
|
||||
|
||||
|
||||
void region_dump(const QRegion *rgn, const char *prefix);
|
||||
|
||||
SPICE_END_DECLS
|
||||
|
||||
Loading…
Reference in New Issue
Block a user