• Preparing search index...
  • The search index is not available
plotboilerplate - v

Settings

Member Visibility

Theme

  • plotboilerplate
  • utils/algorithms/sutherlandHodgman
  • sutherlandHodgman

Function sutherlandHodgman

  • sutherlandHodgman(subjectPolygon, clipPolygon): XYCoords[]
  • Parameters

    • subjectPolygon: XYCoords[]

      Can be any polygon.

    • clipPolygon: XYCoords[]

      Must be convex.

    Returns XYCoords[]

    • Defined in plotboilerplate/src/ts/utils/algorithms/sutherlandHodgman.ts:52
plotboilerplate
  • BezierPath
    • BezierPath
  • Bounds
    • Bounds
  • Circle
    • Circle
  • CircleSector
    • CircleSector
  • CubicBezierCurve
    • CubicBezierCurve
  • Grid
    • Grid
  • KeyHandler
    • KeyHandler
    • XKeyListener
    • XKeyCallback
  • Line
    • Line
  • MouseHandler
    • MouseHandler
    • XMouseEvent
    • XWheelEvent
    • XMouseParams
    • XMouseCallback
    • XWheelCallback
  • PBImage
    • PBImage
  • PBText
    • PBText
  • PlotBoilerplate
    • default
    • PlotBoilerplate
  • Polygon
    • Polygon
  • Triangle
    • Triangle
  • UIDGenerator
    • UIDGenerator
  • VEllipse
    • VEllipse
  • VEllipseSector
    • VEllipseSector
  • Vector
    • Vector
  • VertTuple
    • VertTuple
  • Vertex
    • Vertex
  • VertexAttr
    • VertexAttr
    • IVertexAttr
  • VertexListeners
    • VertexListeners
    • VertEvent
    • VertEventParams
    • VertListener
  • draw
    • drawutils
  • drawgl
    • drawutilsgl
  • drawutilssvg
    • drawutilssvg
  • geomutils
    • geomutils
      A collection of usefull geometry utilities.
  • index
    • BezierPath
    • Bounds
    • CSSBackdropFilterParams
    • CanvasWrapper
    • Circle
    • CircleSector
    • Config
    • CubicBezierCurve
    • DatGuiProps
    • DrawConfig
    • DrawLib
    • DrawLibConfiguration
    • DrawSettings
    • Drawable
    • FontOptions
    • FontStyle
    • FontWeight
    • GUI
    • Grid
    • IBounded
    • IBounds
    • IDraggable
    • IHooks
    • IVertexAttr
    • Intersectable
    • KeyHandler
    • LilGuiProps
    • Line
    • MouseHandler
    • PBImage
    • PBParams
    • PBText
    • Path
    • PathSegment
    • PlotBoilerplate
    • Polygon
    • SVGPathParams
    • SVGSerializable
    • StrokeOptions
    • Triangle
    • UID
    • UIDGenerator
    • VEllipse
    • VEllipseSector
    • Vector
    • VertEvent
    • VertEventParams
    • VertListener
    • VertTuple
    • Vertex
    • VertexAttr
    • VertexListeners
    • XKeyCallback
    • XKeyListener
    • XMouseCallback
    • XMouseEvent
    • XMouseParams
    • XWheelCallback
    • XWheelEvent
    • XYCoords
    • XYDimension
    • drawutils
    • drawutilsgl
    • drawutilssvg
    • geomutils
  • interfaces
    • CSSBackdropFilterParams
    • CanvasWrapper
    • Config
    • DatGuiProps
    • DrawConfig
    • DrawLib
    • DrawLibConfiguration
    • DrawSettings
    • Drawable
    • FontOptions
    • FontStyle
    • FontWeight
    • GUI
    • IBounded
    • IBounds
    • IDraggable
    • IHooks
    • Intersectable
    • LilGuiProps
    • PBParams
    • Path
    • PathSegment
    • SVGPathParams
    • SVGSerializable
    • StrokeOptions
    • UID
    • XYCoords
    • XYDimension
  • interfaces/DrawLib
    • DrawLib
      An interface all drawing libraries must implement to be used with PlotBoilerplate.
    • DrawLibConfiguration
    • FontOptions
    • StrokeOptions
      Defines a line-dash configuration.
    • FontStyle
    • FontWeight
  • interfaces/additionals
    • Path
      A common interface for general path representations.
    • PathSegment
      A common interface for different kinds of path segments.
  • interfaces/core
    • CanvasWrapper
      This is used to wrap 2d/gl/svg canvas elements together.
    • Config
      The config that's used by PB.
    • DrawConfig
    • DrawSettings
    • IBounded
    • IBounds
    • IDraggable
      A wrapper class/interface for draggable items (mostly vertices).
    • IHooks
    • Intersectable
      Shapes should implement this interface if they support intersection calculation.
    • PBParams
      For initialization the constructor needs a mix of config and draw-settings.
    • SVGSerializable
      This is a fix for the problem, that the constructor's "name" attribute is not
    • XYCoords
    • XYDimension
    • Drawable
      The types that can be drawn and thus added to the draw queue.
    • SVGPathParams
      A type for SVG <path d="..." /> params.
    • UID
      A unique identifier (UID) to tell drawables apart in a performant manner.
  • interfaces/externals
    • CSSBackdropFilterParams
      This is just for the backdrop-filter vaules (CSS after effects filters). They are not directly
    • DatGuiProps
    • GUI
    • LilGuiProps
  • module
    • BezierPath
    • Bounds
    • Circle
    • CircleSector
    • CubicBezierCurve
    • Grid
    • KeyHandler
    • Line
    • MouseHandler
    • PBImage
    • PlotBoilerplate
    • Polygon
    • Triangle
    • UIDGenerator
    • VEllipse
    • VEllipseSector
    • Vector
    • VertTuple
    • Vertex
    • VertexAttr
    • VertexListeners
    • default
    • drawutils
    • drawutilssvg
    • geomutils
  • utils/InitializationObserver
    • InitializationObserver
  • utils/NGons
    • NGons
  • utils/Params
    • Params
      Wraps a Record<string,string> and adds type conversion methods (developed this in
  • utils/WebColors
    • Blue
    • Cyan
    • DeepPurple
    • Green
    • Indigo
    • LightBlue
    • LightGreen
    • Pink
    • Purple
    • Red
    • Teal
    • WebColors
      A set of beautiful web colors (I know, beauty is in the eye of the beholder).
    • shuffleWebColors
      A helper function to shuffle the colors into a new order.
  • utils/WebColorsContrast
    • WebColorsContrast
  • utils/WebColorsMalachite
    • WebColorsMalachite
      A mix of green shades.
  • utils/algorithms/CatmullRomPath
    • CatmullRomPath
  • utils/algorithms/CircleIntersections
    • CircleIntersections
  • utils/algorithms/ContourLineDetection
    • ContourLineDetection
  • utils/algorithms/CubicSplinePath
    • CubicSplinePath
  • utils/algorithms/HobbyPath
    • HobbyPath
  • utils/algorithms/Metaballs
    • Metaballs
  • utils/algorithms/PolygonInset
    • PolygonInset
    • IPolygonInsetOptions
  • utils/algorithms/arrayFill
    • arrayFill
      An equivalent of lodash.array_fill(...).
  • utils/algorithms/arrayResize
    • arrayResize
      Resize a given array to a desired number of elements by adding or removing some.
  • utils/algorithms/arrayShuffle
    • arrayShuffle
      Randomize a given array in-place.
  • utils/algorithms/clearDuplicateVertices
    • clearDuplicateVertices
      Filter the array and clear all duplicates.
  • utils/algorithms/clearPolygonDuplicateVertices
    • clearPolygonDuplicateVertices
      Remove all duplicate neighbours from the given polygon.
  • utils/algorithms/convexHull
    • getConvexHull
  • utils/algorithms/convexPolygonIncircle
    • PolygonIncircle
    • convexPolygonIncircle
      Compute the max sized inlying circle in the given convex (!) polygon - also called the
  • utils/algorithms/delaunay
    • Delaunay
  • utils/algorithms/delaunay2voronoi
    • delaunay2voronoi
  • utils/algorithms/detectPaths
    • detectPaths
      Run a path detection on the given set of path segments.
  • utils/algorithms/findPolygonSelfIntersections
    • findPolygonSelfIntersections
      Collect all self-intersection points of the given polygon.
  • utils/algorithms/getContrastColor
    • getContrastColor
      Contrast color algorithm by Martin Sojka's.
  • utils/algorithms/matrixFill
    • matrixFill
      A matrix-fill helper function. Equivalent of lodash.array_fill(...).
  • utils/algorithms/splitPolygonToNonIntersecting
    • splitPolygonToNonIntersecting
      This function cuts a given self-intersecting polygon into non-self-intersecting
  • utils/algorithms/sutherlandHodgman
    • sutherlandHodgman
  • utils/cloneVertexArray
    • cloneVertexArray
  • utils/createRandomizedPolygon
    • createRandomizedPolygon
  • utils/datastructures/CircularIntervalSet
    • CircularIntervalSet
  • utils/datastructures/Color
    • Color
  • utils/datastructures/DataGrid2d
    • IDataGrid2d
    • DataGridFace4
      A 2D datagrid interface for getting/storing data in some 2 dimensional array style types.
  • utils/datastructures/DataGrid2dListAdapter
    • DataGrid2dListAdapter
  • utils/datastructures/GenericPath
    • GenericPath
      A common interface for general path representations.
  • utils/datastructures/Girih
    • Girih
  • utils/datastructures/GirihBowtie
    • GirihBowtie
  • utils/datastructures/GirihDecagon
    • GirihDecagon
  • utils/datastructures/GirihHexagon
    • GirihHexagon
  • utils/datastructures/GirihPenroseRhombus
    • GirihPenroseRhombus
  • utils/datastructures/GirihPentagon
    • GirihPentagon
  • utils/datastructures/GirihRhombus
    • GirihRhombus
  • utils/datastructures/GirihTile
    • TileType
    • GirihTile
    • IAdjacency
  • utils/datastructures/Matrix4x4
    • Matrix4x4
  • utils/datastructures/VoronoiCell
    • VoronoiCell
  • utils/datastructures/interfaces
    • IndexPair
    • Interval
      Some often-used interfaces.
    • Matrix
  • utils/detectDarkMode
    • detectDarkMode
  • utils/dom/getAvailableContainerSpace
    • getAvailableContainerSpace
  • utils/dom/getFProp
    • getFProp
      Internal helper function used to get 'float' properties from elements.
  • utils/dom/guiSizeToggler
    • guiSizeToggler
  • utils/findInVertexArray
    • findInVertexArray
      In an array of vertices find the first occurence of a specific vertex, using
  • utils/gup
    • gup
      `gup` = "Get URL/URI Params".
  • utils/helpers/BezierPathInteractionHelper
    • BezierPathInteractionHelper
  • utils/helpers/CircleHelper
    • CircleHelper
  • utils/helpers/CircleSectorHelper
    • CircleSectorHelper
  • utils/helpers/VEllipseHelper
    • VEllipseHelper
  • utils/helpers/VEllipseSectorHelper
    • VEllipseSectorHelper
  • utils/io/FileDrop
    • FileDrop
  • utils/parsers/OBJParser
    • OBJParser
  • utils/parsers/STLParser
    • STLParser

Generated using TypeDoc