|
float | hmap::angle (const Point &p1, const Point &p2) |
| Computes the angle between two points relative to the x-axis.
|
|
float | hmap::angle (const Point &p0, const Point &p1, const Point &p2) |
| Computes the angle formed by three points with the reference point as the origin.
|
|
float | hmap::cross_product (const Point &p0, const Point &p1, const Point &p2) |
| Computes the 2D cross product of vectors formed by three points.
|
|
float | hmap::curvature (const Point &p1, const Point &p2, const Point &p3) |
| Calculates the curvature formed by three points in 2D space.
|
|
float | hmap::distance (const Point &p1, const Point &p2) |
| Calculates the distance between two points.
|
|
Point | hmap::interp_bezier (const Point &p_start, const Point &p_ctrl_start, const Point &p_ctrl_end, const Point &p_end, float t) |
| Performs a cubic Bezier interpolation.
|
|
Point | hmap::interp_bspline (const Point &p0, const Point &p1, const Point &p2, const Point &p3, float t) |
| Performs a cubic B-spline interpolation.
|
|
Point | hmap::interp_catmullrom (const Point &p0, const Point &p1, const Point &p2, const Point &p3, float t) |
| Performs a Catmull-Rom spline interpolation.
|
|
Point | hmap::interp_decasteljau (const std::vector< Point > &points, float t) |
| Performs a De Casteljau algorithm-based interpolation for Bezier curves.
|
|
Vec4< float > | hmap::intersect_bounding_boxes (const Vec4< float > &bbox1, const Vec4< float > &bbox2) |
| Determines the intersection of two bounding boxes.
|
|
bool | hmap::is_point_within_bounding_box (Point p, Vec4< float > bbox) |
| Checks if a point is within a specified bounding box.
|
|
bool | hmap::is_point_within_bounding_box (float x, float y, Vec4< float > bbox) |
| Checks if a point is within a specified bounding box.
|
|
Point | hmap::lerp (const Point &p1, const Point &p2, float t) |
| Linearly interpolates between two points.
|
|
Point | hmap::midpoint (const Point &p1, const Point &p2, int orientation, float distance_ratio, float t=0.5f) |
| Computes the midpoint displacement in 1D with a perpendicular displacement.
|
|
Vec4< float > | hmap::unit_square_bbox () |
| Constructs a 4D bounding box for a unit square.
|
|
bool | hmap::cmp_inf (Point &a, Point &b) |
|
void | hmap::sort_points (std::vector< Point > &points) |
| Sorts a vector of points in ascending order based on their coordinates.
|
|
float | hmap::triangle_area (const Point &p1, const Point &p2, const Point &p3) |
| Calculates the area of a triangle formed by three points in 2D space.
|
|