cairoRegionCreateFromSurface

fncairo.region.Region cairoRegionCreateFromSurface(cairo.surface.Surface surface)

Creates region that describes covers the area where the given surface is more than 50% opaque.

This function takes into account device offsets that might be set with cairo.surface.Surface.setDeviceOffset.

Parameters

surfacea cairo surface

Returns

A #cairo_region_t; must be freed with cairo.region.Region.destroy