casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Static Public Member Functions | List of all members
casacore::Geometry Class Reference

Geometry related methods. More...

#include <Geometry.h>

Static Public Member Functions

static std::pair< Double, Doublerotate2D (Double x, Double y, const Quantity &theta)
 Get result of rotating a 2-D vector counterclockwise through an angle theta. More...
 
static Bool doLineSegmentsIntersect (Double a0x, Double a0y, Double a1x, Double a1y, Double b0x, Double b0y, Double b1x, Double b1y)
 Determine if two coplanar line segments, a and b, intersect. More...
 

Detailed Description

Geometry related methods.

Intended use:

Public interface

Review Status

Date Reviewed:
yyyy/mm/dd

Etymology

self-explanatory

Synopsis

Various geometry related functions

Motivation

Commonly used geometrical functions for various image and region applications.

Definition at line 59 of file Geometry.h.

Member Function Documentation

static Bool casacore::Geometry::doLineSegmentsIntersect ( Double  a0x,
Double  a0y,
Double  a1x,
Double  a1y,
Double  b0x,
Double  b0y,
Double  b1x,
Double  b1y 
)
static

Determine if two coplanar line segments, a and b, intersect.

Line segment a has end points a0 and a1, and line segment b has endpoints b0 and b1. Algorithm from http://stackoverflow.com/questions/563198/how-do-you-detect-where-two-line-segments-intersect

static std::pair<Double, Double> casacore::Geometry::rotate2D ( Double  x,
Double  y,
const Quantity theta 
)
static

Get result of rotating a 2-D vector counterclockwise through an angle theta.

The output pair will have x as the first member and y as the second. theta must have angular units (no explicit checking is done, but an exception will be thrown from the Quanta code if not).


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