Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
ogdf::TileToRowsCCPacker Class Reference

The tile-to-rows algorithm for packing drawings of connected components. More...

#include <ogdf/packing/TileToRowsCCPacker.h>

+ Inheritance diagram for ogdf::TileToRowsCCPacker:

Classes

struct  RowInfo
 

Public Member Functions

 TileToRowsCCPacker ()
 Creates an instance of tile-to-rows packer.
 
virtual ~TileToRowsCCPacker ()
 
virtual void call (Array< DPoint > &box, Array< DPoint > &offset, double pageRatio=1.0) override
 Arranges the rectangles given by box.
 
virtual void call (Array< IPoint > &box, Array< IPoint > &offset, double pageRatio=1.0) override
 Arranges the rectangles given by box.
 
- Public Member Functions inherited from ogdf::CCLayoutPackModule
 CCLayoutPackModule ()
 Initializes a layout packing module.
 
virtual ~CCLayoutPackModule ()
 
void operator() (Array< DPoint > &box, Array< DPoint > &offset, double pageRatio=1.0)
 Arranges the rectangles given by box.
 
void operator() (Array< IPoint > &box, Array< IPoint > &offset, double pageRatio=1.0)
 Arranges the rectangles given by box.
 

Static Private Member Functions

template<class POINT >
static void callGeneric (Array< POINT > &box, Array< POINT > &offset, double pageRatio)
 
template<class POINT >
static int findBestRow (Array< RowInfo< POINT > > &row, int nRows, double pageRatio, const POINT &rect)
 

Additional Inherited Members

- Static Public Member Functions inherited from ogdf::CCLayoutPackModule
static bool checkOffsets (const Array< DPoint > &box, const Array< DPoint > &offset)
 Checks if the rectangles in box do not overlap for given offsets.
 
static bool checkOffsets (const Array< IPoint > &box, const Array< IPoint > &offset)
 Checks if the rectangles in box do not overlap for given offsets.
 

Detailed Description

The tile-to-rows algorithm for packing drawings of connected components.

Definition at line 40 of file TileToRowsCCPacker.h.

Constructor & Destructor Documentation

◆ TileToRowsCCPacker()

ogdf::TileToRowsCCPacker::TileToRowsCCPacker ( )
inline

Creates an instance of tile-to-rows packer.

Definition at line 46 of file TileToRowsCCPacker.h.

◆ ~TileToRowsCCPacker()

virtual ogdf::TileToRowsCCPacker::~TileToRowsCCPacker ( )
inlinevirtual

Definition at line 48 of file TileToRowsCCPacker.h.

Member Function Documentation

◆ call() [1/2]

virtual void ogdf::TileToRowsCCPacker::call ( Array< DPoint > &  box,
Array< DPoint > &  offset,
double  pageRatio = 1.0 
)
overridevirtual

Arranges the rectangles given by box.

The algorithm call takes an input an array box of rectangles with real coordinates and computes in offset the offset to (0,0) of each rectangle in the layout.

Parameters
boxis the array of input rectangles.
offsetis assigned the offset of each rectangle to the origin (0,0). The offset of a rectangle is its lower left point in the layout.
pageRatiois the desired page ratio (width / height) of the resulting layout.

Implements ogdf::CCLayoutPackModule.

◆ call() [2/2]

virtual void ogdf::TileToRowsCCPacker::call ( Array< IPoint > &  box,
Array< IPoint > &  offset,
double  pageRatio = 1.0 
)
overridevirtual

Arranges the rectangles given by box.

The algorithm call takes an input an array box of rectangles with real coordinates and computes in offset the offset to (0,0) of each rectangle in the layout.

Parameters
boxis the array of input rectangles.
offsetis assigned the offset of each rectangle to the origin (0,0). The offset of a rectangle is its lower left point in the layout.
pageRatiois the desired page ratio (width / height) of the resulting layout.

Implements ogdf::CCLayoutPackModule.

◆ callGeneric()

template<class POINT >
static void ogdf::TileToRowsCCPacker::callGeneric ( Array< POINT > &  box,
Array< POINT > &  offset,
double  pageRatio 
)
staticprivate

◆ findBestRow()

template<class POINT >
static int ogdf::TileToRowsCCPacker::findBestRow ( Array< RowInfo< POINT > > &  row,
int  nRows,
double  pageRatio,
const POINT rect 
)
staticprivate

The documentation for this class was generated from the following file: