Skip to main content

clip_inside

Function clip_inside 

Source
pub fn clip_inside(shape: &ClipShape, ox: i32, oy: i32) -> bool
Expand description

Returns true if point (ox, oy) in element-local pixels is inside the clip shape. 計算量: O(V) — V は多角形の頂点数(polygon() の場合)。 円・楕円・矩形は O(1)。 毎ピクセル呼ばれるため、多角形クリップは面積 × 頂点数で効く。