PathGenerator
- class cee.utils.PathGenerator()
Helper class to generate vertices for paths
Constructors
Methods
Constructors
- PathGenerator.constructor()
- Return type:
PathGenerator
Methods
static generateVerticesForCircle
- PathGenerator.generateVerticesForCircle(center, normal, radius, numSegments)
- Arguments:
center (
Vec3
) – Nonenormal (
Vec3
) – Noneradius (
number
) – NonenumSegments (
number
) – None
Generates vertices to draw a circle.
- Return type:
[number]
static generateVerticesForCircleThrough3Points
- PathGenerator.generateVerticesForCircleThrough3Points(p1, p2, p3, numSegments)
- Arguments:
p1 (
Vec3
) – Nonep2 (
Vec3
) – Nonep3 (
Vec3
) – NonenumSegments (
number
) – None
Generates vertices to draw a circle passing through the given 3 points. Returns undefined when the points (p1, p2, p3) do not specify a circle, e.g. they lie on a straight line.
- Return type:
[number]
static generateVerticesForCircularSegmentBetween2Lines
- PathGenerator.generateVerticesForCircularSegmentBetween2Lines(center, endPoint1, endPoint2, radius, numSegments)
- Arguments:
center (
Vec3
) – NoneendPoint1 (
Vec3
) – NoneendPoint2 (
Vec3
) – Noneradius (
number
) – NonenumSegments (
number
) – None
Generates vertices to draw a circular segment between the lines <center, endPoint1> and <center, endPoint2>. Returns undefined when the points (center, endpoint1, endpoint2) do not specify a circle, e.g. they lie on a straight line.
- Return type:
[number]
static generateVerticesForPath
- PathGenerator.generateVerticesForPath(points)
- Arguments:
points (
[Vec3]
) – None
Generates vertices to draw a path connecting the given points
- Return type:
[number]