Show / Hide Table of Contents

    Class RoutingHintLine

    Structure that holds information about polylines that are used to guide routing.

    Inheritance
    System.Object
    RoutingHintLine
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Elements.Spatial.AdaptiveGrid
    Assembly: Hypar.Elements.dll
    Syntax
    public class RoutingHintLine

    Constructors

    RoutingHintLine(Polyline, Double, Double, Boolean, Boolean)

    Construct new RoutingHintLine structure.

    Declaration
    public RoutingHintLine(Polyline polyline, double factor, double influence, bool userDefined, bool is2D)
    Parameters
    Type Name Description
    Polyline polyline

    Geometry of HintLine.

    System.Double factor

    Cost multiplier.

    System.Double influence

    How far it affects.

    System.Boolean userDefined

    Is user defined.

    System.Boolean is2D

    Should polyline be virtually extended by Z coordinate.

    Fields

    Factor

    Cost multiplier for edges that lie within the Influence distance to the line.

    Declaration
    public readonly double Factor
    Field Value
    Type Description
    System.Double

    InfluenceDistance

    How far away from the line, edge travel cost is affected. Both sides of an edge and its middle point should be within influence range.

    Declaration
    public readonly double InfluenceDistance
    Field Value
    Type Description
    System.Double

    Is2D

    Should polyline be virtually extended by Z coordinate.

    Declaration
    public readonly bool Is2D
    Field Value
    Type Description
    System.Boolean

    Polyline

    2D Polyline geometry representation with an influence that is extended on both sides in Z direction.

    Declaration
    public readonly Polyline Polyline
    Field Value
    Type Description
    Polyline

    UserDefined

    Is line created by the user or from internal parameters? User defined lines are preferred for input Vertex connection.

    Declaration
    public readonly bool UserDefined
    Field Value
    Type Description
    System.Boolean

    Methods

    Affects(Vector3, Vector3, Double)

    Check if hint line affects the line represented by two points. Both points must be withing influence radius of the polyline. Only edges parallel to polyline segments are affected.

    Declaration
    public bool Affects(Vector3 start, Vector3 end, double tolerance = 1E-05)
    Parameters
    Type Name Description
    Vector3 start

    Start of the line point.

    Vector3 end

    End of the line point.

    System.Double tolerance

    Minimum allowed distance to polyline, even if influence is 0.

    Returns
    Type Description
    System.Boolean

    Intersects(Vector3, Vector3)

    Check if hint line intersects the line represented by two points withing influence radius of the polyline.

    Declaration
    public bool Intersects(Vector3 start, Vector3 end)
    Parameters
    Type Name Description
    Vector3 start

    Start of the line point.

    Vector3 end

    End of the line point.

    Returns
    Type Description
    System.Boolean

    IsNearby(Vector3, Double)

    Check if point is within influence of the hint line. If hint line is 2D than only 2D distance is calculated, ignoring Z coordinate.

    Declaration
    public bool IsNearby(Vector3 point, double tolerance = 1E-05)
    Parameters
    Type Name Description
    Vector3 point

    Point to check.

    System.Double tolerance

    Minimum allowed distance to polyline, even if influence is 0.

    Returns
    Type Description
    System.Boolean

    True if point is close enough to the polyline.