Skip to content

Instantly share code, notes, and snippets.

@jonathanhudak
Last active March 4, 2023 07:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonathanhudak/bc5c6697a30f413643c8529875037123 to your computer and use it in GitHub Desktop.
Save jonathanhudak/bc5c6697a30f413643c8529875037123 to your computer and use it in GitHub Desktop.
{
"lume3d": [{
"type": "script",
"attributes": {
"src": "https://unpkg.com/lume@0.3.0-alpha.9/dist/global.js"
}
},
{
"type": "script",
"attributes": {
"type": "module"
},
"value": "LUME.defineElements()"
},
{
"type": "html",
"value": "<div id=\"lume-scene\"><lume-scene webgl>\r\n <lume-ambient-light intensity=\"0.5\"><\/lume-ambient-light>\r\n <lume-point-light color=\"white\" align-point=\"0.5 0.5\" position=\"0 0 300\" size=\"0 0 0\" cast-shadow=\"true\" intensity=\"0.65\">\r\n <\/lume-point-light>\r\n\r\n <lume-box id=\"box\" size=\"100 100 100\" align-point=\"0.5 0.5 0.5\" mount-point=\"0.5 0.5 0.5\"> <\/lume-box>\r\n<\/lume-scene></div>"
},
{
"type": "script",
"attributes": {
"type": "module"
},
"value": "box.rotation = (x, y, z) => [x, y + 1, z]"
},
{
"type": "style",
"value": "#lume-scene { width: 500px; height: 500px; background: #62b997; position: relative; }"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment