libimgdoc2
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
imgdoc2::LogicalPositionInfo Struct Reference

#include <LogicalPositionInfo.h>

Public Member Functions

 LogicalPositionInfo ()=default
 Default constructor, all properties are initialized to invalid values.
 
 LogicalPositionInfo (double x, double y, double w, double h)
 
 LogicalPositionInfo (double x, double y, double w, double h, int pyrLvl)
 
bool operator== (const LogicalPositionInfo &rhs) const
 
bool operator!= (const LogicalPositionInfo &rhs) const
 

Public Attributes

double posX { std::numeric_limits<double>::quiet_NaN() }
 The x coordinate of the top left point.
 
double posY { std::numeric_limits<double>::quiet_NaN() }
 The y coordinate of the top left point.
 
double width { std::numeric_limits<double>::quiet_NaN() }
 The width.
 
double height { std::numeric_limits<double>::quiet_NaN() }
 The height.
 
int pyrLvl { std::numeric_limits<int>::min() }
 The pyramid level.
 

Detailed Description

This structure defines the "logical position" of a tile in the 2D-document model. It is given by a (axis-aligned) rectangle (in the plane-pixel-coordinate-system) and the pyramid-level.

Constructor & Destructor Documentation

◆ LogicalPositionInfo() [1/2]

imgdoc2::LogicalPositionInfo::LogicalPositionInfo ( double  x,
double  y,
double  w,
double  h 
)
inline

Constructor initializing the rectangle and setting the pyramid-level to zero.

Parameters
xThe x coordinate of the top left point.
yThe y coordinate of the top left point.
wThe width.
hThe height.

◆ LogicalPositionInfo() [2/2]

imgdoc2::LogicalPositionInfo::LogicalPositionInfo ( double  x,
double  y,
double  w,
double  h,
int  pyrLvl 
)
inline

Constructor.

Parameters
xThe x coordinate of the top left point.
yThe y coordinate of the top left point.
wThe width.
hThe height.
pyrLvlThe pyramid level.

Member Function Documentation

◆ operator!=()

bool imgdoc2::LogicalPositionInfo::operator!= ( const LogicalPositionInfo rhs) const
inline

Inequality operator (where the coordinates are compared with an epsilon).

Parameters
rhsThe right hand side.
Returns
True if the parameters are not considered equivalent.

◆ operator==()

bool imgdoc2::LogicalPositionInfo::operator== ( const LogicalPositionInfo rhs) const
inline

Equality operator (where the coordinates are compared with an epsilon).

Parameters
rhsThe right hand side.
Returns
True if the parameters are considered equivalent.

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