#include "example_loader2.hpp"
#include "organizer/loader.hpp"

void loaderTest1()
{
    Loader loader;

    std::vector<Point3D> points;
    std::vector<double>  bulges;
    Vector3D             extusion;
    Point3D              topPoint, bottomPoint, basePoint, leftBottomPoint;
    Direction3D          direction;

    double offset, radius, radius1, radius2, length, width, height, areaDifference, volumeDifference;

    std::pair<double, double> before, after;

    /* Ìå1 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag1 = loader.addExtrude(points, bulges, extusion);

    loader.getAreaAndVolume(tag1);

    /* Ìå2 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag2 = loader.addExtrude(points, bulges, extusion);

    loader.getAreaAndVolume(tag2);

    /* Ìå3 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag3 = loader.addExtrude(points, bulges, extusion);

    loader.getAreaAndVolume(tag3);

    /* Ìå4 */
    topPoint    = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 0.0000000000000000};
    bottomPoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 3300.0000000000000000};
    radius1     = 32450.000000000000;
    radius2     = 33539.000000000000;
    auto tag4   = loader.addCone(topPoint, bottomPoint, radius1, radius2);

    loader.getAreaAndVolume(tag4);

    /* Ìå3±»Çиî */
    basePoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 0.0000000000000000};
    direction = Direction3D{0, 0, 1};
    loader.split(tag3, basePoint, direction);

    loader.getAreaAndVolume(tag3);

    /* Ìå3ºÍÌå4²¼¶û²î */
    loader.differentNode(tag3, tag4);

    loader.getAreaAndVolume(tag3);

    /* Ìå5 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag5 = loader.addExtrude(points, bulges, extusion);

    /* Ìå5±»Çиî */
    basePoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 3300.0000000000000000};
    direction = Direction3D{0, 0, 1};
    loader.split(tag5, basePoint, direction);

    /* Ìå3ºÍÌå5²¼¶û²¢ */
    loader.unionNode(tag3, tag5);

    /* Ìå6 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag6 = loader.addExtrude(points, bulges, extusion);

    /* Ìå6±»Çиî */
    basePoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 3300.0000000000000000};
    direction = Direction3D{0, 0, 1};
    loader.split(tag6, basePoint, direction);

    /* Ìå3ºÍÌå6²¼¶û²¢ */
    loader.unionNode(tag3, tag6);

    /* Ìå2ºÍÌå3²¼¶û²î */
    loader.differentNode(tag2, tag3);

    /* Ìå7 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag7 = loader.addExtrude(points, bulges, extusion);

    /* Ìå8 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag8 = loader.addExtrude(points, bulges, extusion);

    /* Ìå9 */
    topPoint    = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 0.0000000000000000};
    bottomPoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    radius1     = 32450.000000000000;
    radius2     = 33539.000000000000;
    auto tag9   = loader.addCone(topPoint, bottomPoint, radius1, radius2);

    /* Ìå8±»Çиî */
    basePoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    direction = Direction3D{0, 0, 1};
    loader.split(tag8, basePoint, direction);

    /* Ìå8ºÍÌå9²¼¶û²î */
    loader.differentNode(tag8, tag9);

    /* Ìå10 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag10 = loader.addExtrude(points, bulges, extusion);

    /* Ìå10±»Çиî */
    basePoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    direction = Direction3D{0, 0, 1};
    loader.split(tag10, basePoint, direction);

    /* Ìå8ºÍÌå10²¼¶û²¢ */
    loader.unionNode(tag8, tag10);

    /* Ìå11 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag11 = loader.addExtrude(points, bulges, extusion);

    /* Ìå11±»Çиî */
    basePoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    direction = Direction3D{0, 0, 1};
    loader.split(tag11, basePoint, direction);

    /* Ìå8ºÍÌå11²¼¶û²¢ */
    loader.unionNode(tag8, tag11);

    /* Ìå7ºÍÌå8²¼¶û²î */
    loader.differentNode(tag7, tag8);

    /* Ìå2ºÍÌå7²¼¶û²¢ */
    loader.unionNode(tag2, tag7);

    /* Ìå1ºÍÌå2²¼¶û²¢ */
    loader.unionNode(tag1, tag2);

    /* Ìå1 ZÖáÆ«ÒÆ -3600 */
    direction = Direction3D{0, 0, 1};
    offset    = -3600;
    loader.offset(tag1, direction, offset);

    /* еÄÌå11 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32050.000001122418, -3.8396319723688066e-07, 0.0000000000000000});
    points.push_back(Point3D{32049.999998877582, -3.8387224776670337e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion      = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto newTag11 = loader.addExtrude(points, bulges, extusion);

    /* Ìå0 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-11798.670446418590, 5999.2409883221799, 0.0000000000000000});
    points.push_back(Point3D{11801.337366082498, 5999.2409883221590, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag0 = loader.addExtrude(points, bulges, extusion);

    /* еÄÌå11ºÍÌå0²¼¶û²î */
    loader.differentNode(newTag11, tag0);

    /* еÄÌå11 ZÖáÆ«ÒÆ -3500 */
    direction = Direction3D{0, 0, 1};
    offset    = -3500;
    loader.offset(newTag11, direction, offset);

    /* Ìå1ºÍеÄÌå11Åн» */
    /* TODO */

    /* Ìå12 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{676.33403607269543, 5999.2409883221790, 0.0000000000000000});
    points.push_back(Point3D{-673.66711640879771, 5999.2409883221790, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag12 = loader.addExtrude(points, bulges, extusion);

    /* Ìå12 ZÖáÆ«ÒÆ -3500 */
    direction = Direction3D{0, 0, 1};
    offset    = -3500;
    loader.offset(tag12, direction, offset);

    /* Ìå1ºÍÌå12Åн» */
    /* TODO */

    /* еÄÌå11ºÍÌå12²¼¶û²¢ ±£ÁôÌå12 */
    loader.unionNode(newTag11, tag12);

    /* Ìå13 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-2398.6665401680511, 5999.2409883221771, 0.0000000000000000});
    points.push_back(Point3D{2401.3334598319489, 5999.2409883221790, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag13 = loader.addExtrude(points, bulges, extusion);

    /* Ìå14 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-673.66711640879771, 5999.2409883221790, 0.0000000000000000});
    points.push_back(Point3D{676.33403607269543, 5999.2409883221790, 0.0000000000000000});
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(-0.99999999999999989);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag14 = loader.addExtrude(points, bulges, extusion);

    /* Ìå13ºÍÌå14²¼¶û²î */
    loader.differentNode(tag13, tag14);

    /* Ìå13 ZÖáÆ«ÒÆ-3500 */
    direction = Direction3D{0, 0, 1};
    offset    = -3500;
    loader.offset(tag13, direction, offset);

    /* Ìå1ºÍÌå13Åн» */
    /* TODO */

    /* еÄÌå11ºÍÌå13²¼¶û²¢±£ÁôÌå13 */
    loader.unionNode(newTag11, tag13);

    before = loader.getAreaAndVolume(tag1);

    /* Ìå1ºÍеÄÌå11²¼¶û²î */
    loader.differentNode(tag1, newTag11);

    after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡ Ìå1 ²¼¶ûÇ°ºóµÄ Ìå»ý²î ºÍ Ãæ»ý²î */
    areaDifference   = after.first - before.first;
    volumeDifference = after.second - before.second;
    std::cout << areaDifference << ", " << volumeDifference << std::endl;

    /* ¶¨Òå¿ÕÌå ¿Û¼õÌå1 */
    auto subTag1 = loader.addEmpty();
    auto cycle   = [&loader, subTag1](const Point3D& point) {
        std::vector<Point3D> points;
        std::vector<double>  bulges;
        Vector3D             extusion;
        Direction3D          direction;
        double               offset;

        /* Ñ­»·Ìå1 */
        points.clear();
        bulges.clear();
        points.push_back(Point3D{-1000.0000000000000, 1000.0000000000001, 0.0000000000000000});
        points.push_back(Point3D{-1000.0000000000000, -1000.0000000000000, 0.0000000000000000});
        points.push_back(Point3D{1000.0000000000000, -1000.0000000000000, 0.0000000000000000});
        points.push_back(Point3D{1000.0000000000000, 1000.0000000000000, 0.0000000000000000});
        bulges.push_back(0.0000000000000000);
        bulges.push_back(0.0000000000000000);
        bulges.push_back(0.0000000000000000);
        bulges.push_back(0.0000000000000000);
        extusion       = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
        auto cycleTag1 = loader.addExtrude(points, bulges, extusion);

        /* Ñ­»·Ìå1 Æ«ÒÆ+ ´«ÈëµÄX,Y,Z×ø±êÖµ */
        loader.offset(cycleTag1, Direction3D{point}, point.length());

        /* Ñ­»·Ìå2 */
        auto   leftBottomPoint = Point3D{point.m_x - 1000, point.m_y - 1000, point.m_z + 0.0000000000005};
        double length          = 2000.0000000000036;
        double width           = 2000.0000000000036;
        double height          = 600;
        auto   cycleTag2       = loader.addBox(leftBottomPoint, length, width, height);

        /* Ñ­»·Ìå3 */
        points.clear();
        bulges.clear();
        points.push_back(Point3D{-32050.000001122418, -3.8396319723688066e-07, 0.0000000000000000});
        points.push_back(Point3D{32049.999998877582, -3.8387224776670337e-07, 0.0000000000000000});
        bulges.push_back(0.99999999999999989);
        bulges.push_back(0.99999999999999989);
        extusion       = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
        auto cycleTag3 = loader.addExtrude(points, bulges, extusion);

        /* Ñ­»·Ìå3 ZÖáÆ«ÒÆ -2900 */
        direction = Direction3D{0, 0, 1};
        offset    = -2900;
        loader.offset(cycleTag3, direction, offset);

        /* Ñ­»·Ìå3ºÍÌå2²¼¶û½» */
        loader.intersectNode(cycleTag3, cycleTag2);

        /* Ñ­»·Ìå1ºÍÌå3²¼¶û½» */
        loader.intersectNode(cycleTag1, cycleTag3);

        /* Ñ­»·Ìå1ºÍÌå1Åн» */
        /* TODO */

        /* ¿Û¼õÌå1ºÍÑ­»·Ìå1²¼¶û²¢ */
        loader.unionNode(subTag1, cycleTag1);
    };

    points.clear();
    points.push_back(Point3D{-21595.036456438422, -21609.173181957169, -2900.0000000000000});
    points.push_back(Point3D{-13505.711180076411, -13505.717935507526, -2900.0000000000000});
    points.push_back(Point3D{-2987.8729842756293, -18864.829751913778, -2900.0000000000000});
    points.push_back(Point3D{2987.9196792985895, -18864.830728476278, -2900.0000000000000});
    points.push_back(Point3D{13505.770265236089, -13505.722818320026, -2900.0000000000000});
    points.push_back(Point3D{17018.254640236089, -8671.2047519137759, -2900.0000000000000});
    points.push_back(Point3D{27220.281983986089, -13869.397623007526, -2900.0000000000000});
    points.push_back(Point3D{21602.139405861089, -21602.103677695028, -2900.0000000000000});
    points.push_back(Point3D{30173.926515236089, -4778.9669589450259, -2900.0000000000000});
    points.push_back(Point3D{18864.887452736089, -2987.8275546481514, -2900.0000000000000});
    points.push_back(Point3D{-18864.815672263911, -2987.8811435153389, -2900.0000000000000});
    points.push_back(Point3D{-30173.856687888911, -4779.0570468356509, -2900.0000000000000});
    points.push_back(Point3D{-13869.422117576411, -27220.218912070028, -2900.0000000000000});
    points.push_back(Point3D{-11781.052000388911, -23121.591958945028, -2900.0000000000000});
    points.push_back(Point3D{-8671.2131332014105, -17018.193521445028, -2900.0000000000000});
    points.push_back(Point3D{-27220.229734763911, -13869.391763632526, -2900.0000000000000});
    points.push_back(Point3D{-17018.194578513911, -8671.1974276950259, -2900.0000000000000});
    points.push_back(Point3D{-30173.856687888911, 4779.0965176174741, -2900.0000000000000});
    points.push_back(Point3D{-25630.485594138911, 4059.4959316799741, -2900.0000000000000});
    points.push_back(Point3D{-18864.815672263911, 2987.9134121487236, -2900.0000000000000});
    points.push_back(Point3D{-15863.798094138911, 8083.0535488674741, -2900.0000000000000});
    points.push_back(Point3D{-27220.216062888911, 13869.449056679974, -2900.0000000000000});
    points.push_back(Point3D{-21602.091062888911, 21602.130697304972, -2900.0000000000000});
    points.push_back(Point3D{-18349.393797263911, 18349.437337929972, -2900.0000000000000});
    points.push_back(Point3D{-13908.684812888911, 13908.728353554974, -2900.0000000000000});
    points.push_back(Point3D{-9584.8552230451605, 18811.339681679972, -2900.0000000000000});
    points.push_back(Point3D{-13869.425047263911, 27220.249837929972, -2900.0000000000000});
    points.push_back(Point3D{-4779.0493148420355, 30173.900228554972, -2900.0000000000000});
    points.push_back(Point3D{4779.0900894548395, 30173.904134804972, -2900.0000000000000});
    points.push_back(Point3D{13869.430421486089, 27220.275228554972, -2900.0000000000000});
    points.push_back(Point3D{9584.8806167985895, 18811.363119179972, -2900.0000000000000});
    points.push_back(Point3D{13908.739015236089, 13908.728353554974, -2900.0000000000000});
    points.push_back(Point3D{18349.453858986089, 18349.433431679972, -2900.0000000000000});
    points.push_back(Point3D{21602.147218361089, 21602.130697304972, -2900.0000000000000});
    points.push_back(Point3D{27220.268312111089, 13869.454916054974, -2900.0000000000000});
    points.push_back(Point3D{15863.852296486089, 8083.0574551174741, -2900.0000000000000});
    points.push_back(Point3D{18864.879640236089, 2987.9153652737236, -2900.0000000000000});
    points.push_back(Point3D{25630.543702736089, 4059.4900723049741, -2900.0000000000000});
    points.push_back(Point3D{30173.912843361089, 4779.0896816799741, -2900.0000000000000});
    points.push_back(Point3D{13869.432374611089, -27220.242349570028, -2900.0000000000000});
    points.push_back(Point3D{-4776.1108367703273, -30098.869302695028, -2900.0000000000000});
    points.push_back(Point3D{4779.0915542985895, -30098.869302695028, -2900.0000000000000});
    points.push_back(Point3D{-23121.594969138911, -11781.033365195026, -2900.0000000000000});
    points.push_back(Point3D{23121.637452736089, 11781.092611367474, -2900.0000000000000});
    points.push_back(Point3D{11781.053468361089, -23121.619302695028, -2900.0000000000000});
    points.push_back(Point3D{-23121.583250388911, 11781.089681679974, -2900.0000000000000});
    for (auto& point : points) { cycle(point); }

    before = loader.getAreaAndVolume(tag1);
    /* Ìå1ºÍ¿Û¼õÌå1²¼¶û²î */
    loader.differentNode(tag1, subTag1);
    after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡ Ìå1 ²¼¶ûÇ°ºóµÄ Ìå»ý²î ºÍ Ãæ»ý²î */
    areaDifference   = after.first - before.first;
    volumeDifference = after.second - before.second;
    std::cout << areaDifference << ", " << volumeDifference << std::endl;

    /* Ìå15£ºEnt1.bool */
    bottomPoint  = Point3D{0.0000, 0.0000, -3600.0000};
    radius       = 32150.0;
    direction    = Direction3D{0, 0, 100};
    auto tag15   = loader.addCylinder(bottomPoint, radius, direction);
    bottomPoint  = Point3D{1.3330, 5999.2412, -3600.0000};
    radius       = 11700.43125;
    direction    = Direction3D{0, 0, 100};
    auto tag15_1 = loader.addCylinder(bottomPoint, radius, direction);
    loader.differentNode(tag15, tag15_1);

    /* Ìå1ºÍÌå15²¼¶û²î */
    loader.differentNode(tag1, tag15);

    /* Ìå16 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-2503.6291053659488, 5999.2409883221790, -3500.0000000000000});
    points.push_back(Point3D{2501.2960250298465, 5999.2409883221790, -3500.0000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion   = Vector3D{-0.0000000000000000, -0.0000000000000000, -100.00000000000000};
    auto tag16 = loader.addExtrude(points, bulges, extusion);

    before = loader.getAreaAndVolume(tag1);
    /* Ìå1ºÍÌå16²¼¶û²î */
    loader.differentNode(tag1, tag16);
    after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡ Ìå1 ²¼¶ûÇ°ºóµÄ Ìå»ý²î ºÍ Ãæ»ý²î */
    areaDifference   = after.first - before.first;
    volumeDifference = after.second - before.second;
    std::cout << areaDifference << ", " << volumeDifference << std::endl;
}

