pub enum TwoDAlgorithm {
Show 20 variants
Auto,
MaxRects,
MaxRectsBestShortSideFit,
MaxRectsBestLongSideFit,
MaxRectsBottomLeft,
MaxRectsContactPoint,
Skyline,
SkylineMinWaste,
Guillotine,
GuillotineBestShortSideFit,
GuillotineBestLongSideFit,
GuillotineShorterLeftoverAxis,
GuillotineLongerLeftoverAxis,
GuillotineMinAreaSplit,
GuillotineMaxAreaSplit,
NextFitDecreasingHeight,
FirstFitDecreasingHeight,
BestFitDecreasingHeight,
MultiStart,
RotationSearch,
}Expand description
Algorithm selector for solve_2d.
Variants§
Auto
Try multiple strategies and return the best.
MaxRects
Classic MaxRects best-area-fit construction.
MaxRectsBestShortSideFit
MaxRects with best-short-side-fit placement scoring.
MaxRectsBestLongSideFit
MaxRects with best-long-side-fit placement scoring.
MaxRectsBottomLeft
MaxRects with bottom-left placement scoring.
MaxRectsContactPoint
MaxRects with contact-point placement scoring.
Skyline
Skyline-based construction.
SkylineMinWaste
Skyline construction ranked by minimum waste.
Guillotine
Guillotine beam search.
GuillotineBestShortSideFit
Guillotine beam search with best-short-side-fit candidate ranking.
GuillotineBestLongSideFit
Guillotine beam search with best-long-side-fit candidate ranking.
GuillotineShorterLeftoverAxis
Guillotine beam search with shorter-leftover-axis split selection.
GuillotineLongerLeftoverAxis
Guillotine beam search with longer-leftover-axis split selection.
GuillotineMinAreaSplit
Guillotine beam search with minimum-area split selection.
GuillotineMaxAreaSplit
Guillotine beam search with maximum-area split selection.
NextFitDecreasingHeight
Next-fit decreasing height shelf heuristic.
FirstFitDecreasingHeight
First-fit decreasing height shelf heuristic.
BestFitDecreasingHeight
Best-fit decreasing height shelf heuristic.
MultiStart
Multistart MaxRects meta-strategy.
RotationSearch
Exhaustive rotation search: enumerates all 2^k rotation assignments
for k rotatable demand types (or samples multistart_runs random
assignments when k exceeds auto_rotation_search_max_types). Uses
MaxRects best-area-fit as the inner packer.
Trait Implementations§
Source§impl Clone for TwoDAlgorithm
impl Clone for TwoDAlgorithm
Source§fn clone(&self) -> TwoDAlgorithm
fn clone(&self) -> TwoDAlgorithm
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for TwoDAlgorithm
impl Debug for TwoDAlgorithm
Source§impl Default for TwoDAlgorithm
impl Default for TwoDAlgorithm
Source§fn default() -> TwoDAlgorithm
fn default() -> TwoDAlgorithm
Source§impl<'de> Deserialize<'de> for TwoDAlgorithm
impl<'de> Deserialize<'de> for TwoDAlgorithm
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for TwoDAlgorithm
impl PartialEq for TwoDAlgorithm
Source§impl Serialize for TwoDAlgorithm
impl Serialize for TwoDAlgorithm
impl Copy for TwoDAlgorithm
impl Eq for TwoDAlgorithm
impl StructuralPartialEq for TwoDAlgorithm
Auto Trait Implementations§
impl Freeze for TwoDAlgorithm
impl RefUnwindSafe for TwoDAlgorithm
impl Send for TwoDAlgorithm
impl Sync for TwoDAlgorithm
impl Unpin for TwoDAlgorithm
impl UnsafeUnpin for TwoDAlgorithm
impl UnwindSafe for TwoDAlgorithm
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more