FireSTARR
Loading...
Searching...
No Matches
fs::XYIdx Struct Reference
Collaboration diagram for fs::XYIdx:

Public Member Functions

constexpr Idx x_value () const noexcept
 
constexpr Idx y_value () const noexcept
 
constexpr XYIdx (const XIdx &x0, const YIdx &y0)
 
template<class T >
constexpr XYIdx (const T &x0, const T &y0)
 
template<class S , int XMin, int XMax, int YMin, int YMax>
constexpr XYIdx (const BoundedPoint< S, XMin, XMax, YMin, YMax > &pt) noexcept
 
constexpr XYIdx (const XYPos &xy) noexcept
 
constexpr auto operator== (const XYIdx &rhs) const noexcept
 
constexpr auto operator<=> (const XYIdx &rhs) const noexcept
 
XYPos operator+ (const XYPos &rhs) const noexcept
 
XYPos center () const noexcept
 
XYIdx operator+ (const XYIdx &rhs) const noexcept
 
XYIdx operator+ (const XIdx &rhs) const noexcept
 
XYIdx operator+ (const YIdx &rhs) const noexcept
 
constexpr CellIndex relativeIndex (const XYIdx &rhs) const noexcept
 

Public Attributes

XIdx x {}
 
YIdx y {}
 

Member Function Documentation

◆ relativeIndex()

CellIndex fs::XYIdx::relativeIndex ( const XYIdx & rhs) const
inlineconstexprnoexcept

Determine the direction that a given cell is in from another cell. This is the same convention as wind (i.e. the direction it is coming from, not the direction it is going towards).

Parameters
srcThe cell to find directions relative to
dstThe cell to find the direction of
Returns
Direction that you would have to go in to get to dst from src

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