void loaderTest2()
{
    Loader loader;

    std::vector<Point3D> points;
    std::vector<double>  bulges;
    Vector3D             extusion;
    Point3D              topPoint, bottomPoint, basePoint, leftBottomPoint;
    Direction3D          direction;

    double offset, radius, radius1, radius2, length, width, height, areaDifference, volumeDifference;

    std::pair<double, double> before, after;

    /* Ìå1 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag1 = loader.addExtrude(points, bulges, extusion);

    /* Ìå2 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag2 = loader.addExtrude(points, bulges, extusion);

    /* Ìå3 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag3 = loader.addExtrude(points, bulges, extusion);

    /* Ìå4 */
    topPoint    = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 0.0000000000000000};
    bottomPoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 3300.0000000000000000};
    radius1     = 32450.000000000000;
    radius2     = 33539.000000000000;
    auto tag4   = loader.addCone(topPoint, bottomPoint, radius1, radius2);

    /* Ìå3±»Çиî */
    direction = Direction3D{0, 0, 1};
    basePoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 0.0000000000000000};
    loader.split(tag3, basePoint, direction);

    /* Ìå3ºÍÌå4²¼¶û²î */
    loader.differentNode(tag3, tag4);

    /* Ìå5 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag5 = loader.addExtrude(points, bulges, extusion);

    /* Ìå5±»Çиî */
    direction = Direction3D{0, 0, 1};
    basePoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 3300.0000000000000000};
    loader.split(tag5, basePoint, direction);

    /* Ìå3ºÍÌå5²¼¶û²¢ */
    loader.unionNode(tag3, tag5);

    /* Ìå6 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392534654100421e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391228016184551e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag6 = loader.addExtrude(points, bulges, extusion);

    /* Ìå6±»Çиî */
    direction = Direction3D{0, 0, 1};
    basePoint = Point3D{-1.1224183253943920e-06, -3.8391322798592142e-07, 3300.0000000000000000};
    loader.split(tag6, basePoint, direction);

    /* Ìå3ºÍÌå6²¼¶û²¢ */
    loader.unionNode(tag3, tag6);

    /* Ìå2ºÍÌå3²¼¶û²î */
    loader.differentNode(tag2, tag3);

    /* Ìå7 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag7 = loader.addExtrude(points, bulges, extusion);

    /* Ìå8 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag8 = loader.addExtrude(points, bulges, extusion);

    /* Ìå9 */
    topPoint    = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 0.0000000000000000};
    bottomPoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    radius1     = 32450.000000000000;
    radius2     = 33539.000000000000;
    auto tag9   = loader.addCone(topPoint, bottomPoint, radius1, radius2);

    /* Ìå8±»Çиî */
    direction = Direction3D{0, 0, 1};
    basePoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    loader.split(tag8, basePoint, direction);

    /* Ìå8ºÍÌå9²¼¶û²î */
    loader.differentNode(tag8, tag9);

    /* Ìå10 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag10 = loader.addExtrude(points, bulges, extusion);

    /* Ìå10±»Çиî */
    direction = Direction3D{0, 0, 1};
    basePoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    loader.split(tag10, basePoint, direction);

    /* Ìå8ºÍÌå10²¼¶û²¢ */
    loader.unionNode(tag8, tag10);

    /* Ìå11 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{32449.999998877582, -3.8392495305561452e-07, 0.0000000000000000});
    points.push_back(Point3D{-32450.000001122418, -3.8391231093737305e-07, 0.0000000000000000});
    points.push_back(Point3D{-33539.000001122418, -3.8391191745198337e-07, 0.0000000000000000});
    points.push_back(Point3D{33538.999998877582, -3.8392498383114206e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 3300.0000000000000};
    auto tag11 = loader.addExtrude(points, bulges, extusion);

    /* Ìå11±»Çиî */
    direction = Direction3D{0, 0, 1};
    basePoint = Point3D{-1.1224183253943920e-06, -3.8392403600706615e-07, 3300.0000000000000000};
    loader.split(tag11, basePoint, direction);

    /* Ìå8ºÍÌå11²¼¶û²¢ */
    loader.unionNode(tag8, tag11);

    /* Ìå7ºÍÌå8²¼¶û²î */
    loader.differentNode(tag7, tag8);

    /* Ìå2ºÍÌå7²¼¶û²¢ */
    loader.unionNode(tag2, tag7);

    /* Ìå1ºÍÌå2²¼¶û²¢ */
    loader.unionNode(tag1, tag2);

    /* Ìå1 ZÖáÆ«ÒÆ -3600 */
    direction = Direction3D{0, 0, 1};
    offset    = -3600;
    loader.offset(tag1, direction, offset);

    /* Ìå111 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-32050.000001122418, -3.8396319723688066e-07, 0.0000000000000000});
    points.push_back(Point3D{32049.999998877582, -3.8387224776670337e-07, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion    = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag111 = loader.addExtrude(points, bulges, extusion);

    /* Ìå0 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-11798.670446418590, 5999.2409883221799, 0.0000000000000000});
    points.push_back(Point3D{11801.337366082498, 5999.2409883221590, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion  = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag0 = loader.addExtrude(points, bulges, extusion);

    /* Ìå111ºÍÌå0²¼¶û²î */
    loader.differentNode(tag111, tag0);

    /* Ìå111 ZÖáÆ«ÒÆ -3500 */
    direction = Direction3D{0, 0, 1};
    offset    = -3500;
    loader.offset(tag111, direction, offset);

    /* Ìå1ºÍÌå111Åн» */
    /* TODO */

    /* Ìå12 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{676.33403607269543, 5999.2409883221790, 0.0000000000000000});
    points.push_back(Point3D{-673.66711640879771, 5999.2409883221790, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag12 = loader.addExtrude(points, bulges, extusion);

    /* Ìå12 ZÖáÆ«ÒÆ -3500 */
    direction = Direction3D{0, 0, 1};
    offset    = -3500;
    loader.offset(tag12, direction, offset);

    /* Ìå1ºÍÌå12Åн» */
    /* TODO */

    /* Ìå111ºÍÌå12²¼¶û²¢ */
    loader.unionNode(tag111, tag12);

    /* Ìå13 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-2398.6665401680511, 5999.2409883221771, 0.0000000000000000});
    points.push_back(Point3D{2401.3334598319489, 5999.2409883221790, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag13 = loader.addExtrude(points, bulges, extusion);

    /* Ìå14 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-673.66711640879771, 5999.2409883221790, 0.0000000000000000});
    points.push_back(Point3D{676.33403607269543, 5999.2409883221790, 0.0000000000000000});
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(-0.99999999999999989);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
    auto tag14 = loader.addExtrude(points, bulges, extusion);

    /* Ìå13ºÍÌå14²¼¶û²î */
    loader.differentNode(tag13, tag14);

    /* Ìå13 ZÖáÆ«ÒÆ -3500 */
    direction = Direction3D{0, 0, 1};
    offset    = -3500;
    loader.offset(tag13, direction, offset);

    /* Ìå1ºÍÌå13Åн» */
    /* TODO */

    /* Ìå111ºÍÌå13²¼¶û²¢ */
    loader.unionNode(tag111, tag13);

    // before = loader.getAreaAndVolume(tag1);
    /* Ìå1ºÍÌå111²¼¶û²î */
    loader.differentNode(tag1, tag111);
    // after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡Ìå1 ²¼¶ûÇ°ºóµÄÌå»ý²îºÍÃæ»ý²î */
    // areaDifference = after.first - before.first;
    // volumeDifference = after.second - before.second;
    // std::cout << areaDifference << ", " << volumeDifference << std::endl;

    /* ¶¨Òå¿ÕÌå ¿Û¼õÌå1 */
    auto subTag1 = loader.addEmpty();
    auto cycle   = [&loader, subTag1](const Point3D& point) {
        std::vector<Point3D> points;
        std::vector<double>  bulges;
        Vector3D             extusion;
        Direction3D          direction;
        double               offset;

        /* Ñ­»·Ìå1 */
        points.clear();
        bulges.clear();
        points.push_back(Point3D{-1000.0000000000000, 1000.0000000000001, 0.0000000000000000});
        points.push_back(Point3D{-1000.0000000000000, -1000.0000000000000, 0.0000000000000000});
        points.push_back(Point3D{1000.0000000000000, -1000.0000000000000, 0.0000000000000000});
        points.push_back(Point3D{1000.0000000000000, 1000.0000000000000, 0.0000000000000000});
        bulges.push_back(0.0000000000000000);
        bulges.push_back(0.0000000000000000);
        bulges.push_back(0.0000000000000000);
        bulges.push_back(0.0000000000000000);
        extusion       = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
        auto cycleTag1 = loader.addExtrude(points, bulges, extusion);

        /* Ñ­»·Ìå1 Æ«ÒÆ+ ´«ÈëµÄX,Y,Z×ø±êÖµ */
        loader.offset(cycleTag1, Direction3D{point}, point.length());

        /* Ñ­»·Ìå2 */
        auto   leftBottomPoint = Point3D{point.m_x - 1000, point.m_y - 1000, point.m_z + 0.0000000000005};
        double length          = 2000.0000000000036;
        double width           = 2000.0000000000036;
        double height          = 600;
        auto   cycleTag2       = loader.addBox(leftBottomPoint, length, width, height);

        /* Ñ­»·Ìå3 */
        points.clear();
        bulges.clear();
        points.push_back(Point3D{-32050.000001122418, -3.8396319723688066e-07, 0.0000000000000000});
        points.push_back(Point3D{32049.999998877582, -3.8387224776670337e-07, 0.0000000000000000});
        bulges.push_back(0.99999999999999989);
        bulges.push_back(0.99999999999999989);
        extusion       = Vector3D{0.0000000000000000, 0.0000000000000000, 600.0000000000000};
        auto cycleTag3 = loader.addExtrude(points, bulges, extusion);

        /* Ñ­»·Ìå3 ZÖáÆ«ÒÆ -2900 */
        direction = Direction3D{0, 0, 1};
        offset    = -2900;
        loader.offset(cycleTag3, direction, offset);

        /* Ñ­»·Ìå3ºÍÌå2²¼¶û½» */
        loader.intersectNode(cycleTag3, cycleTag2);

        /* Ñ­»·Ìå1ºÍÌå3²¼¶û½» */
        loader.intersectNode(cycleTag1, cycleTag3);

        /* Ñ­»·Ìå1ºÍÌå1Åн» */
        /* TODO */

        /* ¿Û¼õÌå1ºÍÑ­»·Ìå1²¼¶û²¢ */
        loader.unionNode(subTag1, cycleTag1);
    };

    points.clear();
    points.push_back(Point3D{-21595.036456438422, -21609.173181957169, -2900.0000000000000});
    points.push_back(Point3D{-13505.711180076411, -13505.717935507526, -2900.0000000000000});
    points.push_back(Point3D{-2987.8729842756293, -18864.829751913778, -2900.0000000000000});
    points.push_back(Point3D{2987.9196792985895, -18864.830728476278, -2900.0000000000000});
    points.push_back(Point3D{13505.770265236089, -13505.722818320026, -2900.0000000000000});
    points.push_back(Point3D{17018.254640236089, -8671.2047519137759, -2900.0000000000000});
    points.push_back(Point3D{27220.281983986089, -13869.397623007526, -2900.0000000000000});
    points.push_back(Point3D{21602.139405861089, -21602.103677695028, -2900.0000000000000});
    points.push_back(Point3D{30173.926515236089, -4778.9669589450259, -2900.0000000000000});
    points.push_back(Point3D{18864.887452736089, -2987.8275546481514, -2900.0000000000000});
    points.push_back(Point3D{-18864.815672263911, -2987.8811435153389, -2900.0000000000000});
    points.push_back(Point3D{-30173.856687888911, -4779.0570468356509, -2900.0000000000000});
    points.push_back(Point3D{-13869.422117576411, -27220.218912070028, -2900.0000000000000});
    points.push_back(Point3D{-11781.052000388911, -23121.591958945028, -2900.0000000000000});
    points.push_back(Point3D{-8671.2131332014105, -17018.193521445028, -2900.0000000000000});
    points.push_back(Point3D{-27220.229734763911, -13869.391763632526, -2900.0000000000000});
    points.push_back(Point3D{-17018.194578513911, -8671.1974276950259, -2900.0000000000000});
    points.push_back(Point3D{-30173.856687888911, 4779.0965176174741, -2900.0000000000000});
    points.push_back(Point3D{-25630.485594138911, 4059.4959316799741, -2900.0000000000000});
    points.push_back(Point3D{-18864.815672263911, 2987.9134121487236, -2900.0000000000000});
    points.push_back(Point3D{-15863.798094138911, 8083.0535488674741, -2900.0000000000000});
    points.push_back(Point3D{-27220.216062888911, 13869.449056679974, -2900.0000000000000});
    points.push_back(Point3D{-21602.091062888911, 21602.130697304972, -2900.0000000000000});
    points.push_back(Point3D{-18349.393797263911, 18349.437337929972, -2900.0000000000000});
    points.push_back(Point3D{-13908.684812888911, 13908.728353554974, -2900.0000000000000});
    points.push_back(Point3D{-9584.8552230451605, 18811.339681679972, -2900.0000000000000});
    points.push_back(Point3D{-13869.425047263911, 27220.249837929972, -2900.0000000000000});
    points.push_back(Point3D{-4779.0493148420355, 30173.900228554972, -2900.0000000000000});
    points.push_back(Point3D{4779.0900894548395, 30173.904134804972, -2900.0000000000000});
    points.push_back(Point3D{13869.430421486089, 27220.275228554972, -2900.0000000000000});
    points.push_back(Point3D{9584.8806167985895, 18811.363119179972, -2900.0000000000000});
    points.push_back(Point3D{13908.739015236089, 13908.728353554974, -2900.0000000000000});
    points.push_back(Point3D{18349.453858986089, 18349.433431679972, -2900.0000000000000});
    points.push_back(Point3D{21602.147218361089, 21602.130697304972, -2900.0000000000000});
    points.push_back(Point3D{27220.268312111089, 13869.454916054974, -2900.0000000000000});
    points.push_back(Point3D{15863.852296486089, 8083.0574551174741, -2900.0000000000000});
    points.push_back(Point3D{18864.879640236089, 2987.9153652737236, -2900.0000000000000});
    points.push_back(Point3D{25630.543702736089, 4059.4900723049741, -2900.0000000000000});
    points.push_back(Point3D{30173.912843361089, 4779.0896816799741, -2900.0000000000000});
    points.push_back(Point3D{13869.432374611089, -27220.242349570028, -2900.0000000000000});
    points.push_back(Point3D{-4776.1108367703273, -30098.869302695028, -2900.0000000000000});
    points.push_back(Point3D{4779.0915542985895, -30098.869302695028, -2900.0000000000000});
    points.push_back(Point3D{-23121.594969138911, -11781.033365195026, -2900.0000000000000});
    points.push_back(Point3D{23121.637452736089, 11781.092611367474, -2900.0000000000000});
    points.push_back(Point3D{11781.053468361089, -23121.619302695028, -2900.0000000000000});
    points.push_back(Point3D{-23121.583250388911, 11781.089681679974, -2900.0000000000000});
    for (auto& point : points) { cycle(point); }

    // before = loader.getAreaAndVolume(tag1);
    /* Ìå1ºÍ¿Û¼õÌå1²¼¶û²î */
    loader.differentNode(tag1, subTag1);
    // after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡ Ìå1 ²¼¶ûÇ°ºóµÄ Ìå»ý²î ºÍ Ãæ»ý²î */
    // areaDifference = after.first - before.first;
    // volumeDifference = after.second - before.second;
    // std::cout << areaDifference << ", " << volumeDifference << std::endl;

    /* Ìå15£ºEnt1.bool */
    bottomPoint  = Point3D{0.0000, 0.0000, -3600.0000};
    radius       = 32150.0;
    direction    = Direction3D{0, 0, 100};
    auto tag15   = loader.addCylinder(bottomPoint, radius, direction);
    bottomPoint  = Point3D{1.3330, 5999.2412, -3600.0000};
    radius       = 11700.43125;
    direction    = Direction3D{0, 0, 100};
    auto tag15_1 = loader.addCylinder(bottomPoint, radius, direction);
    loader.differentNode(tag15, tag15_1);

    /* Ìå1ºÍÌå15²¼¶û²î */
    loader.differentNode(tag1, tag15);

    /* Ìå16 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-2503.6291053659488, 5999.2409883221790, -3500.0000000000000});
    points.push_back(Point3D{2501.2960250298465, 5999.2409883221790, -3500.0000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.99999999999999989);
    extusion   = Vector3D{-0.0000000000000000, -0.0000000000000000, -100.00000000000000};
    auto tag16 = loader.addExtrude(points, bulges, extusion);

    /* Ìå1ºÍÌå16²¼¶û²î */
    loader.differentNode(tag1, tag16);

    /* Ìå17 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{2079.8334638622341, 5999.2409883221844, 0.0000000000000000});
    points.push_back(Point3D{-2070.1665441983364, 5999.2409883221844, 0.0000000000000000});
    points.push_back(Point3D{-1320.1665441983364, 5999.2409883221844, 0.0000000000000000});
    points.push_back(Point3D{1329.8334638622341, 5999.2409883221844, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2750.0000000000000};
    auto tag17 = loader.addExtrude(points, bulges, extusion);

    /* Ìå17 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag17, direction, offset);

    /* Ìå1ºÍÌå17²¼¶û²î */
    loader.differentNode(tag1, tag17);

    /* Ìå18 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{-2070.1665441983364, 5999.2409883221844, 0.0000000000000000});
    points.push_back(Point3D{2079.8334638622341, 5999.2409883221844, 0.0000000000000000});
    points.push_back(Point3D{1329.8334638622341, 5999.2409883221844, 0.0000000000000000});
    points.push_back(Point3D{-1320.1665441983364, 5999.2409883221844, 0.0000000000000000});
    bulges.push_back(0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(-0.99999999999999989);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2750.0000000000000};
    auto tag18 = loader.addExtrude(points, bulges, extusion);

    /* Ìå18 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag18, direction, offset);

    /* Ìå1ºÍÌå18²¼¶û²î */
    loader.differentNode(tag1, tag18);

    /* Ìå19 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{8760.4644464528919, -16861.795338417785, 0.0000000000000000});
    points.push_back(Point3D{5893.9646280986062, -18064.309214597473, 0.0000000000000000});
    points.push_back(Point3D{6248.1524494726591, -18208.769763083357, 0.0000000000000000});
    points.push_back(Point3D{8651.1159137951836, -17197.859075721935, 0.0000000000000000});
    bulges.push_back(-0.039803147455118697);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.032943018176267741);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
    auto tag19 = loader.addExtrude(points, bulges, extusion);

    /* Ìå19 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag19, direction, offset);

    /* Ìå1ºÍÌå19²¼¶û²î */
    loader.differentNode(tag1, tag19);

    /* Ìå20 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{8472.1973651856952, -23124.378331468590, 0.0000000000000000});
    points.push_back(Point3D{11234.316117012168, -21717.002618593218, 0.0000000000000000});
    points.push_back(Point3D{10898.067054009927, -21607.748991111552, 0.0000000000000000});
    points.push_back(Point3D{8581.4512221945606, -22788.128674499021, 0.0000000000000000});
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
    auto tag20 = loader.addExtrude(points, bulges, extusion);

    /* Ìå20 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag20, direction, offset);

    /* Ìå1ºÍÌå20²¼¶û²î */
    loader.differentNode(tag1, tag20);

    /* Ìå21 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{11234.316117012169, -21717.002618593222, 0.0000000000000000});
    points.push_back(Point3D{8760.4644464528919, -16861.795338417785, 0.0000000000000000});
    points.push_back(Point3D{8651.1159137951836, -17197.859075721935, 0.0000000000000000});
    points.push_back(Point3D{10898.067054009929, -21607.748991111555, 0.0000000000000000});
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
    auto tag21 = loader.addExtrude(points, bulges, extusion);

    /* Ìå21 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag21, direction, offset);

    /* Ìå1ºÍÌå21²¼¶û²î */
    loader.differentNode(tag1, tag21);

    /* Ìå22 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{5893.9646280986062, -18064.309214597473, 0.0000000000000000});
    points.push_back(Point3D{8472.1973651856970, -23124.378331468593, 0.0000000000000000});
    points.push_back(Point3D{8581.4512221945624, -22788.128674499025, 0.0000000000000000});
    points.push_back(Point3D{6248.1524494726591, -18208.769763083357, 0.0000000000000000});
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
    auto tag22 = loader.addExtrude(points, bulges, extusion);

    /* Ìå22 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag22, direction, offset);

    // before = loader.getAreaAndVolume(tag1);
    /* Ìå1ºÍÌå22²¼¶û²î */
    loader.differentNode(tag1, tag22);
    // after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡Ìå1 ²¼¶ûÇ°ºóµÄÌå»ý²îºÍÃæ»ý²î */
    // areaDifference = after.first - before.first;
    // volumeDifference = after.second - before.second;
    // std::cout << areaDifference << ", " << volumeDifference << std::endl;

    /* Ìå23 */
    points.clear();
    bulges.clear();
    points.push_back(Point3D{7380.7150904719992, -20706.098050612181, 0.0000000000000000});
    points.push_back(Point3D{9920.1451018985645, -19412.300707257506, 0.0000000000000000});
    points.push_back(Point3D{9829.3529561354007, -19234.096368736471, 0.0000000000000000});
    points.push_back(Point3D{7289.9229447088355, -20527.893712091147, 0.0000000000000000});
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    bulges.push_back(0.0000000000000000);
    extusion   = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
    auto tag23 = loader.addExtrude(points, bulges, extusion);

    /* Ìå23 ZÖáÆ«ÒÆ -2900 */
    direction = Direction3D{0, 0, 1};
    offset    = -2900;
    loader.offset(tag23, direction, offset);

    // before = loader.getAreaAndVolume(tag1);
    /* Ìå1ºÍÌå23²¼¶û²î */
    loader.differentNode(tag1, tag23);
    // after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡Ìå1 ²¼¶ûÇ°ºóµÄÌå»ý²îºÍÃæ»ý²î */
    // areaDifference = after.first - before.first;
    // volumeDifference = after.second - before.second;
    // std::cout << areaDifference << ", " << volumeDifference << std::endl;

    /* ÒÔÏÂΪһ¸öÑ­»·£¬Í¹¶È×é¹Ì¶¨£¬µ«µã×é²»Ò»Ñù£¬ÆäËû²Ù×÷Ò»Ö */
    auto cycle1 = [&loader, tag1](const Point3D& point1, const Point3D point2) {
        /* Ñ­»·Ìå */
        const std::vector<Point3D> points   = {point1, point2};
        std::vector<double>        bulges   = {0.99999999999999989, 0.99999999999999989};
        Vector3D                   extusion = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
        auto                       cycleTag = loader.addExtrude(points, bulges, extusion);

        /* Ñ­»·Ìå ZÖáÆ«ÒÆ -2900 */
        Direction3D direction = Direction3D{0, 0, 1};
        double      offset    = -2900;
        loader.offset(cycleTag, direction, offset);

        /* Ìå1ºÍÑ­»·Ìå²¼¶û²î */
        loader.differentNode(tag1, cycleTag);
    };

    points.clear();
    bulges.clear();
    points.push_back(Point3D{25330.544191030145, 4059.4890957491152, 0.0000000000000000});
    points.push_back(Point3D{25930.544191030145, 4059.4890957491152, 0.0000000000000000});
    points.push_back(Point3D{2637.9248093705974, -18864.831701145784, 0.0000000000000000});
    points.push_back(Point3D{3337.9248093705974, -18864.831701145784, 0.0000000000000000});
    points.push_back(Point3D{-19214.815183982137, -2987.8808536118449, 0.0000000000000000});
    points.push_back(Point3D{-18514.815183982137, -2987.8808536118449, 0.0000000000000000});
    points.push_back(Point3D{13155.774659765651, -13505.730142548899, 0.0000000000000000});
    points.push_back(Point3D{13855.774659765651, -13505.730142548899, 0.0000000000000000});
    points.push_back(Point3D{-23421.584711222677, 11781.088222738428, 0.0000000000000000});
    points.push_back(Point3D{-22821.584711222677, 11781.088222738428, 0.0000000000000000});
    points.push_back(Point3D{-21952.083741631068, -21602.101728577210, 0.0000000000000000});
    points.push_back(Point3D{-21252.083741631068, -21602.101728577210, 0.0000000000000000});
    points.push_back(Point3D{-3337.8756971632247, -18864.831700995899, 0.0000000000000000});
    points.push_back(Point3D{-2637.8756971632247, -18864.831700995899, 0.0000000000000000});
    points.push_back(Point3D{22821.635010756669, 11781.088216097109, 0.0000000000000000});
    points.push_back(Point3D{23421.635010756669, 11781.088216097109, 0.0000000000000000});
    points.push_back(Point3D{8321.2448748154566, -17018.220376670986, 0.0000000000000000});
    points.push_back(Point3D{9021.2448748154566, -17018.220376670986, 0.0000000000000000});
    points.push_back(Point3D{-1871.5656374104437, -9922.6107521542435, 0.0000000000000000});
    points.push_back(Point3D{-1271.5656374104440, -9922.6107521542435, 0.0000000000000000});
    points.push_back(Point3D{26920.265871888550, 13869.448081589901, 0.0000000000000000});
    points.push_back(Point3D{27520.265871888550, 13869.448081589901, 0.0000000000000000});
    points.push_back(Point3D{29873.915284768678, 4779.0894375231728, 0.0000000000000000});
    points.push_back(Point3D{30473.915284768678, 4779.0894375231728, 0.0000000000000000});
    points.push_back(Point3D{1271.6142550302902, -9922.6210172974243, 0.0000000000000000});
    points.push_back(Point3D{1871.6142550302900, -9922.6210172974243, 0.0000000000000000});
    points.push_back(Point3D{7608.7448703002883, -7908.7010952570563, 0.0000000000000000});
    points.push_back(Point3D{8208.7448703002883, -7908.7010952570563, 0.0000000000000000});
    points.push_back(Point3D{11431.053468361089, -23121.619302695020, 0.0000000000000000});
    points.push_back(Point3D{12131.053468361089, -23121.619302695020, 0.0000000000000000});
    points.push_back(Point3D{21252.143796979217, -21602.113447324591, 0.0000000000000000});
    points.push_back(Point3D{21952.143796979217, -21602.113447324591, 0.0000000000000000});
    points.push_back(Point3D{26870.284425387275, -13869.400552711551, 0.0000000000000000});
    points.push_back(Point3D{27570.284425387275, -13869.400552711551, 0.0000000000000000});
    points.push_back(Point3D{16668.254151753965, -8671.2113439714158, 0.0000000000000000});
    points.push_back(Point3D{17368.254151753965, -8671.2113439714158, 0.0000000000000000});
    points.push_back(Point3D{21302.142824993702, 21602.129722254482, 0.0000000000000000});
    points.push_back(Point3D{21902.142824993702, 21602.129722254482, 0.0000000000000000});
    points.push_back(Point3D{18514.882078273164, -2987.8308623732737, 0.0000000000000000});
    points.push_back(Point3D{19214.882078273164, -2987.8308623732737, 0.0000000000000000});
    points.push_back(Point3D{-27570.225340223697, -13869.390298805301, 0.0000000000000000});
    points.push_back(Point3D{-26870.225340223697, -13869.390298805301, 0.0000000000000000});
    points.push_back(Point3D{15563.854737884307, 8083.0486660407769, 0.0000000000000000});
    points.push_back(Point3D{16163.854737884307, 8083.0486660407769, 0.0000000000000000});
    points.push_back(Point3D{29823.926027013978, -4778.9706820347201, 0.0000000000000000});
    points.push_back(Point3D{30523.926027013978, -4778.9706820347201, 0.0000000000000000});
    points.push_back(Point3D{-25930.485105855274, 4059.4890957491152, 0.0000000000000000});
    points.push_back(Point3D{-25330.485105855274, 4059.4890957491152, 0.0000000000000000});
    points.push_back(Point3D{-15906.105228972388, 2471.7791264631815, 0.0000000000000000});
    points.push_back(Point3D{-15306.105228972388, 2471.7791264631815, 0.0000000000000000});
    points.push_back(Point3D{-14208.685301157355, 13908.728353561615, 0.0000000000000000});
    points.push_back(Point3D{-13608.685301157355, 13908.728353561615, 0.0000000000000000});
    points.push_back(Point3D{15306.173097269726, 2471.7791347907769, 0.0000000000000000});
    points.push_back(Point3D{15906.173097269726, 2471.7791347907769, 0.0000000000000000});
    points.push_back(Point3D{-30523.856199605914, -4779.0607699771499, 0.0000000000000000});
    points.push_back(Point3D{-29823.856199605914, -4779.0607699771499, 0.0000000000000000});
    points.push_back(Point3D{13608.744379809476, 13908.728344973482, 0.0000000000000000});
    points.push_back(Point3D{14208.744379809476, 13908.728344973482, 0.0000000000000000});
    points.push_back(Point3D{-19164.815183980274, 2987.9090176032769, 0.0000000000000000});
    points.push_back(Point3D{-18564.815183980274, 2987.9090176032769, 0.0000000000000000});
    points.push_back(Point3D{18049.454334036331, 18349.429508093293, 0.0000000000000000});
    points.push_back(Point3D{18649.454334036331, 18349.429508093293, 0.0000000000000000});
    points.push_back(Point3D{18564.882081644726, 2987.9090176032769, 0.0000000000000000});
    points.push_back(Point3D{19164.882081644726, 2987.9090176032769, 0.0000000000000000});
    points.push_back(Point3D{-18649.394773816515, 18349.429525433647, 0.0000000000000000});
    points.push_back(Point3D{-18049.394773816515, 18349.429525433647, 0.0000000000000000});
    points.push_back(Point3D{-16163.795652730274, 8083.0486660407769, 0.0000000000000000});
    points.push_back(Point3D{-15563.795652730274, 8083.0486660407769, 0.0000000000000000});
    points.push_back(Point3D{-13089.545652741857, 6516.6287441791064, 0.0000000000000000});
    points.push_back(Point3D{-12489.545652741857, 6516.6287441791064, 0.0000000000000000});
    points.push_back(Point3D{-12432.865969395847, 1921.6695098721102, 0.0000000000000000});
    points.push_back(Point3D{-11832.865969395847, 1921.6695098721102, 0.0000000000000000});
    points.push_back(Point3D{11832.924069322587, 1921.6787872227869, 0.0000000000000000});
    points.push_back(Point3D{12432.924069322587, 1921.6787872227869, 0.0000000000000000});
    points.push_back(Point3D{-14219.424558988423, -27220.219888640844, 0.0000000000000000});
    points.push_back(Point3D{-13519.424558988423, -27220.219888640844, 0.0000000000000000});
    points.push_back(Point3D{-8208.6860335274250, -7908.7010897282598, 0.0000000000000000});
    points.push_back(Point3D{-7608.6860335274250, -7908.7010897282598, 0.0000000000000000});
    points.push_back(Point3D{11531.074457970564, 23121.638501036170, 0.0000000000000000});
    points.push_back(Point3D{12031.074457970564, 23121.638501036170, 0.0000000000000000});
    points.push_back(Point3D{-21902.083733627456, 21602.129728298649, 0.0000000000000000});
    points.push_back(Point3D{-21302.083733627456, 21602.129728298649, 0.0000000000000000});
    points.push_back(Point3D{-5079.0456527201459, 30173.900228539613, 0.0000000000000000});
    points.push_back(Point3D{-4479.0456527201459, 30173.900228539613, 0.0000000000000000});
    points.push_back(Point3D{-3223.9956954814261, 18461.557455070157, 0.0000000000000000});
    points.push_back(Point3D{-2623.9956954814261, 18461.557455070157, 0.0000000000000000});
    points.push_back(Point3D{2624.0444348900346, 18461.557454720794, 0.0000000000000000});
    points.push_back(Point3D{3224.0444348900346, 18461.557454720794, 0.0000000000000000});
    points.push_back(Point3D{-8405.0161077585071, 15906.991054460479, 0.0000000000000000});
    points.push_back(Point3D{-7805.0161077585071, 15906.991054460479, 0.0000000000000000});
    points.push_back(Point3D{4479.0942398422048, 30173.900228537284, 0.0000000000000000});
    points.push_back(Point3D{5079.0942398422048, 30173.900228537284, 0.0000000000000000});
    points.push_back(Point3D{-30473.855223292368, 4779.0894371719478, 0.0000000000000000});
    points.push_back(Point3D{-29873.855223292368, 4779.0894371719478, 0.0000000000000000});
    points.push_back(Point3D{-9834.8557113136048, 18811.339681665777, 0.0000000000000000});
    points.push_back(Point3D{-9334.8557113136048, 18811.339681665777, 0.0000000000000000});
    points.push_back(Point3D{13569.434806959180, 27220.270333465378, 0.0000000000000000});
    points.push_back(Point3D{14169.434806959180, 27220.270333465378, 0.0000000000000000});
    points.push_back(Point3D{13452.094479468651, -2178.0609130331286, 0.0000000000000000});
    points.push_back(Point3D{14052.094479468651, -2178.0609130331286, 0.0000000000000000});
    points.push_back(Point3D{7635.4943863257067, -4043.3108920587547, 0.0000000000000000});
    points.push_back(Point3D{8235.4943863257067, -4043.3108920587547, 0.0000000000000000});
    points.push_back(Point3D{-5030.7456039006938, -9284.6107577729126, 0.0000000000000000});
    points.push_back(Point3D{-4430.7456039006938, -9284.6107577729126, 0.0000000000000000});
    points.push_back(Point3D{9334.8840347801452, 18811.357259790777, 0.0000000000000000});
    points.push_back(Point3D{9834.8840347801452, 18811.357259790777, 0.0000000000000000});
    points.push_back(Point3D{-3675.6656478448422, 21628.976400436615, 0.0000000000000000});
    points.push_back(Point3D{-3175.6656478448422, 21628.976400436615, 0.0000000000000000});
    points.push_back(Point3D{3809.4943863322260, 25630.529134790777, 0.0000000000000000});
    points.push_back(Point3D{4309.4943863322260, 25630.529134790777, 0.0000000000000000});
    points.push_back(Point3D{4430.7846695982153, -9284.6210116034345, 0.0000000000000000});
    points.push_back(Point3D{5030.7846695982153, -9284.6210116034345, 0.0000000000000000});
    points.push_back(Point3D{-13855.715086132754, -13505.720376673606, 0.0000000000000000});
    points.push_back(Point3D{-13155.715086132754, -13505.720376673606, 0.0000000000000000});
    points.push_back(Point3D{-12131.054926622368, -23121.600743537347, 0.0000000000000000});
    points.push_back(Point3D{-11431.054926622368, -23121.600743537347, 0.0000000000000000});
    points.push_back(Point3D{-10578.765375099087, -1627.9909095301846, 0.0000000000000000});
    points.push_back(Point3D{-9978.7653750990867, -1627.9909095301846, 0.0000000000000000});
    points.push_back(Point3D{3175.7141128947260, 21628.976400436615, 0.0000000000000000});
    points.push_back(Point3D{3675.7141128947260, 21628.976400436615, 0.0000000000000000});
    points.push_back(Point3D{11239.354737904854, 11539.338705116606, 0.0000000000000000});
    points.push_back(Point3D{11839.354737904854, 11539.338705116606, 0.0000000000000000});
    points.push_back(Point3D{-17318.196043352364, -8671.2008456719195, 0.0000000000000000});
    points.push_back(Point3D{-16718.196043352364, -8671.2008456719195, 0.0000000000000000});
    points.push_back(Point3D{-14169.424558975501, 27220.248861367945, 0.0000000000000000});
    points.push_back(Point3D{-13569.424558975501, 27220.248861367945, 0.0000000000000000});
    points.push_back(Point3D{9978.8439957064693, -1627.9708957259863, 0.0000000000000000});
    points.push_back(Point3D{10578.843995706469, -1627.9708957259863, 0.0000000000000000});
    points.push_back(Point3D{13519.435304297367, -27220.250162088065, 0.0000000000000000});
    points.push_back(Point3D{14219.435304297367, -27220.250162088065, 0.0000000000000000});
    points.push_back(Point3D{-3550.8955367645249, -6380.2710360850760, 0.0000000000000000});
    points.push_back(Point3D{-2950.8955367645249, -6380.2710360850760, 0.0000000000000000});
    points.push_back(Point3D{10709.754156451614, -5609.7207374573773, 0.0000000000000000});
    points.push_back(Point3D{11309.754156451614, -5609.7207374573773, 0.0000000000000000});
    points.push_back(Point3D{12489.604245378461, 6516.6389926101110, 0.0000000000000000});
    points.push_back(Point3D{13089.604245378461, 6516.6389926101110, 0.0000000000000000});
    points.push_back(Point3D{-8235.4355452836026, -4043.3108920448431, 0.0000000000000000});
    points.push_back(Point3D{-7635.4355452836026, -4043.3108920448431, 0.0000000000000000});
    points.push_back(Point3D{2950.9448257543263, -6380.2808017734642, 0.0000000000000000});
    points.push_back(Point3D{3550.9448257543263, -6380.2808017734642, 0.0000000000000000});
    points.push_back(Point3D{-11309.696043347765, -5609.7207431293646, 0.0000000000000000});
    points.push_back(Point3D{-10709.696043347765, -5609.7207431293646, 0.0000000000000000});
    points.push_back(Point3D{-11839.285398820706, 11539.328939490792, 0.0000000000000000});
    points.push_back(Point3D{-11239.285398820706, 11539.328939490792, 0.0000000000000000});
    points.push_back(Point3D{-14052.005613667367, -2178.0908755634300, 0.0000000000000000});
    points.push_back(Point3D{-13452.005613667367, -2178.0908755634300, 0.0000000000000000});
    points.push_back(Point3D{-9021.2153273623553, -17018.201329904943, 0.0000000000000000});
    points.push_back(Point3D{-8321.2153273623553, -17018.201329904943, 0.0000000000000000});
    points.push_back(Point3D{-4309.4457381869433, 25630.529134784956, 0.0000000000000000});
    points.push_back(Point3D{-3809.4457381869433, 25630.529134784956, 0.0000000000000000});
    points.push_back(Point3D{-27520.215574607428, 13869.448080100890, 0.0000000000000000});
    points.push_back(Point3D{-26920.215574607428, 13869.448080100890, 0.0000000000000000});
    points.push_back(Point3D{-12031.065183990693, 23121.618978540777, 0.0000000000000000});
    points.push_back(Point3D{-11531.065183990693, 23121.618978540777, 0.0000000000000000});
    points.push_back(Point3D{7805.0446787483525, 15907.018391851525, 0.0000000000000000});
    points.push_back(Point3D{8405.0446787483525, 15907.018391851525, 0.0000000000000000});
    points.push_back(Point3D{4354.0942397164181, -30098.870279427545, 0.0000000000000000});
    points.push_back(Point3D{5204.0942397164044, -30098.870279427545, 0.0000000000000000});
    points.push_back(Point3D{-5204.0456527279457, -30098.870279264738, 0.0000000000000000});
    points.push_back(Point3D{-4354.0456527279594, -30098.870279264738, 0.0000000000000000});
    points.push_back(Point3D{-23421.612136159150, -11781.067532595984, 0.0000000000000000});
    points.push_back(Point3D{-22821.612136159150, -11781.067532595984, 0.0000000000000000});
    for (size_t i = 0; i < points.size(); i += 2) { cycle1(points[i], points[i + 1]); }

    /* ÒÔÏÂΪһ¸öÑ­»·£¬Í¹¶È×é¹Ì¶¨£¬µ«µã×é²»Ò»Ñù£¬ÆäËû²Ù×÷Ò»Ö */
    auto cycle2 = [&loader, tag1](const Point3D& point1, const Point3D point2, const Point3D point3, const Point3D point4) {
        /* Ñ­»·Ìå */
        const std::vector<Point3D> points   = {point1, point2, point3, point4};
        std::vector<double>        bulges   = {0.0000000000000000, 0.0000000000000000, 0.0000000000000000, 0.0000000000000000};
        Vector3D                   extusion = Vector3D{0.0000000000000000, 0.0000000000000000, 2850.0000000000000};
        auto                       cycleTag = loader.addExtrude(points, bulges, extusion);

        /* Ñ­»·Ìå ZÖáÆ«ÒÆ -2900 */
        Direction3D direction = Direction3D{0, 0, 1};
        double      offset    = -2900;
        loader.offset(cycleTag, direction, offset);

        /* Ìå1ºÍÑ­»·Ìå²¼¶û²î */
        loader.differentNode(tag1, cycleTag);
    };

    points.clear();
    bulges.clear();
    points.push_back(Point3D{-24963.009860716236, 7446.7650615308812, 0.0000000000000000});
    points.push_back(Point3D{-24459.052558350675, 7366.9792723925602, 0.0000000000000000});
    points.push_back(Point3D{-24388.685618648018, 7811.4435496937649, 0.0000000000000000});
    points.push_back(Point3D{-24833.149895949224, 7881.8104893964210, 0.0000000000000000});
    points.push_back(Point3D{24963.106150213611, 7446.7650615305229, 0.0000000000000000});
    points.push_back(Point3D{24459.148847848050, 7366.9792723922019, 0.0000000000000000});
    points.push_back(Point3D{24388.781908145393, 7811.4435496934066, 0.0000000000000000});
    points.push_back(Point3D{24833.246185446598, 7881.8104893960626, 0.0000000000000000});
    points.push_back(Point3D{6085.2898662776533, -18440.931060827090, 0.0000000000000000});
    points.push_back(Point3D{6530.7930936759531, -18213.935742862825, 0.0000000000000000});
    points.push_back(Point3D{6326.4973075081125, -17812.982838204356, 0.0000000000000000});
    points.push_back(Point3D{5880.9940801098128, -18039.978156168621, 0.0000000000000000});
    points.push_back(Point3D{9198.0021988374647, -24549.990396445304, 0.0000000000000000});
    points.push_back(Point3D{9643.5067429911614, -24322.997662776565, 0.0000000000000000});
    points.push_back(Point3D{9439.2132826892957, -23922.043573038238, 0.0000000000000000});
    points.push_back(Point3D{8993.7087385355990, -24149.036306706977, 0.0000000000000000});

    // before = loader.getAreaAndVolume(tag1);
    for (size_t i = 0; i < points.size(); i += 4) { cycle2(points[i], points[i + 1], points[i + 2], points[i + 3]); }
    // after = loader.getAreaAndVolume(tag1);

    /* »ñÈ¡Ìå1 ²¼¶ûÇ°ºóµÄÌå»ý²îºÍÃæ»ý²î */
    // areaDifference = after.first - before.first;
    // volumeDifference = after.second - before.second;
    // std::cout << areaDifference << ", " << volumeDifference << std::endl;

    //auto result = loader.getAreaAndVolume(tag1);
    //std::cout << "result:" << result.first << ", " << result.second << std::endl;

	loader.output();
}

int main(int argc, char** argv)
{
    loaderTest2();
    // loaderPolyTilted();
    // loaderPolyThickPlane();
    return 0;
}