#include <rect_packer.h>
Classes | |
class | ComparisonFunctor |
class | Stat |
Static Public Member Functions | |
static bool | Pack (const std::vector< Box2x > &rectVec, const Point2i containerSizeX, std::vector< Similarity2x > &trVec, Point2x &coveredContainer) |
the sub portion of the container covered by the solution. | |
static bool | PackMulti (const std::vector< Box2x > &rectVec, const Point2i containerSizeI, const int containerNum, std::vector< Similarity2x > &trVec, std::vector< int > &indVec, std::vector< Point2x > &coveredContainer) |
the sub portion of the container covered by the solution. | |
static bool | PackOccupancy (const std::vector< Box2x > &rectVec, const Point2i containerSizeX, const SCALAR_TYPE occupancyRatio, std::vector< Similarity2x > &trVec, Point2x &coveredContainer) |
the sub portion of the container covered by the solution. | |
static bool | PackOccupancyMulti (const std::vector< Box2x > &rectVec, const Point2i containerSizeX, const int containerNum, const SCALAR_TYPE occupancyRatio, std::vector< Similarity2x > &trVec, std::vector< int > &indVec, std::vector< Point2x > &coveredContainer) |
the sub portion of the container covered by the solution. | |
static Stat & | stat () |
Private Types | |
typedef vcg::Box2< SCALAR_TYPE > | Box2x |
typedef vcg::Point2< SCALAR_TYPE > | Point2x |
typedef vcg::Similarity2 < SCALAR_TYPE > | Similarity2x |
Static Private Member Functions | |
static bool | PackInt (const std::vector< vcg::Point2i > &sizes, const vcg::Point2i &max_size, std::vector< vcg::Point2i > &posiz, vcg::Point2i &global_size) |
static bool | PackIntMulti (const std::vector< Point2i > &sizes, const int ntexture, const vcg::Point2i &max_size, std::vector< Point2i > &posiz, std::vector< int > &texin, std::vector< Point2i > &globalsize) |
Definition at line 38 of file rect_packer.h.
typedef vcg::Box2<SCALAR_TYPE> vcg::RectPacker< SCALAR_TYPE >::Box2x [private] |
Definition at line 40 of file rect_packer.h.
typedef vcg::Point2<SCALAR_TYPE> vcg::RectPacker< SCALAR_TYPE >::Point2x [private] |
Definition at line 41 of file rect_packer.h.
typedef vcg::Similarity2<SCALAR_TYPE> vcg::RectPacker< SCALAR_TYPE >::Similarity2x [private] |
Definition at line 42 of file rect_packer.h.
static bool vcg::RectPacker< SCALAR_TYPE >::Pack | ( | const std::vector< Box2x > & | rectVec, |
const Point2i | containerSizeX, | ||
std::vector< Similarity2x > & | trVec, | ||
Point2x & | coveredContainer | ||
) | [inline, static] |
the sub portion of the container covered by the solution.
containerSizeX | the set of rectangles that have to be packed (generic floats, no req.) |
trVec | the size of the container where they has to be fitted (usually in pixel size) |
coveredContainer | the result, a set of similarity transformation that have to be applied to the rect to get their position |
Definition at line 62 of file rect_packer.h.
static bool vcg::RectPacker< SCALAR_TYPE >::PackInt | ( | const std::vector< vcg::Point2i > & | sizes, |
const vcg::Point2i & | max_size, | ||
std::vector< vcg::Point2i > & | posiz, | ||
vcg::Point2i & | global_size | ||
) | [inline, static, private] |
Definition at line 273 of file rect_packer.h.
static bool vcg::RectPacker< SCALAR_TYPE >::PackIntMulti | ( | const std::vector< Point2i > & | sizes, |
const int | ntexture, | ||
const vcg::Point2i & | max_size, | ||
std::vector< Point2i > & | posiz, | ||
std::vector< int > & | texin, | ||
std::vector< Point2i > & | globalsize | ||
) | [inline, static, private] |
Definition at line 406 of file rect_packer.h.
static bool vcg::RectPacker< SCALAR_TYPE >::PackMulti | ( | const std::vector< Box2x > & | rectVec, |
const Point2i | containerSizeI, | ||
const int | containerNum, | ||
std::vector< Similarity2x > & | trVec, | ||
std::vector< int > & | indVec, | ||
std::vector< Point2x > & | coveredContainer | ||
) | [inline, static] |
the sub portion of the container covered by the solution.
containerSizeI | the set of rectangles that have to be packed (generic floats, no req.) |
containerNum | the size of the container where they has to be fitted (usually in pixel size) |
indVec | the result, a set of similarity transformation that have to be applied to the rect to get their position |
Definition at line 149 of file rect_packer.h.
static bool vcg::RectPacker< SCALAR_TYPE >::PackOccupancy | ( | const std::vector< Box2x > & | rectVec, |
const Point2i | containerSizeX, | ||
const SCALAR_TYPE | occupancyRatio, | ||
std::vector< Similarity2x > & | trVec, | ||
Point2x & | coveredContainer | ||
) | [inline, static] |
the sub portion of the container covered by the solution.
containerSizeX | the set of rectangles that have to be packed |
occupancyRatio | the size of the container where they has to be fitted (usually in pixel size) |
trVec | the expected percentage of the container that has to be covered |
coveredContainer | the result, a set of similarity transformation that have to be applied to the rect to get their position |
Definition at line 94 of file rect_packer.h.
static bool vcg::RectPacker< SCALAR_TYPE >::PackOccupancyMulti | ( | const std::vector< Box2x > & | rectVec, |
const Point2i | containerSizeX, | ||
const int | containerNum, | ||
const SCALAR_TYPE | occupancyRatio, | ||
std::vector< Similarity2x > & | trVec, | ||
std::vector< int > & | indVec, | ||
std::vector< Point2x > & | coveredContainer | ||
) | [inline, static] |
the sub portion of the container covered by the solution.
containerSizeX | the set of rectangles that have to be packed |
containerNum | the size of the container where they has to be fitted (usually in pixel size) |
trVec | the expected percentage of the container that has to be covered |
indVec | the result, a set of similarity transformation that have to be applied to the rect to get their position |
Definition at line 185 of file rect_packer.h.
static Stat& vcg::RectPacker< SCALAR_TYPE >::stat | ( | ) | [inline, static] |
Definition at line 59 of file rect_packer.h.