Corrections

<< Click to Display Table of Contents >>

Navigation:  Technical Guide > Geometry >

Corrections

 

DTSGeoJson corrections are encoded as an array of Line Solutions, each of which describes a sector's exact representation and its place within the geometry structure's coordinates. A Line Solution must represent a continuous curve.

 

This is the structure of a Line Solution:

 

{

 "startIndex": 0,

 "length": 0,

 "exactRepresentation": [],

 "lineType": ""

}

 

Value

Interpretation

LINE_STRING

The coordinates represent a series of straight line segments, as they would in the geometry structure's coordinates. This correction type is redundant, but exists for specialized clients which can pass exact geometry representations using only the corrections field.

CP_ARCS

The coordinates represent a series of Center Point Circle Arcs. Each arc is encoded by 3 coordinates [start, middle, end]. The middle coordinate can be any point on the arc. In geometries created by DTS, the middle coordinate is always the exact middle of the arc.

The end coordinate of an arc also serves as the start coordinate of the next arc, so the total number of coordinates will be 2*N_ARCS+1.

exclamation_mark_16px Please note that elliptical / tangent arcs cannot be encoded with this lineType and need to be defined as NURBS.

 

NURBS

The coordinates represent a Non-Uniform Rational B-Spline as follows:

[ [ D, N, K ], [ knot1, ..., knotK ], [ contolPoint1 ], ..., [ controlPointN ] ]

Where:

D: the degree of the NURBS

N: the number of control points

K: the number of knots

knot1,  ..., knotK: the knots (K double values)

[controlPoint1], ..., [controlPointN]: the weighted control points (N arrays of double values containing the coordinate for the respective control point and the weight [x, y, z, w])

Information-icon_16px A correctly defined NURBS will agree with K = D + N + 1

 

RECTANGLE

The coordinates represent the opposite corners of a rectangle. Serves as shorthand for the equivalent polygon which would use 5 coordinates instead of 2.

CIRCLE

The coordinates represent a circle using 2 coordinates:

[ [centerCoord], [anyOtherPointOnCircle] ]

 

Information-icon_16px When feeding geometry data to a system via DTS using DTSGeoJson, it is possible to set exact representations in the corrections field and not calculate any approximations for the coordinates field. For this to work, the targeted connector must be capable of using the DTSGeoJson extensions and the coordinates field must contain some minimal placeholder values that will be replaced by the exact corrections upon processing.