Skip to main content

apply_layer_affine_to_point

Function apply_layer_affine_to_point 

Source
pub fn apply_layer_affine_to_point(
    point: Point,
    layer_bounds: Rect,
    layer: &GraphicsLayer,
) -> Point
Expand description

Point counterpart of apply_layer_affine_to_rect: scale about the layer pivot, then translate. Rotation/perspective are deliberately excluded — the affine space is the one SDF shapes are evaluated in, with rotation carried by the deformed quad instead.