.. role:: ts-api-decorator

#############
PathGenerator
#############

.. js:module:: cee.utils
   :noindex:

.. container:: ts-api-section

   .. js:class:: PathGenerator

      Helper class to generate vertices for paths



.. container:: api-index-section

   .. rubric:: Constructors

   .. rst-class:: api-index-list-item api-kind-constructor api-parent-kind-class

   * :js:meth:`~cee.utils.PathGenerator.constructor`



.. container:: api-index-section

   .. rubric:: Methods

   .. rst-class:: api-index-list-item api-kind-method api-parent-kind-class

   * :js:meth:`~cee.utils.PathGenerator.generateVerticesForCircle`
   * :js:meth:`~cee.utils.PathGenerator.generateVerticesForCircleThrough3Points`
   * :js:meth:`~cee.utils.PathGenerator.generateVerticesForCircularSegmentBetween2Lines`
   * :js:meth:`~cee.utils.PathGenerator.generateVerticesForPath`





------------

Constructors
============

.. container:: ts-api-section

   .. js:function:: PathGenerator.constructor()



      :rtype: PathGenerator



Methods
=======

.. rst-class:: ts-api-section

:ts-api-decorator:`static` generateVerticesForCircle
----------------------------------------------------

.. js:method:: PathGenerator.generateVerticesForCircle( center, normal, radius, numSegments)

   :param center: None
   :type center: Vec3
   :param normal: None
   :type normal: Vec3
   :param radius: None
   :type radius: number
   :param numSegments: None
   :type numSegments: number


   Generates vertices to draw a circle.


   :rtype: [number]

.. rst-class:: ts-api-section

:ts-api-decorator:`static` generateVerticesForCircleThrough3Points
------------------------------------------------------------------

.. js:method:: PathGenerator.generateVerticesForCircleThrough3Points( p1, p2, p3, numSegments)

   :param p1: None
   :type p1: Vec3
   :param p2: None
   :type p2: Vec3
   :param p3: None
   :type p3: Vec3
   :param numSegments: None
   :type numSegments: number


   Generates vertices to draw a circle passing through the given 3 points.
   Returns null when the points (p1, p2, p3) do not specify a circle, e.g. they lie on a straight line.


   :rtype: [number]

.. rst-class:: ts-api-section

:ts-api-decorator:`static` generateVerticesForCircularSegmentBetween2Lines
--------------------------------------------------------------------------

.. js:method:: PathGenerator.generateVerticesForCircularSegmentBetween2Lines( center, endPoint1, endPoint2, radius, numSegments)

   :param center: None
   :type center: Vec3
   :param endPoint1: None
   :type endPoint1: Vec3
   :param endPoint2: None
   :type endPoint2: Vec3
   :param radius: None
   :type radius: number
   :param numSegments: None
   :type numSegments: number


   Generates vertices to draw a circular segment between the lines <center, endPoint1> and <center, endPoint2>.
   Returns null when the points (center, endpoint1, endpoint2) do not specify a circle, e.g. they lie on a straight line.


   :rtype: [number]

.. rst-class:: ts-api-section

:ts-api-decorator:`static` generateVerticesForPath
--------------------------------------------------

.. js:method:: PathGenerator.generateVerticesForPath( points)

   :param points: None
   :type points: [Vec3]


   Generates vertices to draw a path connecting the given points


   :rtype: [number]

