SCV  4.2.1
Simple Components for Visual
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
scv::math Namespace Reference

Mathematic functions. More...

Functions

bool isInside (scv::Point p11, scv::Point p12, scv::Point p21, scv::Point p22)
 Widths are positive and should grow to right and down.
 
double nearestValue (double p, double p1, double p2)
 Return the nearest value from 'p'.
 
void intersectSquare (scv::Point &p11, scv::Point &p12, scv::Point &p21, scv::Point &p22)
 

Detailed Description

Mathematic functions.

Function Documentation

void scv::math::intersectSquare ( scv::Point p11,
scv::Point p12,
scv::Point p21,
scv::Point p22 
)
inline
      P11__________
      |            |
      |       P21__|_______
      |       |    |       |
      |_______|____P12     |
              |            |
              |____________P22

return New square points by reference.

bool scv::math::isInside ( scv::Point  p11,
scv::Point  p12,
scv::Point  p21,
scv::Point  p22 
)
inline

Widths are positive and should grow to right and down.

      P11__________
      |            |
      |       P21__|_______
      |       |    |       |
      |_______|____|       |
              |            |
              |____________|

      p12 = width and height from p11 square.
      p22 = width and height from p21 square.
Returns
Return true if intersection area not exist.
double scv::math::nearestValue ( double  p,
double  p1,
double  p2 
)
inline

Return the nearest value from 'p'.