Skip to main content

draw_image_nn_blit

Function draw_image_nn_blit 

Source
pub(super) fn draw_image_nn_blit(
    screen: &Screen,
    img: &DecodedImage,
    x0: i32,
    y0: i32,
    dst_w: u32,
    dst_h: u32,
)
Expand description

list-style-image 用の小さな画像を (x0,y0) を左上として dst_w x dst_h へ最近傍スケーリング して描画する。クリップ・object-fit 等は考慮しない簡易実装(マーカーサイズのアイコン用途)。