catenary-curve

<script src="./point_src/catenary-curve"></script>

* * Given two points and a length, calculate and draw the catenary. * * TypeScript implementation: * Copyright (c) 2018, 2023 Jan Hug me@dulnan.net * Released under the MIT license. * * ---------------------------------------------------------------------------- * * Original ActionScript implementation: * Copyright poiasd ( http://wonderfl.net/user/poiasd ) * MIT License ( http://www.opensource.org/licenses/mit-license.php ) * Downloaded from: http://wonderfl.net/c/8Bnl * * ---------------------------------------------------------------------------- * * Archived by and downloaded from: * http://wa.zozuar.org/code.php?c=8Bnl

Meta Data
filepath_exists True
path catenary-curve
filepath catenary-curve.js
clean_files ()

  • VariableDeclaration
    const

    EPSILON

    =
    1e-6
  • FunctionDeclaration
    function

    getCurve

    (
    a , p1 , p2 , offsetX , offsetY , segments
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • VariableDeclaration
    var

    superVal

    =
    29
  • VariableDeclaration
    const

    standardCosH

    =
    function ( a , x , offsetX , offsetY )
  • FunctionDeclaration
    function

    getLineResult

    (
    data
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    getCatenaryParameter

    (
    h , v , length , limit
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    getCurveResult

    (
    data
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    drawResult

    (
    result , context
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    drawResultLine

    (
    result , context
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    drawResultCurve

    (
    result , context
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    getDifferenceTo

    (
    p1 , p2
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    getDistanceBetweenPoints

    (
    p1 , p2
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])
  • FunctionDeclaration
    function

    getCatenaryCurve

    (
    point1 , point2 , chainLength , options = {}
    )
    dict_keys(['kind', 'word', 'generator', 'expression', 'async', 'params', 'id', 'pos', 'type'])