Wire Projection on 3D Shape

Wire Projection on 3D Shape script details
Author
matas
Type
Rete logo image
rete
App Version
0.13.0
Visibility
public
Date Created
Nov 15, 2023, 10:02:31 AM
Last Edit Date
Dec 5, 2023, 2:02:01 PM

Script Details

The Code
{ "id": "bitbybit-dev@0.0.1", "nodes": { "1": { "id": 1, "data": { "radius": 2, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "radius": { "connections": [ { "node": 9, "output": "result", "data": {} } ] }, "center": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 5, "input": "shape", "data": {} }, { "node": 11, "input": "shape", "data": {} } ] } }, "position": [ 119.34221257691112, 561.0553681983995 ], "name": "bitbybit.occt.shapes.solid.createSphere" }, "2": { "id": 2, "data": { "radius": 1.6, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "radius": { "connections": [ { "node": 10, "output": "result", "data": {} } ] }, "center": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 21, "input": "shape", "data": {} }, { "node": 23, "input": "shape", "data": {} } ] } }, "position": [ 123.57054286129306, 965.0547506220355 ], "name": "bitbybit.occt.shapes.solid.createSphere" }, "3": { "id": 3, "data": { "half": false, "numRays": 8, "outerRadius": 3.7, "innerRadius": 0.5, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "center": { "connections": [ { "node": 4, "output": "result", "data": {} } ] }, "direction": { "connections": [ { "node": 16, "output": "result", "data": {} } ] }, "numRays": { "connections": [] }, "outerRadius": { "connections": [] }, "innerRadius": { "connections": [] }, "half": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 7, "input": "shape", "data": {} } ] } }, "position": [ 484.64454024224, 180.5406697804233 ], "name": "bitbybit.occt.shapes.wire.createStarWire" }, "4": { "id": 4, "data": { "x": 5, "y": 0, "z": 0, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "x": { "connections": [] }, "y": { "connections": [] }, "z": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 3, "input": "center", "data": {} }, { "node": 19, "input": "center", "data": {} } ] } }, "position": [ 55.444548677462066, 23.18021565693465 ], "name": "bitbybit.vector.vectorXYZ" }, "5": { "id": 5, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "wire": { "connections": [ { "node": 7, "output": "result", "data": {} } ] }, "shape": { "connections": [ { "node": 1, "output": "result", "data": {} } ] }, "direction": { "connections": [ { "node": 16, "output": "result", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 12, "input": "listElements", "data": {} } ] } }, "position": [ 1240.4776624892613, 418.07126216264595 ], "name": "bitbybit.occt.shapes.wire.project" }, "7": { "id": 7, "data": { "radius": 0.1, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 3, "output": "result", "data": {} } ] }, "radius": { "connections": [] }, "radiusList": { "connections": [] }, "indexes": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 5, "input": "wire", "data": {} } ] } }, "position": [ 870.9053009951144, 229.43013926000432 ], "name": "bitbybit.occt.fillets.fillet2d" }, "8": { "id": 8, "data": { "number": 0.2519, "options": { "min": 0.1, "max": 1, "step": 0.0001, "width": 350 } }, "inputs": {}, "outputs": { "result": { "connections": [ { "node": 10, "input": "second", "data": {} }, { "node": 18, "input": "number", "data": {} } ] } }, "position": [ -848.5164712569745, 761.4251285755527 ], "name": "bitbybit.math.numberSlider" }, "9": { "id": 9, "data": { "number": 2 }, "inputs": { "number": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 1, "input": "radius", "data": {} }, { "node": 10, "input": "first", "data": {} } ] } }, "position": [ -397.4503942213751, 502.2628349088084 ], "name": "bitbybit.math.number" }, "10": { "id": 10, "data": { "first": 1, "second": 1, "operation": "subtract" }, "inputs": { "first": { "connections": [ { "node": 9, "output": "result", "data": {} } ] }, "second": { "connections": [ { "node": 8, "output": "result", "data": {} } ] }, "operation": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 2, "input": "radius", "data": {} } ] } }, "position": [ -249.02307693972574, 779.5951742757744 ], "name": "bitbybit.math.twoNrOperation" }, "11": { "id": 11, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 1, "output": "result", "data": {} } ] }, "shapes": { "connections": [ { "node": 12, "output": "list", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 13, "input": "shape", "data": {} } ] } }, "position": [ 1808.399079128558, 545.7569819947432 ], "name": "bitbybit.occt.operations.splitShapeWithShapes" }, "12": { "id": 12, "data": {}, "inputs": { "listElements": { "connections": [ { "node": 5, "output": "result", "data": {} } ] } }, "outputs": { "list": { "connections": [ { "node": 11, "input": "shapes", "data": {} } ] } }, "position": [ 1539.687582915636, 528.607110729851 ], "name": "createList" }, "13": { "id": 13, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 11, "output": "result", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 14, "input": "list", "data": {} } ] } }, "position": [ 2126.194049292414, 552.5948421447551 ], "name": "bitbybit.occt.shapes.face.getFaces" }, "14": { "id": 14, "data": { "index": 7 }, "inputs": { "list": { "connections": [ { "node": 13, "output": "result", "data": {} } ] }, "index": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 17, "input": "shape", "data": {} } ] } }, "position": [ 2439.568088717949, 615.973636969476 ], "name": "bitbybit.lists.getItem" }, "16": { "id": 16, "data": { "x": 1, "y": 0, "z": 0, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "x": { "connections": [] }, "y": { "connections": [] }, "z": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 3, "input": "direction", "data": {} }, { "node": 5, "input": "direction", "data": {} }, { "node": 19, "input": "direction", "data": {} }, { "node": 21, "input": "direction", "data": {} } ] } }, "position": [ 90.33133194605325, 348.4030770770338 ], "name": "bitbybit.vector.vectorXYZ" }, "17": { "id": 17, "data": { "offset": -0.3, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 14, "output": "result", "data": {} } ] }, "offset": { "connections": [ { "node": 18, "output": "result", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 31, "input": "listElements", "data": {} } ] } }, "position": [ 3635.4567696250397, 893.9932252222508 ], "name": "bitbybit.occt.operations.makeThickSolidSimple" }, "18": { "id": 18, "data": { "number": 1, "operation": "negate" }, "inputs": { "number": { "connections": [ { "node": 8, "output": "result", "data": {} } ] }, "operation": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 17, "input": "offset", "data": {} } ] } }, "position": [ 2527.0367561163885, 905.5728747818416 ], "name": "bitbybit.math.oneNrOperation" }, "19": { "id": 19, "data": { "half": false, "numRays": 8, "outerRadius": 3, "innerRadius": 1, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "center": { "connections": [ { "node": 4, "output": "result", "data": {} } ] }, "direction": { "connections": [ { "node": 16, "output": "result", "data": {} } ] }, "numRays": { "connections": [] }, "outerRadius": { "connections": [] }, "innerRadius": { "connections": [] }, "half": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 20, "input": "shape", "data": {} } ] } }, "position": [ 860.2070633473331, 1060.4580719625267 ], "name": "bitbybit.occt.shapes.wire.createStarWire" }, "20": { "id": 20, "data": { "radius": 0.1, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 19, "output": "result", "data": {} } ] }, "radius": { "connections": [] }, "radiusList": { "connections": [] }, "indexes": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 21, "input": "wire", "data": {} } ] } }, "position": [ 1365.9739808363615, 1074.6125738843714 ], "name": "bitbybit.occt.fillets.fillet2d" }, "21": { "id": 21, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "wire": { "connections": [ { "node": 20, "output": "result", "data": {} } ] }, "shape": { "connections": [ { "node": 2, "output": "result", "data": {} } ] }, "direction": { "connections": [ { "node": 16, "output": "result", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 22, "input": "listElements", "data": {} } ] } }, "position": [ 1735.974895943832, 1083.6978324800975 ], "name": "bitbybit.occt.shapes.wire.project" }, "22": { "id": 22, "data": {}, "inputs": { "listElements": { "connections": [ { "node": 21, "output": "result", "data": {} } ] } }, "outputs": { "list": { "connections": [ { "node": 23, "input": "shapes", "data": {} } ] } }, "position": [ 2148.545835114808, 1345.502721208489 ], "name": "createList" }, "23": { "id": 23, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 2, "output": "result", "data": {} } ] }, "shapes": { "connections": [ { "node": 22, "output": "list", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 26, "input": "shape", "data": {} } ] } }, "position": [ 2473.8502988344517, 1200.1390557265142 ], "name": "bitbybit.occt.operations.splitShapeWithShapes" }, "24": { "id": 24, "data": { "index": 7 }, "inputs": { "list": { "connections": [ { "node": 26, "output": "result", "data": {} } ] }, "index": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 25, "input": "shape", "data": {} } ] } }, "position": [ 3172.899778973188, 1197.8851323483807 ], "name": "bitbybit.lists.getItem" }, "25": { "id": 25, "data": { "offset": -0.2, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 24, "output": "result", "data": {} } ] }, "offset": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 31, "input": "listElements", "data": {} } ] } }, "position": [ 3617.1656638640247, 1171.3549593218222 ], "name": "bitbybit.occt.operations.makeThickSolidSimple" }, "26": { "id": 26, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shape": { "connections": [ { "node": 23, "output": "result", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 24, "input": "list", "data": {} } ] } }, "position": [ 2775.149573390515, 1320.4126374075586 ], "name": "bitbybit.occt.shapes.face.getFaces" }, "30": { "id": 30, "data": { "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "shapes": { "connections": [ { "node": 31, "output": "list", "data": {} } ] } }, "outputs": { "result": { "connections": [ { "node": 32, "input": "entity", "data": {} } ] } }, "position": [ 4285.831024006871, 1024.3035049237035 ], "name": "bitbybit.occt.shapes.compound.makeCompound" }, "31": { "id": 31, "data": {}, "inputs": { "listElements": { "connections": [ { "node": 17, "output": "result", "data": {} }, { "node": 25, "output": "result", "data": {} } ] } }, "outputs": { "list": { "connections": [ { "node": 30, "input": "shapes", "data": {} } ] } }, "position": [ 3938.1522129202644, 1039.3645163806952 ], "name": "createList" }, "32": { "id": 32, "data": {}, "inputs": { "entity": { "connections": [ { "node": 30, "output": "result", "data": {} } ] }, "options": { "connections": [ { "node": 33, "output": "result", "data": {} } ] }, "babylonMesh": { "connections": [] } }, "outputs": { "result": { "connections": [] } }, "position": [ 4725.280119799183, 897.8617527443034 ], "name": "bitbybit.draw.drawAnyAsync" }, "33": { "id": 33, "data": { "drawEdges": true, "drawFaces": true, "drawEdgeIndexes": false, "drawFaceIndexes": false, "faceOpacity": 1, "edgeOpacity": 1, "edgeColour": "#a28fff", "faceColour": "#3700ff", "edgeWidth": 0.5, "precision": 0.005, "edgeIndexHeight": 0.06, "edgeIndexColour": "ff00ff", "faceIndexHeight": 0.06, "faceIndexColour": "#0000ff" }, "inputs": { "faceOpacity": { "connections": [] }, "edgeOpacity": { "connections": [] }, "edgeColour": { "connections": [] }, "faceColour": { "connections": [] }, "faceMaterial": { "connections": [] }, "edgeWidth": { "connections": [] }, "drawEdges": { "connections": [] }, "drawFaces": { "connections": [] }, "precision": { "connections": [] }, "drawEdgeIndexes": { "connections": [] }, "edgeIndexHeight": { "connections": [] }, "edgeIndexColour": { "connections": [] }, "drawFaceIndexes": { "connections": [] }, "faceIndexHeight": { "connections": [] }, "faceIndexColour": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 32, "input": "options", "data": {} } ] } }, "position": [ 4224.041345507986, 1330.2541134383978 ], "name": "bitbybit.draw.optionsOcctShape" }, "35": { "id": 35, "data": { "enableShadows": true, "intensity": 1000, "diffuse": "#ffffff", "specular": "#ffffff", "radius": 0.1, "shadowGeneratorMapSize": 2056, "shadowDarkness": 0 }, "inputs": { "position": { "connections": [ { "node": 36, "output": "result", "data": {} } ] }, "intensity": { "connections": [] }, "diffuse": { "connections": [] }, "specular": { "connections": [] }, "radius": { "connections": [] }, "shadowGeneratorMapSize": { "connections": [] }, "enableShadows": { "connections": [] }, "shadowDarkness": { "connections": [] } }, "outputs": { "result": { "connections": [] } }, "position": [ 1819.1869736293306, 2418.556795416953 ], "name": "bitbybit.babylon.scene.drawPointLight" }, "36": { "id": 36, "data": { "x": -3, "y": 3, "z": 0, "genericNodeData": { "hide": true, "oneOnOne": false, "flatten": 0 } }, "inputs": { "x": { "connections": [] }, "y": { "connections": [] }, "z": { "connections": [] } }, "outputs": { "result": { "connections": [ { "node": 35, "input": "position", "data": {} } ] } }, "position": [ 1347.759710541683, 2423.4696563878188 ], "name": "bitbybit.vector.vectorXYZ" } } }