Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MultiSegment ¶
type MultiSegment []Segment
MultiSegment is an ordered set of segments that form a continuous section of a multipolygon.
func Join ¶
func Join(segments []Segment) []MultiSegment
Join will join a set of segments into a set of connected MultiSegments.
func (MultiSegment) First ¶
func (ms MultiSegment) First() orb.Point
First returns the first point in the list of linestrings.
func (MultiSegment) Last ¶
func (ms MultiSegment) Last() orb.Point
Last returns the last point in the list of linestrings.
func (MultiSegment) LineString ¶
func (ms MultiSegment) LineString() orb.LineString
LineString converts a multisegment into a geo linestring object.
func (MultiSegment) Orientation ¶
func (ms MultiSegment) Orientation() orb.Orientation
Orientation computes the orientation of a multisegment like if it was ring.
func (MultiSegment) Ring ¶
func (ms MultiSegment) Ring(o orb.Orientation) orb.Ring
Ring converts the multisegment to a ring of the given orientation. It uses the orientation on the members if possible.
type Segment ¶
type Segment struct { Index uint32 Orientation orb.Orientation Reversed bool Line orb.LineString }
Segment is a section of a multipolygon with some extra information on the member it came from.
func Group ¶
func Group( members osm.Members, ways map[osm.WayID]*osm.Way, at time.Time, ) (outer, inner []Segment, tainted bool)
Group will take the members and group them by inner our outer parts of the relation. Will also build the way geometry.