segment-aabb

    1.0.0 • Public • Published

    segment-aabb

    compute the aabb of an n-dimensional line segment

    install

    npm install segment-aabb

    use

    var convert = require('segment-aabb');
     
    var start = [10, 10, 5];
    var end = [100, -2, 10];
     
    var r = convert(start, end);
     
    console.log(r);
     
    /*
        outputs:
        [10, -2, 5, 100, 10, 10]
    */
     

    api surface

    segmentAABB(start, end)

    • start - vector in the form of an array
    • end - vector in the form of an array

    returns array (e.g in 2d [minX, minY, maxX, maxY])

    license

    MIT

    Install

    npm i segment-aabb

    DownloadsWeekly Downloads

    2

    Version

    1.0.0

    License

    MIT

    Last publish

    Collaborators

    • tmpvar