Script: Shopify text 3d

Shopify text 3d picture
Type
Rete logo indicatorrete
Author
matas
Date Created
Jul 10, 2024, 5:47:06 PM
Last Edit Date
Jul 10, 2024, 5:50:16 PM

Project Information

This project contains demo scripts for Rete editor that are used as examples in the "Getting Started" section of the documentation.

View Full Project

Script Code

{
  "id": "rete-v2-json",
  "nodes": {
    "f67f8c01c549a695": {
      "id": "f67f8c01c549a695",
      "name": "bitbybit.advanced.text3d.create",
      "async": true,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "text": "bitbybit.dev + shopify.com",
        "fontType": "Roboto",
        "fontVariant": "Regular",
        "fontSize": 1.5,
        "height": 0.5,
        "rotation": 180,
        "origin": [
          0,
          0,
          0
        ],
        "direction": [
          0,
          1,
          0
        ],
        "originAlignment": "centerMiddle"
      },
      "inputs": {
        "origin": {
          "connections": [
            {
              "node": "e7df39c8f146fdaf",
              "output": "result",
              "data": {}
            }
          ]
        },
        "text": {
          "connections": [
            {
              "node": "a110775d7aa9121c",
              "output": "result",
              "data": {}
            }
          ]
        },
        "height": {
          "connections": [
            {
              "node": "0d5f661d4d739cf2",
              "output": "result",
              "data": {}
            }
          ]
        },
        "fontType": {
          "connections": [
            {
              "node": "96d818aece6a9d50",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        765.6369676148224,
        51.69113983022578
      ]
    },
    "42f5b7b8481a5ed9": {
      "id": "42f5b7b8481a5ed9",
      "name": "bitbybit.occt.shapes.wire.createRectangleWire",
      "async": true,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "width": 23,
        "length": 3,
        "center": [
          0,
          0,
          0
        ],
        "direction": [
          0,
          1,
          0
        ]
      },
      "inputs": {
        "center": {
          "connections": [
            {
              "node": "ac8e8b03912f1aaa",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        1015.2578125,
        632.22265625
      ]
    },
    "ac8e8b03912f1aaa": {
      "id": "ac8e8b03912f1aaa",
      "name": "bitbybit.vector.vectorXYZ",
      "async": false,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "x": 0,
        "y": 0,
        "z": -0.3
      },
      "inputs": {},
      "position": [
        611.3904900720239,
        810.3584842511211
      ]
    },
    "a47f31ebcec14863": {
      "id": "a47f31ebcec14863",
      "name": "bitbybit.occt.fillets.fillet2d",
      "async": true,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "radius": 0.5
      },
      "inputs": {
        "shape": {
          "connections": [
            {
              "node": "42f5b7b8481a5ed9",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        1374.1952481995884,
        648.609246399177
      ]
    },
    "185f2d72797f11fb": {
      "id": "185f2d72797f11fb",
      "name": "bitbybit.occt.shapes.face.createFaceFromWire",
      "async": true,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "planar": true
      },
      "inputs": {
        "shape": {
          "connections": [
            {
              "node": "a47f31ebcec14863",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        1869.0289574559004,
        674.378493195208
      ]
    },
    "460d91137d0323a2": {
      "id": "460d91137d0323a2",
      "name": "bitbybit.draw.drawAnyAsync",
      "async": true,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "options": {
          "connections": [
            {
              "node": "8c48c69fc882f42e",
              "output": "result",
              "data": {}
            }
          ]
        },
        "entity": {
          "connections": [
            {
              "node": "b9c6383746437f94",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        3668.5297284505837,
        987.5675248490475
      ]
    },
    "49bab1541d7b7a5b": {
      "id": "49bab1541d7b7a5b",
      "name": "bitbybit.babylon.scene.drawDirectionalLight",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "direction": [
          -100,
          -100,
          -100
        ],
        "intensity": 1,
        "diffuse": "#ffffff",
        "specular": "#ffffff",
        "shadowGeneratorMapSize": 2056,
        "enableShadows": true,
        "shadowDarkness": 0.3
      },
      "inputs": {},
      "position": [
        89.47921838416175,
        2279.8176060045625
      ]
    },
    "6148707144527816": {
      "id": "6148707144527816",
      "name": "bitbybit.draw.drawAnyAsync",
      "async": true,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "options": {
          "connections": [
            {
              "node": "5b9b11ee25eac7b3",
              "output": "result",
              "data": {}
            }
          ]
        },
        "entity": {
          "connections": [
            {
              "node": "4aeb3f8ea04b2309",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        3574.3320114147064,
        26.98652070164698
      ]
    },
    "5be569d81ce054da": {
      "id": "5be569d81ce054da",
      "name": "bitbybit.babylon.material.pbrMetallicRoughness.create",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "name": "Custom Material",
        "baseColor": "#ffffff",
        "emissiveColor": "#000000",
        "metallic": 0.2,
        "roughness": 0.8,
        "alpha": 1,
        "backFaceCulling": false,
        "zOffset": 1
      },
      "inputs": {
        "baseColor": {
          "connections": [
            {
              "node": "699b1e73f22e9fc1",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        2638.163868090751,
        296.38359338205237
      ]
    },
    "5b9b11ee25eac7b3": {
      "id": "5b9b11ee25eac7b3",
      "name": "bitbybit.draw.optionsOcctShapeMaterial",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "precision": 0.05,
        "drawEdges": true,
        "edgeColour": "#f0cebb",
        "edgeWidth": 1.5
      },
      "inputs": {
        "faceMaterial": {
          "connections": [
            {
              "node": "5be569d81ce054da",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        3020.961596434065,
        239.26131489116065
      ]
    },
    "4aeb3f8ea04b2309": {
      "id": "4aeb3f8ea04b2309",
      "name": "bitbybit.advanced.text3d.getCompoundShape",
      "async": false,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "model": {
          "connections": [
            {
              "node": "f67f8c01c549a695",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        1352.9691460984973,
        62.243038689673426
      ]
    },
    "916a82ee03e7552b": {
      "id": "916a82ee03e7552b",
      "name": "bitbybit.babylon.scene.drawDirectionalLight",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "direction": [
          -100,
          -100,
          -100
        ],
        "intensity": 3,
        "diffuse": "#ffffff",
        "specular": "#ffffff",
        "shadowGeneratorMapSize": 2056,
        "enableShadows": true,
        "shadowDarkness": 0
      },
      "inputs": {
        "direction": {
          "connections": [
            {
              "node": "3462604dff61d9cf",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        1442.2888402619672,
        1430.5225700282897
      ]
    },
    "3462604dff61d9cf": {
      "id": "3462604dff61d9cf",
      "name": "bitbybit.vector.vectorXYZ",
      "async": false,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "x": -15,
        "y": -10,
        "z": -10
      },
      "inputs": {},
      "position": [
        1056.3298268714798,
        1533.0678169740593
      ]
    },
    "8c48c69fc882f42e": {
      "id": "8c48c69fc882f42e",
      "name": "bitbybit.draw.optionsOcctShapeMaterial",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "precision": 0.05,
        "drawEdges": true,
        "edgeColour": "#f0cebb",
        "edgeWidth": 1.5
      },
      "inputs": {
        "faceMaterial": {
          "connections": [
            {
              "node": "142d8ec2b9845ea3",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        2994.3013679396067,
        1514.8174079045473
      ]
    },
    "142d8ec2b9845ea3": {
      "id": "142d8ec2b9845ea3",
      "name": "bitbybit.babylon.material.pbrMetallicRoughness.create",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "name": "Custom Material",
        "baseColor": "#f0cebb",
        "emissiveColor": "#000000",
        "metallic": 0.6,
        "roughness": 0.8,
        "alpha": 1,
        "backFaceCulling": false,
        "zOffset": 1
      },
      "inputs": {
        "baseColor": {
          "connections": [
            {
              "node": "699b1e73f22e9fc1",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        2551.4686696014014,
        1728.9782873385639
      ]
    },
    "e7df39c8f146fdaf": {
      "id": "e7df39c8f146fdaf",
      "name": "bitbybit.vector.vectorXYZ",
      "async": false,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "x": 0,
        "y": 0.01,
        "z": 0
      },
      "inputs": {},
      "position": [
        259.8741357983199,
        436.7966548297619
      ]
    },
    "3176c2d5a587e191": {
      "id": "3176c2d5a587e191",
      "name": "bitbybit.text.create",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "text": "We Love 3D!"
      },
      "inputs": {},
      "position": [
        -393.7632956287673,
        -196.29196998809803
      ]
    },
    "4ad95a55318f837e": {
      "id": "4ad95a55318f837e",
      "name": "bitbybit.runner.getRunnerInputValue",
      "data": {
        "property": "properties[Text 3D]"
      },
      "inputs": {},
      "position": [
        -551.1824687081382,
        -347.7689971723621
      ]
    },
    "a110775d7aa9121c": {
      "id": "a110775d7aa9121c",
      "name": "bitbybit.logic.firstDefinedValueGate",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "value1": {
          "connections": [
            {
              "node": "4ad95a55318f837e",
              "output": "result",
              "data": {}
            }
          ]
        },
        "value2": {
          "connections": [
            {
              "node": "3176c2d5a587e191",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        158.79703088870372,
        -154.57874211289987
      ]
    },
    "2e1bc831c418ccc6": {
      "id": "2e1bc831c418ccc6",
      "name": "bitbybit.math.number",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "number": 0.5
      },
      "inputs": {},
      "position": [
        -424.4711150582058,
        233.8569176053654
      ]
    },
    "28d5bcc9911991e2": {
      "id": "28d5bcc9911991e2",
      "name": "bitbybit.runner.getRunnerInputValue",
      "data": {
        "property": "properties[Text Height]"
      },
      "inputs": {},
      "position": [
        -548.7955399370704,
        99.69514102163816
      ]
    },
    "0d5f661d4d739cf2": {
      "id": "0d5f661d4d739cf2",
      "name": "bitbybit.logic.firstDefinedValueGate",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "value1": {
          "connections": [
            {
              "node": "28d5bcc9911991e2",
              "output": "result",
              "data": {}
            }
          ]
        },
        "value2": {
          "connections": [
            {
              "node": "2e1bc831c418ccc6",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        174.0282063769109,
        129.44924562352833
      ]
    },
    "b9c6383746437f94": {
      "id": "b9c6383746437f94",
      "name": "bitbybit.occt.operations.extrude",
      "async": true,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "direction": [
          0,
          1,
          0
        ]
      },
      "inputs": {
        "shape": {
          "connections": [
            {
              "node": "185f2d72797f11fb",
              "output": "result",
              "data": {}
            }
          ]
        },
        "direction": {
          "connections": [
            {
              "node": "c9d402ef8ffafcfe",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        3080.834700576882,
        805.3351499989922
      ]
    },
    "c9d402ef8ffafcfe": {
      "id": "c9d402ef8ffafcfe",
      "name": "bitbybit.vector.vectorXYZ",
      "async": false,
      "drawable": true,
      "data": {
        "genericNodeData": {
          "hide": true,
          "oneOnOne": false,
          "flatten": 0
        },
        "x": 0,
        "y": -1,
        "z": 0
      },
      "inputs": {
        "y": {
          "connections": [
            {
              "node": "dcb99e33752e59c2",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        2612.1283990122174,
        936.6249692030156
      ]
    },
    "1aeeb35ccaf39769": {
      "id": "1aeeb35ccaf39769",
      "name": "bitbybit.runner.getRunnerInputValue",
      "data": {
        "property": "properties[Base Height]"
      },
      "inputs": {},
      "position": [
        -825.2041602293295,
        933.8506869084349
      ]
    },
    "4e08a25dd7eaaf0b": {
      "id": "4e08a25dd7eaaf0b",
      "name": "bitbybit.math.number",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "number": 0.7
      },
      "inputs": {},
      "position": [
        -720.6045061109694,
        1130.9958644118383
      ]
    },
    "d8d798c5f420cc76": {
      "id": "d8d798c5f420cc76",
      "name": "bitbybit.logic.firstDefinedValueGate",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "value1": {
          "connections": [
            {
              "node": "1aeeb35ccaf39769",
              "output": "result",
              "data": {}
            }
          ]
        },
        "value2": {
          "connections": [
            {
              "node": "4e08a25dd7eaaf0b",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        -316.99698239726405,
        1033.6596076410217
      ]
    },
    "dcb99e33752e59c2": {
      "id": "dcb99e33752e59c2",
      "name": "bitbybit.math.oneNrOperation",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "number": 1,
        "operation": "negate"
      },
      "inputs": {
        "number": {
          "connections": [
            {
              "node": "d8d798c5f420cc76",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        202.94826703282672,
        1075.7876679070412
      ]
    },
    "aa650293170744ec": {
      "id": "aa650293170744ec",
      "name": "bitbybit.runner.setRunnerResultValue",
      "data": {
        "property": "meshes"
      },
      "inputs": {
        "value": {
          "connections": [
            {
              "node": "0e748ba08ef25bb3",
              "output": "list",
              "data": {}
            }
          ]
        }
      },
      "position": [
        4558.999642094764,
        479.7033546130833
      ]
    },
    "0e748ba08ef25bb3": {
      "id": "0e748ba08ef25bb3",
      "name": "bitbybit.lists.createList",
      "data": {},
      "inputs": {
        "listElements": {
          "connections": [
            {
              "node": "6148707144527816",
              "output": "result",
              "data": {}
            },
            {
              "node": "460d91137d0323a2",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        4190.326747239366,
        471.3175951458681
      ]
    },
    "2e01dd35d521b59c": {
      "id": "2e01dd35d521b59c",
      "name": "bitbybit.color.hexColor",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "color": "#000000"
      },
      "inputs": {},
      "position": [
        1607.0140809012648,
        2151.8820720280114
      ]
    },
    "142467017c28430c": {
      "id": "142467017c28430c",
      "name": "bitbybit.runner.getRunnerInputValue",
      "data": {
        "property": "properties[Color]"
      },
      "inputs": {},
      "position": [
        1461.460277535588,
        1999.8511049468452
      ]
    },
    "699b1e73f22e9fc1": {
      "id": "699b1e73f22e9fc1",
      "name": "bitbybit.logic.firstDefinedValueGate",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "value1": {
          "connections": [
            {
              "node": "142467017c28430c",
              "output": "result",
              "data": {}
            }
          ]
        },
        "value2": {
          "connections": [
            {
              "node": "2e01dd35d521b59c",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        1930.2768050452478,
        2019.6159784237263
      ]
    },
    "96d818aece6a9d50": {
      "id": "96d818aece6a9d50",
      "name": "bitbybit.logic.firstDefinedValueGate",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        }
      },
      "inputs": {
        "value1": {
          "connections": [
            {
              "node": "25b5e12093a986b5",
              "output": "result",
              "data": {}
            }
          ]
        },
        "value2": {
          "connections": [
            {
              "node": "c26705bac77004ea",
              "output": "result",
              "data": {}
            }
          ]
        }
      },
      "position": [
        87.91691673553828,
        -929.2180774041162
      ]
    },
    "c26705bac77004ea": {
      "id": "c26705bac77004ea",
      "name": "bitbybit.text.create",
      "async": false,
      "drawable": false,
      "data": {
        "genericNodeData": {
          "hide": false,
          "oneOnOne": false,
          "flatten": 0
        },
        "text": "Orbitron"
      },
      "inputs": {},
      "position": [
        -620.0505066396745,
        -890.9871599729952
      ]
    },
    "25b5e12093a986b5": {
      "id": "25b5e12093a986b5",
      "name": "bitbybit.runner.getRunnerInputValue",
      "data": {
        "property": "Font"
      },
      "inputs": {},
      "position": [
        -784.7014978055885,
        -1044.4867483116782
      ]
    }
  }
}