Skip to content

Pack a box up to a certain volume? #216

Answered by dvdoug
eastpiada asked this question in Q&A
Discussion options

You must be logged in to vote

Hello

There's no built-in mechanism for doing something like that, but depending on how precise you want to be, either of the following should be feasible.

  1. Reduce the "inner" dimensions of each box by a couple of centimetres to ensure space for the additional protective packaging
  2. You could also do something with the custom constraint system (https://www.boxpacker.io/en/stable/advanced-usage.html#custom-constraints) - that doesn't give you the PackedBox and its helper methods (I'll look into changing that at the next major version bump), but you should be able to work out the current packed volume anyway to make a decision with

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@eastpiada
Comment options

@dvdoug
Comment options

@eastpiada
Comment options

@dvdoug
Comment options

Answer selected by eastpiada
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants