Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

polyhedron defined by points and faces not working #1

Open
seainside75 opened this issue Jul 15, 2018 · 1 comment
Open

polyhedron defined by points and faces not working #1

seainside75 opened this issue Jul 15, 2018 · 1 comment

Comments

@seainside75
Copy link

seainside75 commented Jul 15, 2018

Hello,
first of all very interesting project!

As per subject, I'm trying the following scad script to be translated via cli

CENTRALIA_01_POINTS = [[6994626.97510511,911483.635884457,24000],[7088385.66303069,933842.896559343,24000],[7106249.74762991,935033.098611347,24000],[7130013.92417585,932663.350497916,24000],[7142293.64918297,931460.638632276,24000],[7200616.14425414,973383.803289837,24000],[7226948.96064999,955749.226928979,24000],[7245297.22469535,943566.763897411,24000],[7281415.31622307,937710.354332817,24000],[7277078.77660679,934375.338958078,24000],[7281204.38870412,914653.567137333,24000],[7264277.97341955,883733.450954237,24000],[7267163.15789245,855461.881181287,24000],[7245139.6998175,846161.618667563,24000],[7234817.95894898,841848.971427513,24000],[7204918.20850207,829895.114443186,24000],[7160634.70602899,818326.522400688,24000],[7119066.68997856,807592.381152567,24000],[7113659.49456358,805783.297182381,24000],[7092812.96550123,798738.862747264,24000],[7041149.95989923,797984.082042617,24000],[7028892.49970086,798458.260311742,24000],[7003427.55162139,797319.017185253,24000],[6991888.82041143,797119.055675698,24000],[6986970.11484296,796865.001906718,24000],[6986754.32450122,801484.579793145,24000],[6990753.28479667,807054.168402527,24000],[6988749.36562373,813359.823641005,24000],[6991738.88509065,827880.64040549,24000],[6993356.53265578,835815.743126298,24000],[7003351.14649329,883446.562910407,24000],[6994626.97510511,911483.635884457,32999],[7003351.14649329,883446.562910407,32999],[6993356.53265578,835815.743126298,32999],[6991738.88509065,827880.64040549,32999],[6988749.36562373,813359.823641005,32999],[6990753.28479667,807054.168402527,32999],[6986754.32450122,801484.579793145,32999],[6986970.11484296,796865.001906718,32999],[6991888.82041143,797119.055675698,32999],[7003427.55162139,797319.017185253,32999],[7028892.49970086,798458.260311742,32999],[7041149.95989923,797984.082042617,32999],[7092812.96550123,798738.862747264,32999],[7113659.49456358,805783.297182381,32999],[7119066.68997856,807592.381152567,32999],[7160634.70602899,818326.522400688,32999],[7204918.20850207,829895.114443186,32999],[7234817.95894898,841848.971427513,32999],[7245139.6998175,846161.618667563,32999],[7267163.15789245,855461.881181287,32999],[7264277.97341955,883733.450954237,32999],[7281204.38870412,914653.567137333,32999],[7277078.77660679,934375.338958078,32999],[7281415.31622307,937710.354332817,32999],[7245297.22469535,943566.763897411,32999],[7226948.96064999,955749.226928979,32999],[7200616.14425414,973383.803289837,32999],[7142293.64918297,931460.638632276,32999],[7130013.92417585,932663.350497916,32999],[7106249.74762991,935033.098611347,32999],[7088385.66303069,933842.896559343,32999],[6994626.97510511,911483.635884457,24000],[6994626.97510511,911483.635884457,32999],[7088385.66303069,933842.896559343,32999],[7088385.66303069,933842.896559343,24000],[7088385.66303069,933842.896559343,24000],[7088385.66303069,933842.896559343,32999],[7106249.74762991,935033.098611347,32999],[7106249.74762991,935033.098611347,24000],[7106249.74762991,935033.098611347,24000],[7106249.74762991,935033.098611347,32999],[7130013.92417585,932663.350497916,32999],[7130013.92417585,932663.350497916,24000],[7130013.92417585,932663.350497916,24000],[7130013.92417585,932663.350497916,32999],[7142293.64918297,931460.638632276,32999],[7142293.64918297,931460.638632276,24000],[7142293.64918297,931460.638632276,24000],[7142293.64918297,931460.638632276,32999],[7200616.14425414,973383.803289837,32999],[7200616.14425414,973383.803289837,24000],[7200616.14425414,973383.803289837,24000],[7200616.14425414,973383.803289837,32999],[7226948.96064999,955749.226928979,32999],[7226948.96064999,955749.226928979,24000],[7226948.96064999,955749.226928979,24000],[7226948.96064999,955749.226928979,32999],[7245297.22469535,943566.763897411,32999],[7245297.22469535,943566.763897411,24000],[7245297.22469535,943566.763897411,24000],[7245297.22469535,943566.763897411,32999],[7281415.31622307,937710.354332817,32999],[7281415.31622307,937710.354332817,24000],[7281415.31622307,937710.354332817,24000],[7281415.31622307,937710.354332817,32999],[7277078.77660679,934375.338958078,32999],[7277078.77660679,934375.338958078,24000],[7277078.77660679,934375.338958078,24000],[7277078.77660679,934375.338958078,32999],[7281204.38870412,914653.567137333,32999],[7281204.38870412,914653.567137333,24000],[7281204.38870412,914653.567137333,24000],[7281204.38870412,914653.567137333,32999],[7264277.97341955,883733.450954237,32999],[7264277.97341955,883733.450954237,24000],[7264277.97341955,883733.450954237,24000],[7264277.97341955,883733.450954237,32999],[7267163.15789245,855461.881181287,32999],[7267163.15789245,855461.881181287,24000],[7267163.15789245,855461.881181287,24000],[7267163.15789245,855461.881181287,32999],[7245139.6998175,846161.618667563,32999],[7245139.6998175,846161.618667563,24000],[7245139.6998175,846161.618667563,24000],[7245139.6998175,846161.618667563,32999],[7234817.95894898,841848.971427513,32999],[7234817.95894898,841848.971427513,24000],[7234817.95894898,841848.971427513,24000],[7234817.95894898,841848.971427513,32999],[7204918.20850207,829895.114443186,32999],[7204918.20850207,829895.114443186,24000],[7204918.20850207,829895.114443186,24000],[7204918.20850207,829895.114443186,32999],[7160634.70602899,818326.522400688,32999],[7160634.70602899,818326.522400688,24000],[7160634.70602899,818326.522400688,24000],[7160634.70602899,818326.522400688,32999],[7119066.68997856,807592.381152567,32999],[7119066.68997856,807592.381152567,24000],[7119066.68997856,807592.381152567,24000],[7119066.68997856,807592.381152567,32999],[7113659.49456358,805783.297182381,32999],[7113659.49456358,805783.297182381,24000],[7113659.49456358,805783.297182381,24000],[7113659.49456358,805783.297182381,32999],[7092812.96550123,798738.862747264,32999],[7092812.96550123,798738.862747264,24000],[7092812.96550123,798738.862747264,24000],[7092812.96550123,798738.862747264,32999],[7041149.95989923,797984.082042617,32999],[7041149.95989923,797984.082042617,24000],[7041149.95989923,797984.082042617,24000],[7041149.95989923,797984.082042617,32999],[7028892.49970086,798458.260311742,32999],[7028892.49970086,798458.260311742,24000],[7028892.49970086,798458.260311742,24000],[7028892.49970086,798458.260311742,32999],[7003427.55162139,797319.017185253,32999],[7003427.55162139,797319.017185253,24000],[7003427.55162139,797319.017185253,24000],[7003427.55162139,797319.017185253,32999],[6991888.82041143,797119.055675698,32999],[6991888.82041143,797119.055675698,24000],[6991888.82041143,797119.055675698,24000],[6991888.82041143,797119.055675698,32999],[6986970.11484296,796865.001906718,32999],[6986970.11484296,796865.001906718,24000],[6986970.11484296,796865.001906718,24000],[6986970.11484296,796865.001906718,32999],[6986754.32450122,801484.579793145,32999],[6986754.32450122,801484.579793145,24000],[6986754.32450122,801484.579793145,24000],[6986754.32450122,801484.579793145,32999],[6990753.28479667,807054.168402527,32999],[6990753.28479667,807054.168402527,24000],[6990753.28479667,807054.168402527,24000],[6990753.28479667,807054.168402527,32999],[6988749.36562373,813359.823641005,32999],[6988749.36562373,813359.823641005,24000],[6988749.36562373,813359.823641005,24000],[6988749.36562373,813359.823641005,32999],[6991738.88509065,827880.64040549,32999],[6991738.88509065,827880.64040549,24000],[6991738.88509065,827880.64040549,24000],[6991738.88509065,827880.64040549,32999],[6993356.53265578,835815.743126298,32999],[6993356.53265578,835815.743126298,24000],[6993356.53265578,835815.743126298,24000],[6993356.53265578,835815.743126298,32999],[7003351.14649329,883446.562910407,32999],[7003351.14649329,883446.562910407,24000],[7003351.14649329,883446.562910407,24000],[7003351.14649329,883446.562910407,32999],[6994626.97510511,911483.635884457,32999],[6994626.97510511,911483.635884457,24000]]; CENTRALIA_02_POINTS = [[7106249.74762991,935033.098611347,28000],[7198433.03396668,988719.744254437,28000],[7198110.52107499,986527.50027001,28000],[7196575.38422485,976092.664426532,28000],[7200616.14425414,973383.803289837,28000],[7142293.64918297,931460.638632276,28000],[7130013.92417585,932663.350497916,28000],[7106249.74762991,935033.098611347,32999],[7130013.92417585,932663.350497916,32999],[7142293.64918297,931460.638632276,32999],[7200616.14425414,973383.803289837,32999],[7196575.38422485,976092.664426532,32999],[7198110.52107499,986527.50027001,32999],[7198433.03396668,988719.744254437,32999],[7106249.74762991,935033.098611347,28000],[7106249.74762991,935033.098611347,32999],[7198433.03396668,988719.744254437,32999],[7198433.03396668,988719.744254437,28000],[7198433.03396668,988719.744254437,28000],[7198433.03396668,988719.744254437,32999],[7198110.52107499,986527.50027001,32999],[7198110.52107499,986527.50027001,28000],[7198110.52107499,986527.50027001,28000],[7198110.52107499,986527.50027001,32999],[7196575.38422485,976092.664426532,32999],[7196575.38422485,976092.664426532,28000],[7196575.38422485,976092.664426532,28000],[7196575.38422485,976092.664426532,32999],[7200616.14425414,973383.803289837,32999],[7200616.14425414,973383.803289837,28000],[7200616.14425414,973383.803289837,28000],[7200616.14425414,973383.803289837,32999],[7142293.64918297,931460.638632276,32999],[7142293.64918297,931460.638632276,28000],[7142293.64918297,931460.638632276,28000],[7142293.64918297,931460.638632276,32999],[7130013.92417585,932663.350497916,32999],[7130013.92417585,932663.350497916,28000],[7130013.92417585,932663.350497916,28000],[7130013.92417585,932663.350497916,32999],[7106249.74762991,935033.098611347,32999],[7106249.74762991,935033.098611347,28000]];CENTRALIA_02_FACES = [[ 0, 1, 2, 3, 4, 5, 6],[ 7, 8, 9, 10, 11, 12, 13],[ 14, 15, 16, 17],[ 18, 19, 20, 21],[ 22, 23, 24, 25],[ 26, 27, 28, 29],[ 30, 31, 32, 33],[ 34, 35, 36, 37],[ 38, 39, 40, 41]];polyhedron (CENTRALIA_02_POINTS,CENTRALIA_02_FACES);
CENTRALIA_01_FACES = [[ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30],[ 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61],[ 62, 63, 64, 65],[ 66, 67, 68, 69],[ 70, 71, 72, 73],[ 74, 75, 76, 77],[ 78, 79, 80, 81],[ 82, 83, 84, 85],[ 86, 87, 88, 89],[ 90, 91, 92, 93],[ 94, 95, 96, 97],[ 98, 99, 100, 101],[ 102, 103, 104, 105],[ 106, 107, 108, 109],[ 110, 111, 112, 113],[ 114, 115, 116, 117],[ 118, 119, 120, 121],[ 122, 123, 124, 125],[ 126, 127, 128, 129],[ 130, 131, 132, 133],[ 134, 135, 136, 137],[ 138, 139, 140, 141],[ 142, 143, 144, 145],[ 146, 147, 148, 149],[ 150, 151, 152, 153],[ 154, 155, 156, 157],[ 158, 159, 160, 161],[ 162, 163, 164, 165],[ 166, 167, 168, 169],[ 170, 171, 172, 173],[ 174, 175, 176, 177],[ 178, 179, 180, 181],[ 182, 183, 184, 185]];
polyhedron (CENTRALIA_01_POINTS,CENTRALIA_01_FACES);

