aws.osml.photogrammetry.math_utils module
- aws.osml.photogrammetry.math_utils.equilateral_triangle(centroid: List[float], size: float) List[List[float]] [source]
Utility function to create an equilateral triangle with a given side length centered on a point. There are many solutions to that problem so this returns the solution where the top corner is directly above the center and the base are horizontal. (i.e. for a triangle made of points ABC A[0] == center[0] and B[1] == C[1])
- Parameters:
centroid – the center of the triangle
size – the length of one side
- Returns:
a list of lists representing the triangle len(result) == 3, len(result[0]) == 2