pub struct TilePlacement {
pub index: usize,
pub count: usize,
pub origin: (f32, f32),
pub crop_size: (f32, f32),
pub letterbox: Option<[f32; 4]>,
pub frame_dims: (f32, f32),
}Expand description
One tile’s placement within a frame grid.
Produced by edgefirst_image::ImageProcessor::plan_tiles and consumed by
edgefirst_decoder::tiling to lift per-tile detections back to full-frame
coordinates. It lives here because it is the contract between those two
crates: it was previously defined in decoder and re-exported by image,
so the producer imported its own output type from its consumer.
Fields§
§index: usizeTile index within the frame grid, 0..count.
count: usizeTotal tiles for this frame (the streaming fan-in fence).
origin: (f32, f32)Native crop origin (ox, oy) in full-frame pixels.
crop_size: (f32, f32)Native crop size (cw, ch) in full-frame pixels. Equals the tile size
for the full-size tiles the EvenDist grid produces.
letterbox: Option<[f32; 4]>Normalized letterbox content bounds [lx0, ly0, lx1, ly1] on the model
input, or None when the crop was stretched to fill it (the hot path).
frame_dims: (f32, f32)Full-frame dimensions (frame_w, frame_h) in pixels.
Trait Implementations§
Source§impl Clone for TilePlacement
impl Clone for TilePlacement
Source§fn clone(&self) -> TilePlacement
fn clone(&self) -> TilePlacement
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more