Tracktable Namespaces

Namespaces

Algorithms Namespace

namespace algorithms

Functions

TRACKTABLE_CORE_EXPORT PropertyValue tracktable::algorithms::interpolate_property(PropertyValueT const & first, PropertyValueT const & second, double t)

Interpolate between two properties.

For timestamps and numeric properties, this function will give you a linear interpolation between the start and end points. For strings, this function will give you the first string at less than 0.5 and the second string at greater than 0.5.

You will probably never need to call this function directly. It will be invoked when you try to interpolate between two points that have property maps attached.

Return

Linearly-interpolated version of property

Parameters
  • [in] first: Starting value for interpolation

  • [in] second: Ending value for interpolation

  • [in] t: Interpolant; 0 means first value, 1 means second value

TRACKTABLE_CORE_EXPORT PropertyValue tracktable::algorithms::extrapolate_property(PropertyValueT const & first, PropertyValueT const & second, double t)
template<>
struct bearing<PointLonLat>

Public Static Functions

static double apply(PointLonLat const &from, PointLonLat const &to)
template<class PointT>
struct end_to_end_distance<Trajectory<PointT>>
#include <Trajectory.h>

Default implementation of end_to_end_distance.

This uses tracktable::distance to compute the distance between the first and last points of the trajectory. We will probably never need to override this implementation.

Public Types

typedef Trajectory<PointT> trajectory_type

Public Static Functions

static double apply(trajectory_type const &path)
template<std::size_t Dimension>
struct extrapolate<PointCartesian<Dimension>>

Public Static Functions

template<typename point_type>
static point_type apply(point_type const &left, point_type const &right, double t)
template<>
struct extrapolate<PropertyMap>

Public Static Functions

static PropertyMap apply(PropertyMap const &first, PropertyMap const &second, double t)
template<>
struct extrapolate<Timestamp>

Public Static Functions

static Timestamp apply(Timestamp const &first, Timestamp const &second, double t)
template<class BasePointT>
struct extrapolate<TrajectoryPoint<BasePointT>>

Public Types

typedef BasePointT Superclass

Public Static Functions

template<class trajectory_point_type>
static trajectory_point_type apply(trajectory_point_type const &left, trajectory_point_type const &right, double t)
template<std::size_t Dimension>
struct interpolate<PointCartesian<Dimension>>
#include <PointCartesian.h>

Interpolate between two PointCartesian objects.

Public Static Functions

template<typename point_type>
static point_type apply(point_type const &left, point_type const &right, double t)
template<>
struct interpolate<PropertyMap>
#include <PropertyMap.h>

Interpolate between two property maps.

Interpolation is well-defined for numbers and for timestamps. For strings, we choose the first string for t <= 0.5 and the second string for t > 0.5.

Public Static Functions

static PropertyMap apply(PropertyMap const &first, PropertyMap const &second, double t)
template<>
struct interpolate<Timestamp>
#include <Timestamp.h>

Interpolate between two timestamps.

Standard linear interpolation. At t <= 0 you get back the first value. At t >= 1 you get the second value. Anywhere in between, you get (1-t) * first + t * second.

This specializes the template in tracktable/Core/detail/algorithm_signatures/Interpolate.h.

Public Static Functions

static Timestamp apply(Timestamp const &first, Timestamp const &second, double t)
template<class BasePointT>
struct interpolate<TrajectoryPoint<BasePointT>>
#include <TrajectoryPoint.h>

Interpolate between two points.

Interpolate between two different points in a trajectory. At t <= 0 you’ll get the first point back. At t >= 1 you’ll get the second point. At any value in between you’ll get a combination of the two. Coordinates and timestamp will be interpolated linearly. Numeric properties will be interpolated linearly. String properties will be taken from the first point if t <= 0.5 and the second point otherwise.

Public Types

typedef BasePointT Superclass

Public Static Functions

template<class trajectory_point_type>
static trajectory_point_type apply(trajectory_point_type const &left, trajectory_point_type const &right, double t)
template<class PointT, template<class> class TrajectoryT>
struct point_to_trajectory_distance

Public Static Functions

static double apply(PointT const &from, TrajectoryT<PointT> const &to)
template<>
struct signed_turn_angle<PointLonLat>

Public Static Functions

static double apply(PointLonLat const &a, PointLonLat const &b, PointLonLat const &c)
template<>
struct simplify_linestring<PointLonLat>

Public Static Functions

template<typename linestring_type>
static void apply(linestring_type const &input, linestring_type &result, double tolerance)
template<class BasePointT>
struct speed_between<TrajectoryPoint<BasePointT>>
#include <TrajectoryPoint.h>

Speed between two points in native units per second.

Public Types

typedef TrajectoryPoint<BasePointT> point_type

Public Static Functions

static double apply(point_type const &start, point_type const &finish)
template<>
struct spherical_coordinate_access<PointLonLat>

Public Types

typedef PointLonLat point_type

Public Static Functions

static double longitude_as_degrees(point_type const &p)
static double latitude_as_degrees(point_type const &p)
static double longitude_as_radians(point_type const &p)
static double latitude_as_radians(point_type const &p)
static void set_longitude_from_degrees(point_type &p, double value)
static void set_latitude_from_degrees(point_type &p, double value)
static void set_longitude_from_radians(point_type &p, double value)
static void set_latitude_from_radians(point_type &p, double value)

Conversions Namespace

namespace conversions

Functions

double degrees(double _rad)

Convert radians to degrees.

Return

Angle measured in degrees

Parameters
  • [in] _rad: Angle to convert

double radians(double _deg)

Convert degrees to radians.

Return

Angle measured in radians

Parameters
  • [in] _deg: Angle to convert

double hours_to_seconds(double _hrs)
double seconds_to_hours(double _secs)
double steradians_to_km2(double _sr)
double km2_to_steradians(double _km2)
double radians_to_km(double _rad)
double km_to_radians(double _km)
double feet_to_meters(double _feet)
namespace constants

Variables

constexpr double PI = 3.141592653589793238462643383
constexpr double EARTH_RADIUS_IN_KM = 6371
constexpr double EARTH_RADIUS_IN_MI = 3959
constexpr double EARTH_RADIUS_IN_NM = 3440
constexpr double DEGREES_PER_RADIAN = 57.29577951308232087679
constexpr double RADIANS_PER_DEGREE = .01745329251994329576
constexpr double SECONDS_PER_HOUR = 3600.0
constexpr double HOURS_PER_SECOND = 0.0027777777777777
constexpr double METERS_PER_FOOT = 0.3048

Log Namespace

namespace log

Enums

enum severity_level

Values:

trace
debug
info
warning
error
fatal

Settings Namespace

namespace settings

Typedefs

typedef double point_coordinate_type
typedef std::string string_type

Variables

const double EQUALITY_RELATIVE_TOLERANCE = 1e-5
const double ZERO_ABSOLUTE_TOLERANCE = 1e-5

Traits Namespace

namespace traits
template<std::size_t Dimension>
struct domain<PointBase<Dimension>>

Public Types

typedef domains::generic type
template<std::size_t Dimension>
struct undecorated_point<PointBase<Dimension>>

Public Types

typedef PointBase<Dimension> type