|
libft
|
Distance computation utilities for 2D points. More...
#include "libft.h"
Include dependency graph for distance_utils.c:Functions | |
| double | ft_euclidean_dist_dpoint (t_dpoint a, t_dpoint b) |
| Computes Euclidean distance between two floating-point points. | |
| int | ft_euclidean_dist_point (t_point a, t_point b) |
| Computes Euclidean distance between two integer points. | |
| double | ft_manhattan_dist_dpoint (t_dpoint a, t_dpoint b) |
| Computes Manhattan distance between two floating-point points. | |
| int | ft_manhattan_dist_point (t_point a, t_point b) |
| Computes Manhattan distance between two integer points. | |
Distance computation utilities for 2D points.
This file provides functions for computing distances between 2D points, including both Manhattan and Euclidean distances. It supports both integer-based (t_point) and double-precision (t_dpoint) points.
These functions are useful in grid-based algorithms, AI navigation, and geometric analysis.