Struct crunch::PackedItem
source · pub struct PackedItem<T> {
pub data: T,
pub rect: Rect,
}Expand description
An item that has been packed into a container.
Fields§
§data: TThe data associated with the item.
rect: RectThe position where the item was packed.
If the item was packed with Rotation::Allowed, you can compare
the rectangle’s width with the input width you provided. If they
differ, it means the item was rotated to fit better.