Skip to main content

scaled_hotspot

Function scaled_hotspot 

Source
fn scaled_hotspot(sprite: &CappedSprite, hot_x: i32, hot_y: i32) -> (i32, i32)
Expand description

Scale a source hotspot onto a delivered sprite. Consumers treat the hotspot as an offset INTO the bitmap, so the rounded coordinate is clamped to the payload rather than allowed to land one pixel past its right or bottom edge.