Skip to main content

blend_tile_into_accum

Function blend_tile_into_accum 

Source
pub fn blend_tile_into_accum(
    tile_rgb: &[u8],
    rect: TileRect,
    scale: u8,
    overlap: u32,
    out_w: u32,
    out_h: u32,
    accum: &mut [f32],
    weight: &mut [f32],
) -> Result<(), CvError>
Expand description

Blend one already scaled tile into float accumulators.

  • tile_rgb: packed RGB of size (rect.w * scale) × (rect.h * scale) × 3
  • rect: input-space tile that produced this tile
  • overlap: input-space overlap used in the plan (feather width ≈ overlap * scale)
  • accum: RGB interleaved f32, length ≥ out_w * out_h * 3 (caller zeros once)
  • weight: per-pixel f32, length ≥ out_w * out_h

After all tiles, call finalize_blend.