diff options
| author | s-ol <s+removethis@s-ol.nu> | 2020-12-03 16:38:43 +0000 |
|---|---|---|
| committer | s-ol <s+removethis@s-ol.nu> | 2020-12-03 16:38:43 +0000 |
| commit | e0a0b25f6586cdf1b1284d97bedadfce5535ba96 (patch) | |
| tree | 50cf646dc673faeda648e7135d84e46f2dbd5262 /root/$mmm/plugins/gltf | |
| parent | fix typo break text/html+interactive (diff) | |
| download | mmm-e0a0b25f6586cdf1b1284d97bedadfce5535ba96.tar.gz mmm-e0a0b25f6586cdf1b1284d97bedadfce5535ba96.zip | |
move plugins into root
Diffstat (limited to 'root/$mmm/plugins/gltf')
| -rw-r--r-- | root/$mmm/plugins/gltf/converts: text$moonscript -> table.moon | 16 | ||||
| -rw-r--r-- | root/$mmm/plugins/gltf/scripts: text$html+frag.html | 2 |
2 files changed, 18 insertions, 0 deletions
diff --git a/root/$mmm/plugins/gltf/converts: text$moonscript -> table.moon b/root/$mmm/plugins/gltf/converts: text$moonscript -> table.moon new file mode 100644 index 0000000..1036eee --- /dev/null +++ b/root/$mmm/plugins/gltf/converts: text$moonscript -> table.moon @@ -0,0 +1,16 @@ +dom = require 'mmm.dom' + +{ + { + inp: 'URL -> model/gltf-binary' + out: 'mmm/dom' + cost: 1 + transform: (href) => + dom['model-viewer'] { + src: href + 'auto-rotate': true + 'camera-controls': true + 'camera-orbit': "548.2deg 117deg 282.4m" + } + } +} diff --git a/root/$mmm/plugins/gltf/scripts: text$html+frag.html b/root/$mmm/plugins/gltf/scripts: text$html+frag.html new file mode 100644 index 0000000..d2b1e44 --- /dev/null +++ b/root/$mmm/plugins/gltf/scripts: text$html+frag.html @@ -0,0 +1,2 @@ + <script type="module" src="https://unpkg.com/@google/model-viewer/dist/model-viewer.min.js"></script> + <script nomodule src="https://unpkg.com/@google/model-viewer/dist/model-viewer-legacy.js"></script> |