but cadmelia-cli returns the following error:

Jul 15, 2018 2:42:12 AM net.nowina.cadmelia.script.CommandInterpreter execute
INFO: New command Command{name='polyhedron', parameters=[points=net.nowina.cadmelia.script.ListIterableDef@27fa135a, triangles=net.nowina.cadmelia.script.ListIterableDef@46f7f36a]}
Jul 15, 2018 2:42:12 AM net.nowina.cadmelia.script.module.CompositionModule operation
INFO: Execute operation Command{name='polyhedron', parameters=[points=net.nowina.cadmelia.script.ListIterableDef@27fa135a, triangles=net.nowina.cadmelia.script.ListIterableDef@46f7f36a]}
Jul 15, 2018 2:42:12 AM net.nowina.cadmelia.script.module.CompositionModule operation
INFO: Result null
Exception in thread "main" java.lang.NullPointerException
at net.nowina.cadmelia.stl.STLWriter.write(STLWriter.java:64)
at net.nowina.cadmelia.CompileToSTLApp.render(CompileToSTLApp.java:68)
at net.nowina.cadmelia.CompileToSTLApp.render(CompileToSTLApp.java:52)
at net.nowina.cadmelia.CompileToSTLApp.main(CompileToSTLApp.java:45)

Thanks in advance

@naramski
Copy link
Owner

Thanks for your feedback. I'll look to this ASAP.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants