GH_GraphicTreeDisplayArgs

References
A class that contains useful information used for drawing GH_GraphicTrees.

Fields

maxPathLength

#
The number of elements in the longest path of the tree.
public int maxPathLength

origin

#
The origin point of the tree in Graphics coordinates.
public PointF origin

radius

#
Radius of the outer ring Leaf objects.
public float radius

vp

#
Gets the viewport of the canvas in which we're drawing.
public GH_Viewport vp

Methods

AdjustMaxPathLength

#
Call this function to register a new maximum path length. This function is only used during the construction of this class. Do not call this while in the middle of a drawing operation.
public void AdjustMaxPathLength(
potential_new_length
)

Distance

#
Compute the distance between a point P and a finite line segment defined by A-B.
public static float Distance(
PointF
A,
PointF
B,
PointF
P
)

Distance

#
Compute the distance between two points.
public static float Distance(
PointF
A,
PointF
B
)

DistanceSquared

#
Compute the squared distance between two points.
public static float DistanceSquared(
PointF
A,
PointF
B
)

RadialBox

#
Compute the extents of a rectanle within the current layout.
public RectangleF RadialBox(
box_edge
)

RadialCrd

#
Compute the x and y coordinates of a point defined by radial coordinates
public PointF RadialCrd(
angle,
offset
)

RadialX

#
Compute the x-coordinate of a point defined by radial coordinates
public float RadialX(
angle,
offset
)

RadialY

#
Compute the y-coordinate of a point defined by radial coordinates
public float RadialY(
angle,
offset
)

RadToDeg

#
Convert Radians to Degrees
public static float RadToDeg()

RemapDegrees

#
Adjust the angle (in degrees) to match tree orientation
public static float RemapDegrees()

SetupViewport

#
Assign the viewport member with this function to ensure that other constants are also set.
public void SetupViewport()

Visible

#
Test to see if a bezier segment is within the visible domain. This test is fuzzy in the interest of performance.
public bool Visible(
PointF
P0,
PointF
P1,
PointF
P2,
PointF
P3,
fuzz = 0
)

Visible

#
Test to see if a circle is within the visible domain.
public bool Visible(
PointF
pt,
radius
)

Visible

#
Test to see if a point is within the visible domain.
public bool Visible(
PointF
pt
)

Visible

#
Test to see if a line segment is within the visible domain. This test is fuzzy in the interest of performance.
public bool Visible(
PointF
ptA,
PointF
ptB,
fuzz = 0
)

Visible

#
Test to see if a rectangle is within the visible domain.
public bool Visible(
rec,
margin
)

Visible

#
Test to see if a rectangle is within the visible domain.
public bool Visible()