| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,12 @@ | |||
| import {_testFinish, downloadBlob, IObject3D, LoadingScreenPlugin, Rhino3dmLoadPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| downloadBlob, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| Rhino3dmLoadPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| const viewer = new ThreeViewer({ | |||
| canvas: document.getElementById('mcanvas') as HTMLCanvasElement, | |||
| @@ -47,4 +55,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -0,0 +1,38 @@ | |||
| <!DOCTYPE html> | |||
| <html lang="en"> | |||
| <head> | |||
| <meta charset="UTF-8"> | |||
| <title>Advanced Ground Plugin</title> | |||
| <meta name="viewport" content="width=device-width, initial-scale=1"> | |||
| <!-- Import maps polyfill --> | |||
| <!-- Remove this when import maps will be widely supported --> | |||
| <script async src="https://unpkg.com/es-module-shims@1.6.3/dist/es-module-shims.js"></script> | |||
| <script type="importmap"> | |||
| { | |||
| "imports": { | |||
| "@threepipe/webgi-plugins": "https://unpkg.com/@threepipe/webgi-plugins@0.5.0/dist/index.mjs", | |||
| "threepipe": "./../../dist/index.mjs", | |||
| "@threepipe/plugin-tweakpane": "./../../plugins/tweakpane/dist/index.mjs" | |||
| } | |||
| } | |||
| </script> | |||
| <style id="example-style"> | |||
| html, body, #canvas-container, #mcanvas { | |||
| width: 100%; | |||
| height: 100%; | |||
| margin: 0; | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| <body> | |||
| <div id="canvas-container"> | |||
| <canvas id="mcanvas"></canvas> | |||
| </div> | |||
| </body> | |||
| @@ -0,0 +1,55 @@ | |||
| import { | |||
| _testFinish, _testStart, | |||
| GBufferPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| PCFSoftShadowMap, | |||
| RenderTargetPreviewPlugin, | |||
| SSAAPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| // @ts-expect-error todo fix import | |||
| import {AdvancedGroundPlugin, SSReflectionPlugin, TemporalAAPlugin} from '@threepipe/webgi-plugins' | |||
| async function init() { | |||
| const viewer = new ThreeViewer({ | |||
| canvas: document.getElementById('mcanvas') as HTMLCanvasElement, | |||
| msaa: true, | |||
| rgbm: true, | |||
| dropzone: { | |||
| addOptions: { | |||
| disposeSceneObjects: true, | |||
| }, | |||
| }, | |||
| plugins: [LoadingScreenPlugin, GBufferPlugin, SSAAPlugin, TemporalAAPlugin], | |||
| // rgbm: false, | |||
| }) | |||
| viewer.renderManager.stableNoise = true | |||
| const ground = viewer.addPluginSync(AdvancedGroundPlugin) | |||
| ground.planarReflections = true | |||
| const ui = viewer.addPluginSync(new TweakpaneUiPlugin(true)) | |||
| await viewer.setEnvironmentMap('https://threejs.org/examples/textures/equirectangular/venice_sunset_1k.hdr', { | |||
| setBackground: false, | |||
| }) | |||
| await viewer.load<IObject3D>('https://threejs.org/examples/models/gltf/DamagedHelmet/glTF/DamagedHelmet.gltf', { | |||
| autoCenter: true, | |||
| autoScale: true, | |||
| }) | |||
| ui.setupPluginUi(AdvancedGroundPlugin) | |||
| viewer.renderManager.renderer.shadowMap.type = PCFSoftShadowMap | |||
| const rt = viewer.addPluginSync(RenderTargetPreviewPlugin) | |||
| rt.addTarget(()=>ground.shadowBaker?.light.shadow.map, 'shadow', false, false, true, (s)=>s + ' = vec4(' + s + '.r/2.);') | |||
| rt.addTarget(()=>ground.shadowBaker?.target, 'baked shadow', false, false, true) | |||
| } | |||
| _testStart() | |||
| init().then(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| AmbientLight2, | |||
| Box3B, | |||
| IObject3D, | |||
| @@ -50,4 +50,5 @@ async function init() { | |||
| ui.appendChild(light.uiConfig, {expanded: true}) | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -26,6 +26,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,12 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, PickingPlugin, SSAAPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| PickingPlugin, | |||
| SSAAPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| // @ts-expect-error todo fix | |||
| import {AnisotropyPlugin, BloomPlugin, OutlinePlugin, SSContactShadowsPlugin, TemporalAAPlugin} from '@threepipe/webgi-plugins' | |||
| @@ -45,4 +53,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().then(_testFinish) | |||
| @@ -26,6 +26,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| AssetExporterPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| @@ -37,4 +37,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -26,6 +26,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| AssetExporterPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| @@ -56,4 +56,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,9 +25,10 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module"> | |||
| import {_testFinish, LoadingScreenPlugin, ThreeViewer, Vector3} from 'threepipe' | |||
| import {_testFinish, _testStart, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {B3DMLoadPlugin} from '@threepipe/plugin-3d-tiles-renderer' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas')}) | |||
| @@ -58,6 +59,7 @@ | |||
| result2.setDirty() | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| </script> | |||
| </head> | |||
| @@ -27,6 +27,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, DirectionalLight2, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, DirectionalLight2, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| import {BasicSVGRendererPlugin} from '@threepipe/plugin-svg-renderer' | |||
| @@ -38,4 +38,5 @@ async function init() { | |||
| ui.appendChild(l.uiConfig) | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,9 +25,10 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module"> | |||
| import {_testFinish, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {BlendLoadPlugin} from '@threepipe/plugin-blend-importer' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas')}) | |||
| @@ -43,6 +44,7 @@ | |||
| console.log(result) | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| </script> | |||
| </head> | |||
| @@ -26,6 +26,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,12 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, PhysicalMaterial, SSAAPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| PhysicalMaterial, | |||
| SSAAPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| // @ts-expect-error todo fix | |||
| import {BloomPlugin, TemporalAAPlugin} from '@threepipe/webgi-plugins' | |||
| @@ -47,4 +55,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().then(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, ThreeViewer, TonemapPlugin} from 'threepipe' | |||
| import {_testFinish, _testStart, IObject3D, LoadingScreenPlugin, ThreeViewer, TonemapPlugin} from 'threepipe' | |||
| import {BlueprintJsUiPlugin} from '@threepipe/plugin-blueprintjs' | |||
| async function init() { | |||
| @@ -23,4 +23,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -25,4 +25,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -22,4 +22,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| CameraView, | |||
| CameraViewPlugin, | |||
| EasingFunctions, | |||
| @@ -84,4 +84,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| CanvasSnapshotPlugin, | |||
| isWebpExportSupported, | |||
| LoadingScreenPlugin, | |||
| @@ -98,4 +98,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,11 @@ | |||
| import {_testFinish, ChromaticAberrationPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| ChromaticAberrationPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -19,4 +26,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| ClearcoatTintPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| @@ -49,4 +49,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,9 +25,10 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module"> | |||
| import {_testFinish, LoadingScreenPlugin, ThreeViewer, Vector3, Box3B} from 'threepipe' | |||
| import {_testFinish, _testStart, LoadingScreenPlugin, ThreeViewer, Vector3, Box3B} from 'threepipe' | |||
| import {CMPTLoadPlugin} from '@threepipe/plugin-3d-tiles-renderer' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas')}) | |||
| @@ -54,6 +55,7 @@ | |||
| console.log(new Box3B(result2).getCenter(new Vector3())) // todo why is this is NaN? | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| </script> | |||
| </head> | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,11 @@ | |||
| import {_testFinish, ContactShadowGroundPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| ContactShadowGroundPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -21,4 +28,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| CustomBumpMapPlugin, | |||
| ITexture, | |||
| LoadingScreenPlugin, | |||
| @@ -48,4 +48,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| DepthBufferPlugin, | |||
| downloadBlob, | |||
| HalfFloatType, | |||
| @@ -59,4 +59,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| DepthBufferPlugin, | |||
| downloadBlob, | |||
| HalfFloatType, | |||
| @@ -60,4 +60,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -26,6 +26,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| PhysicalMaterial, | |||
| @@ -49,4 +49,5 @@ async function init() { | |||
| viewer.scene.mainCamera.setDirty() | |||
| } | |||
| _testStart() | |||
| init().then(_testFinish) | |||
| @@ -31,6 +31,7 @@ | |||
| backdrop-filter: blur(16px); | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,11 @@ | |||
| import {_testFinish, DeviceOrientationControlsPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| DeviceOrientationControlsPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -27,4 +34,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| Box3B, | |||
| DirectionalLight2, | |||
| IObject3D, | |||
| @@ -66,4 +66,5 @@ async function init() { | |||
| ui.appendChild(light.uiConfig, {expanded: true}) | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,9 +24,10 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module"> | |||
| import {_testFinish, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, ThreeViewer} from 'threepipe' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas')}) | |||
| @@ -40,6 +41,7 @@ | |||
| console.log(result) | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| </script> | |||
| </head> | |||
| @@ -35,6 +35,7 @@ | |||
| pointer-events: none; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| DropzonePlugin, | |||
| LoadingScreenPlugin, | |||
| PickingPlugin, | |||
| @@ -45,4 +45,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,12 @@ | |||
| import {_testFinish, EditorViewWidgetPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer, timeout} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| EditorViewWidgetPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| ThreeViewer, | |||
| timeout, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -33,4 +41,5 @@ async function init() { | |||
| plugin.setOrientation('+z') | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -0,0 +1,29 @@ | |||
| function run () { | |||
| if (document.body.classList.contains('_testStarted')) return | |||
| const div = document.createElement('div'); | |||
| const colorScheme = window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light'; | |||
| Object.assign(div.style, { | |||
| position: 'fixed', top: 0, left: 0, bottom: 0, right: 0, width: 'auto', height: 'max-content', | |||
| display: 'flex', alignItems: 'center', justifyContent: 'center', flexDirection: 'column', | |||
| background: 'transparent', pointerEvents: 'none', | |||
| zIndex: '49', // loading screen is 50 | |||
| transition: 'opacity 0.5s ease', | |||
| color: colorScheme !== 'dark' ? '#eee' : '#222', | |||
| fontSize: '1.25rem', | |||
| margin: 'auto', | |||
| }); | |||
| div.innerHTML = '<div style="width:32px;height:32px;border:4px solid #ccc;border-top:4px solid #333;border-radius:50%;animation:spin 1s linear infinite;margin:auto"></div><div style="text-align:center;margin-top:8px;font-family:sans-serif">Loading...</div><style>@keyframes spin{100%{transform:rotate(360deg)}}</style>'; | |||
| document.body.appendChild(div); | |||
| let removed = false | |||
| function remove () { | |||
| if (removed) return | |||
| removed = true | |||
| div.style.opacity = '0'; | |||
| setTimeout(() => div.remove(), 600); | |||
| } | |||
| window.addEventListener('threepipe-test-started', remove) | |||
| setTimeout(remove, 8000); // remove after 5 seconds if not removed | |||
| } | |||
| run() | |||
| @@ -24,9 +24,11 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module"> | |||
| import {_testFinish, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, ThreeViewer} from 'threepipe' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas')}) | |||
| @@ -37,6 +39,7 @@ | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| </script> | |||
| </head> | |||
| @@ -36,6 +36,7 @@ | |||
| pointer-events: none; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| GLTFAnimationPlugin, | |||
| HemisphereLight, | |||
| ImportAddOptions, | |||
| @@ -62,24 +62,24 @@ async function init() { | |||
| viewer.scene.setBackgroundColor('#555555') | |||
| viewer.scene.addObject(new HemisphereLight(0xffffff, 0x444444, 2)) | |||
| await viewer.setEnvironmentMap('https://threejs.org/examples/textures/equirectangular/venice_sunset_1k.hdr') | |||
| await viewer.setEnvironmentMap('https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/textures/equirectangular/venice_sunset_1k.hdr') | |||
| const urls = [ | |||
| 'https://threejs.org/examples/models/3ds/portalgun/portalgun.3ds', | |||
| 'https://threejs.org/examples/models/3mf/cube_gears.3mf', | |||
| 'https://threejs.org/examples/models/collada/elf/elf.dae', | |||
| 'https://threejs.org/examples/models/amf/rook.amf', | |||
| 'https://threejs.org/examples/models/gcode/benchy.gcode', | |||
| 'https://threejs.org/examples/models/bvh/pirouette.bvh', | |||
| 'https://threejs.org/examples/models/vox/monu10.vox', | |||
| 'https://threejs.org/examples/models/mdd/cube.mdd', | |||
| 'https://threejs.org/examples/models/pcd/binary/Zaghetto.pcd', | |||
| 'https://threejs.org/examples/models/tilt/BRUSH_DOME.tilt', | |||
| 'https://threejs.org/examples/models/ldraw/officialLibrary/models/car.ldr_Packed.mpd', | |||
| 'https://threejs.org/examples/models/vtk/bunny.vtk', | |||
| 'https://threejs.org/examples/models/vtk/cube_binary.vtp', | |||
| 'https://threejs.org/examples/models/xyz/helix_201.xyz', | |||
| 'https://threejs.org/examples/models/vrml/meshWithTexture.wrl', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/3ds/portalgun/portalgun.3ds', // todo - to load textures there should be a way to set basepath to portalgun/textures | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/3mf/cube_gears.3mf', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/collada/elf/elf.dae', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/amf/rook.amf', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/gcode/benchy.gcode', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/bvh/pirouette.bvh', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/vox/monu10.vox', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/mdd/cube.mdd', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/pcd/binary/Zaghetto.pcd', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/tilt/BRUSH_DOME.tilt', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/ldraw/officialLibrary/models/car.ldr_Packed.mpd', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/vtk/bunny.vtk', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/vtk/cube_binary.vtp', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/xyz/helix_201.xyz', | |||
| 'https://cdn.jsdelivr.net/gh/repalash/three.js-modded@v0.157.1004/examples/models/vrml/meshWithTexture.wrl', | |||
| ] | |||
| const options: ImportAddOptions = { | |||
| @@ -102,5 +102,6 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| Color, | |||
| GLTFLoader2, | |||
| IObject3D, | |||
| @@ -52,4 +52,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,9 +24,10 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module"> | |||
| import {_testFinish, HemisphereLight, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, HemisphereLight, ThreeViewer} from 'threepipe' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas')}) | |||
| @@ -41,6 +42,7 @@ | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| </script> | |||
| </head> | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, FilmicGrainPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, FilmicGrainPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| async function init() { | |||
| @@ -19,4 +19,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| FragmentClippingExtensionPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| @@ -48,4 +48,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| BoxGeometry, | |||
| FrameFadePlugin, | |||
| LoadingScreenPlugin, | |||
| @@ -42,4 +42,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, FullScreenPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, FullScreenPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {createSimpleButtons} from '../examples-utils/simple-bottom-buttons.js' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| @@ -31,4 +31,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| downloadBlob, | |||
| FloatType, | |||
| GBufferPlugin, | |||
| @@ -94,4 +94,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -27,6 +27,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| CameraViewPlugin, | |||
| LoadingScreenPlugin, | |||
| Object3DGeneratorPlugin, | |||
| @@ -34,5 +34,6 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, GeometryUVPreviewPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, GeometryUVPreviewPlugin, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| const viewer = new ThreeViewer({ | |||
| canvas: document.getElementById('mcanvas') as HTMLCanvasElement, | |||
| @@ -33,4 +33,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,12 @@ | |||
| import {_testFinish, AssetExporterPlugin, downloadBlob, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| AssetExporterPlugin, | |||
| downloadBlob, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {createSimpleButtons} from '../examples-utils/simple-bottom-buttons.js' | |||
| import {GLTFDracoExportPlugin} from '@threepipe/plugin-gltf-transform' | |||
| @@ -69,4 +77,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, downloadBlob, IMaterial, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, downloadBlob, IMaterial, IObject3D, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {createSimpleButtons} from '../examples-utils/simple-bottom-buttons.js' | |||
| const viewer = new ThreeViewer({canvas: document.getElementById('mcanvas') as HTMLCanvasElement, msaa: true}) | |||
| @@ -64,4 +64,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -50,6 +50,7 @@ | |||
| font-weight: 600; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, GLTFAnimationPlugin, ICamera, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, GLTFAnimationPlugin, ICamera, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| async function init() { | |||
| @@ -32,4 +32,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, GLTFAnimationPlugin, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, GLTFAnimationPlugin, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| async function init() { | |||
| @@ -27,4 +27,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, GLTFAnimationPlugin, ICamera, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, GLTFAnimationPlugin, ICamera, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| async function init() { | |||
| @@ -40,4 +40,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| GLTFKHRMaterialVariantsPlugin, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| @@ -33,4 +33,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,4 @@ | |||
| import {_testFinish, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| import {_testFinish, _testStart, LoadingScreenPlugin, ThreeViewer} from 'threepipe' | |||
| async function init() { | |||
| @@ -30,4 +30,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| BufferGeometry, | |||
| BufferGeometry2, | |||
| Color, | |||
| @@ -81,4 +81,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -24,6 +24,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,5 +1,5 @@ | |||
| import { | |||
| _testFinish, | |||
| _testFinish, _testStart, | |||
| GLTFMeshOptDecodePlugin, | |||
| IObject3D, | |||
| KTX2LoadPlugin, | |||
| @@ -36,4 +36,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,11 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, RenderTargetPreviewPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| RenderTargetPreviewPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| const viewer = new ThreeViewer({ | |||
| @@ -51,4 +58,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,11 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, RenderTargetPreviewPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| RenderTargetPreviewPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| const viewer = new ThreeViewer({ | |||
| @@ -50,4 +57,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||
| @@ -1,4 +1,11 @@ | |||
| import {_testFinish, IObject3D, LoadingScreenPlugin, RenderTargetPreviewPlugin, ThreeViewer} from 'threepipe' | |||
| import { | |||
| _testFinish, | |||
| _testStart, | |||
| IObject3D, | |||
| LoadingScreenPlugin, | |||
| RenderTargetPreviewPlugin, | |||
| ThreeViewer, | |||
| } from 'threepipe' | |||
| import {TweakpaneUiPlugin} from '@threepipe/plugin-tweakpane' | |||
| const viewer = new ThreeViewer({ | |||
| @@ -50,4 +57,5 @@ async function init() { | |||
| } | |||
| _testStart() | |||
| init().finally(_testFinish) | |||
| @@ -25,6 +25,7 @@ | |||
| overflow: hidden; | |||
| } | |||
| </style> | |||
| <script type="module" src="../examples-utils/global-loading.mjs"></script> | |||
| <script type="module" src="../examples-utils/simple-code-preview.mjs"></script> | |||
| <script id="example-script" type="module" src="./script.js" data-scripts="./script.ts;./script.js"></script> | |||
| </head> | |||