angular-three-soba 2.0.0-beta.8 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +62 -4
- package/abstractions/README.md +279 -2
- package/abstractions/index.d.ts +13 -6
- package/abstractions/lib/billboard.d.ts +19 -0
- package/abstractions/lib/catmull-rom-line.d.ts +617 -0
- package/abstractions/lib/cubic-bezier-line.d.ts +19 -0
- package/abstractions/lib/edges.d.ts +800 -0
- package/abstractions/lib/gradient-texture.d.ts +24 -0
- package/abstractions/lib/grid.d.ts +315 -0
- package/abstractions/lib/helper.d.ts +25 -0
- package/abstractions/lib/line.d.ts +41 -0
- package/abstractions/lib/prism-geometry.d.ts +32 -0
- package/abstractions/lib/quadratic-bezier-line.d.ts +21 -0
- package/abstractions/lib/rounded-box.d.ts +41 -0
- package/abstractions/lib/text-3d.d.ts +314 -0
- package/abstractions/lib/text.d.ts +54 -0
- package/cameras/README.md +91 -2
- package/cameras/index.d.ts +4 -4
- package/cameras/lib/camera-content.d.ts +10 -0
- package/cameras/lib/cube-camera.d.ts +38 -0
- package/cameras/lib/orthographic-camera.d.ts +40 -0
- package/cameras/lib/perspective-camera.d.ts +36 -0
- package/controls/README.md +96 -2
- package/controls/index.d.ts +4 -1
- package/controls/lib/camera-controls.d.ts +31 -0
- package/controls/lib/orbit-controls.d.ts +38 -0
- package/controls/lib/pivot-controls/axis-arrow.d.ts +31 -0
- package/controls/lib/pivot-controls/axis-rotator.d.ts +30 -0
- package/controls/lib/pivot-controls/pivot-controls.d.ts +110 -0
- package/controls/lib/pivot-controls/plane-slider.d.ts +32 -0
- package/controls/lib/pivot-controls/scaling-sphere.d.ts +32 -0
- package/controls/lib/scroll-controls.d.ts +78 -0
- package/esm2022/abstractions/index.mjs +14 -7
- package/esm2022/abstractions/lib/billboard.mjs +69 -0
- package/esm2022/abstractions/lib/catmull-rom-line.mjs +76 -0
- package/esm2022/abstractions/lib/cubic-bezier-line.mjs +51 -0
- package/esm2022/abstractions/lib/edges.mjs +70 -0
- package/esm2022/abstractions/lib/gradient-texture.mjs +91 -0
- package/esm2022/abstractions/lib/grid.mjs +103 -0
- package/esm2022/abstractions/lib/helper.mjs +76 -0
- package/esm2022/abstractions/lib/line.mjs +126 -0
- package/esm2022/abstractions/lib/prism-geometry.mjs +46 -0
- package/esm2022/abstractions/lib/quadratic-bezier-line.mjs +73 -0
- package/esm2022/abstractions/lib/rounded-box.mjs +111 -0
- package/esm2022/abstractions/lib/text-3d.mjs +98 -0
- package/esm2022/abstractions/lib/text.mjs +91 -0
- package/esm2022/cameras/index.mjs +5 -5
- package/esm2022/cameras/lib/camera-content.mjs +14 -0
- package/esm2022/cameras/lib/cube-camera.mjs +111 -0
- package/esm2022/cameras/lib/orthographic-camera.mjs +131 -0
- package/esm2022/cameras/lib/perspective-camera.mjs +104 -0
- package/esm2022/controls/index.mjs +5 -2
- package/esm2022/controls/lib/camera-controls.mjs +127 -0
- package/esm2022/controls/lib/orbit-controls.mjs +132 -0
- package/esm2022/controls/lib/pivot-controls/axis-arrow.mjs +263 -0
- package/esm2022/controls/lib/pivot-controls/axis-rotator.mjs +264 -0
- package/esm2022/controls/lib/pivot-controls/pivot-controls.mjs +340 -0
- package/esm2022/controls/lib/pivot-controls/plane-slider.mjs +266 -0
- package/esm2022/controls/lib/pivot-controls/scaling-sphere.mjs +232 -0
- package/esm2022/controls/lib/scroll-controls.mjs +268 -0
- package/esm2022/loaders/index.mjs +6 -5
- package/esm2022/loaders/lib/font-loader.mjs +49 -0
- package/esm2022/loaders/lib/gltf-loader.mjs +51 -0
- package/esm2022/loaders/lib/loader.mjs +109 -0
- package/esm2022/loaders/lib/progress.mjs +51 -0
- package/esm2022/loaders/lib/texture-loader.mjs +32 -0
- package/esm2022/materials/index.mjs +8 -7
- package/esm2022/materials/lib/custom-shader-material.mjs +71 -0
- package/esm2022/materials/lib/mesh-distort-material.mjs +42 -0
- package/esm2022/materials/lib/mesh-reflector-material.mjs +278 -0
- package/esm2022/materials/lib/mesh-refraction-material.mjs +144 -0
- package/esm2022/materials/lib/mesh-transmission-material.mjs +188 -0
- package/esm2022/materials/lib/mesh-wobble-material.mjs +42 -0
- package/esm2022/materials/lib/point-material.mjs +33 -0
- package/esm2022/misc/index.mjs +14 -14
- package/esm2022/misc/lib/animations.mjs +71 -0
- package/esm2022/misc/lib/bake-shadows.mjs +26 -0
- package/esm2022/misc/lib/computed-attribute.mjs +55 -0
- package/esm2022/misc/lib/constants.mjs +5 -0
- package/esm2022/misc/lib/decal.mjs +139 -0
- package/esm2022/misc/lib/deprecated.mjs +15 -0
- package/esm2022/misc/lib/depth-buffer.mjs +39 -0
- package/esm2022/misc/lib/fbo.mjs +86 -0
- package/esm2022/misc/lib/html/html-content.mjs +327 -0
- package/esm2022/misc/lib/html/html.mjs +129 -0
- package/esm2022/misc/lib/html/utils.mjs +74 -0
- package/esm2022/misc/lib/intersect.mjs +52 -0
- package/esm2022/misc/lib/sampler.mjs +122 -0
- package/esm2022/misc/lib/scale-factor.mjs +29 -0
- package/esm2022/performances/index.mjs +7 -6
- package/esm2022/performances/lib/adaptive-dpr.mjs +52 -0
- package/esm2022/performances/lib/adaptive-events.mjs +28 -0
- package/esm2022/performances/lib/detailed.mjs +57 -0
- package/esm2022/performances/lib/instances/instances.mjs +183 -0
- package/esm2022/performances/lib/instances/position-mesh.mjs +51 -0
- package/esm2022/performances/lib/points/points.mjs +278 -0
- package/esm2022/performances/lib/points/position-point.mjs +53 -0
- package/esm2022/performances/lib/segments/segment-object.mjs +9 -0
- package/esm2022/performances/lib/segments/segments.mjs +129 -0
- package/esm2022/shaders/index.mjs +4 -18
- package/esm2022/shaders/lib/grid-material.mjs +81 -0
- package/esm2022/shaders/lib/mesh-refraction-material.mjs +163 -0
- package/esm2022/shaders/lib/point-material.mjs +24 -0
- package/esm2022/staging/index.mjs +19 -22
- package/esm2022/staging/lib/accumulative-shadows.mjs +182 -0
- package/esm2022/staging/lib/backdrop.mjs +73 -0
- package/esm2022/staging/lib/bb-anchor.mjs +58 -0
- package/esm2022/staging/lib/bounds.mjs +286 -0
- package/esm2022/staging/lib/camera-shake.mjs +69 -0
- package/esm2022/staging/lib/caustics.mjs +188 -0
- package/esm2022/staging/lib/center.mjs +118 -0
- package/esm2022/staging/lib/contact-shadows.mjs +214 -0
- package/esm2022/staging/lib/environment.mjs +481 -0
- package/esm2022/staging/lib/float.mjs +70 -0
- package/esm2022/staging/lib/lightformer.mjs +107 -0
- package/esm2022/staging/lib/matcap-texture.mjs +81 -0
- package/esm2022/staging/lib/normal-texture.mjs +81 -0
- package/esm2022/staging/lib/randomized-lights.mjs +104 -0
- package/esm2022/staging/lib/render-texture.mjs +203 -0
- package/esm2022/staging/lib/sky.mjs +86 -0
- package/esm2022/staging/lib/spot-light.mjs +453 -0
- package/esm2022/staging/lib/stage.mjs +236 -0
- package/esm2022/{utils/angular-three-soba-utils.mjs → stats/angular-three-soba-stats.mjs} +1 -1
- package/esm2022/stats/index.mjs +2 -0
- package/esm2022/stats/lib/stats.mjs +63 -0
- package/esm2022/vanilla-exports/angular-three-soba-vanilla-exports.mjs +5 -0
- package/esm2022/vanilla-exports/index.mjs +3 -0
- package/fesm2022/angular-three-soba-abstractions.mjs +884 -697
- package/fesm2022/angular-three-soba-abstractions.mjs.map +1 -1
- package/fesm2022/angular-three-soba-cameras.mjs +261 -308
- package/fesm2022/angular-three-soba-cameras.mjs.map +1 -1
- package/fesm2022/angular-three-soba-controls.mjs +1776 -109
- package/fesm2022/angular-three-soba-controls.mjs.map +1 -1
- package/fesm2022/angular-three-soba-loaders.mjs +191 -145
- package/fesm2022/angular-three-soba-loaders.mjs.map +1 -1
- package/fesm2022/angular-three-soba-materials.mjs +527 -748
- package/fesm2022/angular-three-soba-materials.mjs.map +1 -1
- package/fesm2022/angular-three-soba-misc.mjs +783 -1935
- package/fesm2022/angular-three-soba-misc.mjs.map +1 -1
- package/fesm2022/angular-three-soba-performances.mjs +591 -475
- package/fesm2022/angular-three-soba-performances.mjs.map +1 -1
- package/fesm2022/angular-three-soba-shaders.mjs +51 -1369
- package/fesm2022/angular-three-soba-shaders.mjs.map +1 -1
- package/fesm2022/angular-three-soba-staging.mjs +2350 -3521
- package/fesm2022/angular-three-soba-staging.mjs.map +1 -1
- package/fesm2022/angular-three-soba-stats.mjs +70 -0
- package/fesm2022/angular-three-soba-stats.mjs.map +1 -0
- package/fesm2022/angular-three-soba-vanilla-exports.mjs +6 -0
- package/fesm2022/angular-three-soba-vanilla-exports.mjs.map +1 -0
- package/loaders/README.md +130 -2
- package/loaders/index.d.ts +5 -4
- package/loaders/lib/font-loader.d.ts +27 -0
- package/loaders/lib/gltf-loader.d.ts +24 -0
- package/loaders/lib/loader.d.ts +29 -0
- package/loaders/lib/progress.d.ts +9 -0
- package/loaders/lib/texture-loader.d.ts +13 -0
- package/materials/README.md +160 -2
- package/materials/index.d.ts +7 -6
- package/materials/lib/custom-shader-material.d.ts +20 -0
- package/materials/lib/mesh-distort-material.d.ts +17 -0
- package/materials/lib/mesh-reflector-material.d.ts +51 -0
- package/materials/lib/mesh-refraction-material.d.ts +42 -0
- package/materials/lib/mesh-transmission-material.d.ts +77 -0
- package/materials/lib/mesh-wobble-material.d.ts +15 -0
- package/materials/lib/point-material.d.ts +11 -0
- package/metadata.json +1 -1
- package/misc/README.md +217 -2
- package/misc/index.d.ts +13 -13
- package/misc/lib/animations.d.ts +17 -0
- package/misc/lib/computed-attribute.d.ts +64 -0
- package/misc/lib/constants.d.ts +1 -0
- package/misc/lib/decal.d.ts +27 -0
- package/misc/lib/deprecated.d.ts +14 -0
- package/misc/lib/depth-buffer.d.ts +8 -0
- package/misc/lib/fbo.d.ts +46 -0
- package/misc/lib/html/html-content.d.ts +47 -0
- package/misc/lib/html/html.d.ts +30 -0
- package/misc/lib/html/utils.d.ts +14 -0
- package/misc/lib/intersect.d.ts +13 -0
- package/misc/lib/sampler.d.ts +73 -0
- package/misc/lib/scale-factor.d.ts +3 -0
- package/package.json +89 -48
- package/performances/index.d.ts +6 -5
- package/performances/lib/adaptive-dpr.d.ts +7 -0
- package/performances/{adaptive-events → lib}/adaptive-events.d.ts +0 -3
- package/performances/lib/detailed.d.ts +17 -0
- package/performances/lib/instances/instances.d.ts +122 -0
- package/performances/lib/instances/position-mesh.d.ts +20 -0
- package/performances/lib/points/points.d.ts +224 -0
- package/performances/lib/points/position-point.d.ts +21 -0
- package/performances/lib/segments/segment-object.d.ts +17 -0
- package/performances/lib/segments/segments.d.ts +97 -0
- package/shaders/index.d.ts +3 -17
- package/shaders/lib/grid-material.d.ts +69 -0
- package/shaders/lib/mesh-refraction-material.d.ts +11 -0
- package/shaders/lib/point-material.d.ts +14 -0
- package/staging/README.md +473 -2
- package/staging/index.d.ts +18 -21
- package/staging/lib/accumulative-shadows.d.ts +75 -0
- package/staging/lib/backdrop.d.ts +22 -0
- package/staging/lib/bb-anchor.d.ts +17 -0
- package/staging/lib/bounds.d.ts +47 -0
- package/staging/lib/camera-shake.d.ts +29 -0
- package/staging/lib/caustics.d.ts +53 -0
- package/staging/lib/center.d.ts +390 -0
- package/staging/lib/contact-shadows.d.ts +55 -0
- package/staging/lib/environment.d.ts +132 -0
- package/staging/lib/float.d.ts +20 -0
- package/staging/lib/lightformer.d.ts +310 -0
- package/staging/lib/matcap-texture.d.ts +32 -0
- package/staging/lib/normal-texture.d.ts +37 -0
- package/staging/lib/randomized-lights.d.ts +54 -0
- package/staging/lib/render-texture.d.ts +64 -0
- package/staging/lib/sky.d.ts +32 -0
- package/staging/lib/spot-light.d.ts +119 -0
- package/staging/lib/stage.d.ts +352 -0
- package/stats/README.md +3 -0
- package/stats/index.d.ts +1 -0
- package/stats/lib/stats.d.ts +14 -0
- package/vanilla-exports/README.md +3 -0
- package/vanilla-exports/index.d.ts +27 -0
- package/web-types.json +1 -1
- package/abstractions/billboard/billboard.d.ts +0 -28
- package/abstractions/detailed/detailed.d.ts +0 -26
- package/abstractions/edges/edges.d.ts +0 -34
- package/abstractions/grid/grid.d.ts +0 -50
- package/abstractions/text/text.d.ts +0 -82
- package/abstractions/text-3d/text-3d.d.ts +0 -81
- package/assets/distort.vert.glsl +0 -1
- package/cameras/camera/camera-content.d.ts +0 -13
- package/cameras/camera/camera.d.ts +0 -26
- package/cameras/cube-camera/cube-camera.d.ts +0 -69
- package/cameras/orthographic-camera/orthographic-camera.d.ts +0 -37
- package/cameras/perspective-camera/perspective-camera.d.ts +0 -18
- package/controls/orbit-controls/orbit-controls.d.ts +0 -54
- package/esm2022/abstractions/billboard/billboard.mjs +0 -74
- package/esm2022/abstractions/detailed/detailed.mjs +0 -64
- package/esm2022/abstractions/edges/edges.mjs +0 -88
- package/esm2022/abstractions/grid/grid.mjs +0 -180
- package/esm2022/abstractions/text/text.mjs +0 -274
- package/esm2022/abstractions/text-3d/text-3d.mjs +0 -165
- package/esm2022/cameras/camera/camera-content.mjs +0 -20
- package/esm2022/cameras/camera/camera.mjs +0 -77
- package/esm2022/cameras/cube-camera/cube-camera.mjs +0 -161
- package/esm2022/cameras/orthographic-camera/orthographic-camera.mjs +0 -102
- package/esm2022/cameras/perspective-camera/perspective-camera.mjs +0 -46
- package/esm2022/controls/orbit-controls/orbit-controls.mjs +0 -181
- package/esm2022/loaders/gltf-loader/gltf-loader.mjs +0 -30
- package/esm2022/loaders/loader/loader.mjs +0 -138
- package/esm2022/loaders/progress/progress.mjs +0 -45
- package/esm2022/loaders/texture-loader/texture-loader.mjs +0 -28
- package/esm2022/materials/mesh-distort-material/mesh-distort-material.mjs +0 -82
- package/esm2022/materials/mesh-reflector-material/mesh-reflector-material.mjs +0 -367
- package/esm2022/materials/mesh-refraction-material/mesh-refraction-material.mjs +0 -171
- package/esm2022/materials/mesh-transmission-material/mesh-transmission-material.mjs +0 -278
- package/esm2022/materials/mesh-wobble-material/mesh-wobble-material.mjs +0 -68
- package/esm2022/materials/point-material/point-material.mjs +0 -46
- package/esm2022/misc/animations/animations.mjs +0 -59
- package/esm2022/misc/bake-shadows/bake-shadows.mjs +0 -24
- package/esm2022/misc/caustics/caustics.mjs +0 -387
- package/esm2022/misc/decal/decal.mjs +0 -187
- package/esm2022/misc/depth-buffer/depth-buffer.mjs +0 -44
- package/esm2022/misc/example/example.mjs +0 -160
- package/esm2022/misc/fbo/fbo.mjs +0 -47
- package/esm2022/misc/html/html-wrapper.mjs +0 -478
- package/esm2022/misc/html/html.mjs +0 -304
- package/esm2022/misc/sampler/sampler.mjs +0 -142
- package/esm2022/misc/shadow/shadow.mjs +0 -111
- package/esm2022/misc/stats-gl/stats-gl.mjs +0 -61
- package/esm2022/misc/trail/trail.mjs +0 -209
- package/esm2022/misc/trail-texture/inject-trail-texture.mjs +0 -17
- package/esm2022/misc/trail-texture/trail-texture.mjs +0 -106
- package/esm2022/modifiers/angular-three-soba-modifiers.mjs +0 -5
- package/esm2022/modifiers/curve-modifier/curve-modifier.mjs +0 -64
- package/esm2022/modifiers/index.mjs +0 -2
- package/esm2022/performances/adaptive-dpr/adaptive-dpr.mjs +0 -44
- package/esm2022/performances/adaptive-events/adaptive-events.mjs +0 -27
- package/esm2022/performances/points/points-input.mjs +0 -64
- package/esm2022/performances/points/points.mjs +0 -329
- package/esm2022/performances/points/position-point.mjs +0 -54
- package/esm2022/performances/segments/segment-object.mjs +0 -9
- package/esm2022/performances/segments/segments.mjs +0 -182
- package/esm2022/shaders/blur-pass/blur-pass.mjs +0 -61
- package/esm2022/shaders/caustics/caustics-material.mjs +0 -130
- package/esm2022/shaders/caustics/caustics-projection-material.mjs +0 -31
- package/esm2022/shaders/convolution-material/convolution-material.mjs +0 -94
- package/esm2022/shaders/discard-material/discard-material.mjs +0 -3
- package/esm2022/shaders/grid-material/grid-material.mjs +0 -77
- package/esm2022/shaders/mesh-distort-material/mesh-distort-material.mjs +0 -56
- package/esm2022/shaders/mesh-reflector-material/mesh-reflector-material.mjs +0 -223
- package/esm2022/shaders/mesh-refraction-material/mesh-refraction-material.mjs +0 -170
- package/esm2022/shaders/mesh-transmission-material/mesh-transmission-material.mjs +0 -268
- package/esm2022/shaders/mesh-wobble-material/mesh-wobble-material.mjs +0 -37
- package/esm2022/shaders/shader-material/shader-material.mjs +0 -34
- package/esm2022/shaders/soft-shadow-material/soft-shadow-material.mjs +0 -25
- package/esm2022/shaders/sparkles-material/sparkles-material.mjs +0 -33
- package/esm2022/shaders/spot-light-material/spot-light-material.mjs +0 -86
- package/esm2022/shaders/star-field-material/star-field-material.mjs +0 -33
- package/esm2022/shaders/wireframe-material/wireframe-material.mjs +0 -247
- package/esm2022/staging/accumulative-shadows/accumulative-shadows.mjs +0 -267
- package/esm2022/staging/accumulative-shadows/progressive-light-map.mjs +0 -108
- package/esm2022/staging/accumulative-shadows/randomized-lights.mjs +0 -206
- package/esm2022/staging/backdrop/backdrop.mjs +0 -77
- package/esm2022/staging/bb-anchor/bb-anchor.mjs +0 -70
- package/esm2022/staging/bounds/bounds.mjs +0 -308
- package/esm2022/staging/camera-shake/camera-shake.mjs +0 -123
- package/esm2022/staging/center/center.mjs +0 -163
- package/esm2022/staging/cloud/cloud.mjs +0 -158
- package/esm2022/staging/contact-shadows/contact-shadows.mjs +0 -246
- package/esm2022/staging/environment/assets.mjs +0 -13
- package/esm2022/staging/environment/environment-cube.mjs +0 -47
- package/esm2022/staging/environment/environment-ground.mjs +0 -41
- package/esm2022/staging/environment/environment-input.mjs +0 -119
- package/esm2022/staging/environment/environment-map.mjs +0 -53
- package/esm2022/staging/environment/environment-portal.mjs +0 -113
- package/esm2022/staging/environment/environment.mjs +0 -61
- package/esm2022/staging/environment/utils.mjs +0 -105
- package/esm2022/staging/float/float.mjs +0 -94
- package/esm2022/staging/matcap-texture/matcap-texture.mjs +0 -64
- package/esm2022/staging/normal-texture/normal-texture.mjs +0 -53
- package/esm2022/staging/sky/sky.mjs +0 -119
- package/esm2022/staging/sparkles/sparkles.mjs +0 -164
- package/esm2022/staging/spot-light/shadow-mesh-input.mjs +0 -63
- package/esm2022/staging/spot-light/shadow-mesh.mjs +0 -266
- package/esm2022/staging/spot-light/spot-light-input.mjs +0 -84
- package/esm2022/staging/spot-light/spot-light.mjs +0 -81
- package/esm2022/staging/spot-light/volumetric-mesh.mjs +0 -98
- package/esm2022/staging/stage/stage.mjs +0 -388
- package/esm2022/staging/stars/stars.mjs +0 -147
- package/esm2022/staging/wireframe/wireframe-input.mjs +0 -191
- package/esm2022/staging/wireframe/wireframe.mjs +0 -224
- package/esm2022/utils/content/content.mjs +0 -15
- package/esm2022/utils/index.mjs +0 -2
- package/fesm2022/angular-three-soba-modifiers.mjs +0 -71
- package/fesm2022/angular-three-soba-modifiers.mjs.map +0 -1
- package/fesm2022/angular-three-soba-utils.mjs +0 -22
- package/fesm2022/angular-three-soba-utils.mjs.map +0 -1
- package/loaders/gltf-loader/gltf-loader.d.ts +0 -10
- package/loaders/loader/loader.d.ts +0 -33
- package/loaders/progress/progress.d.ts +0 -9
- package/loaders/texture-loader/texture-loader.d.ts +0 -7
- package/materials/mesh-distort-material/mesh-distort-material.d.ts +0 -40
- package/materials/mesh-reflector-material/mesh-reflector-material.d.ts +0 -99
- package/materials/mesh-refraction-material/mesh-refraction-material.d.ts +0 -62
- package/materials/mesh-transmission-material/mesh-transmission-material.d.ts +0 -107
- package/materials/mesh-wobble-material/mesh-wobble-material.d.ts +0 -29
- package/materials/point-material/point-material.d.ts +0 -24
- package/misc/animations/animations.d.ts +0 -15
- package/misc/caustics/caustics.d.ts +0 -87
- package/misc/decal/decal.d.ts +0 -49
- package/misc/depth-buffer/depth-buffer.d.ts +0 -9
- package/misc/example/example.d.ts +0 -81
- package/misc/fbo/fbo.d.ts +0 -17
- package/misc/html/html-wrapper.d.ts +0 -559
- package/misc/html/html.d.ts +0 -214
- package/misc/sampler/sampler.d.ts +0 -67
- package/misc/shadow/shadow.d.ts +0 -37
- package/misc/stats-gl/stats-gl.d.ts +0 -24
- package/misc/trail/trail.d.ts +0 -57
- package/misc/trail-texture/inject-trail-texture.d.ts +0 -9
- package/misc/trail-texture/trail-texture.d.ts +0 -50
- package/modifiers/README.md +0 -3
- package/modifiers/curve-modifier/curve-modifier.d.ts +0 -23
- package/modifiers/index.d.ts +0 -1
- package/performances/adaptive-dpr/adaptive-dpr.d.ts +0 -14
- package/performances/points/points-input.d.ts +0 -32
- package/performances/points/points.d.ts +0 -92
- package/performances/points/position-point.d.ts +0 -11
- package/performances/segments/segment-object.d.ts +0 -7
- package/performances/segments/segments.d.ts +0 -124
- package/shaders/blur-pass/blur-pass.d.ts +0 -23
- package/shaders/caustics/caustics-material.d.ts +0 -4
- package/shaders/caustics/caustics-projection-material.d.ts +0 -4
- package/shaders/convolution-material/convolution-material.d.ts +0 -7
- package/shaders/discard-material/discard-material.d.ts +0 -3
- package/shaders/grid-material/grid-material.d.ts +0 -37
- package/shaders/mesh-distort-material/mesh-distort-material.d.ts +0 -295
- package/shaders/mesh-reflector-material/mesh-reflector-material.d.ts +0 -50
- package/shaders/mesh-refraction-material/mesh-refraction-material.d.ts +0 -4
- package/shaders/mesh-transmission-material/mesh-transmission-material.d.ts +0 -25
- package/shaders/mesh-wobble-material/mesh-wobble-material.d.ts +0 -16
- package/shaders/shader-material/shader-material.d.ts +0 -6
- package/shaders/soft-shadow-material/soft-shadow-material.d.ts +0 -19
- package/shaders/sparkles-material/sparkles-material.d.ts +0 -17
- package/shaders/spot-light-material/spot-light-material.d.ts +0 -13
- package/shaders/star-field-material/star-field-material.d.ts +0 -13
- package/shaders/wireframe-material/wireframe-material.d.ts +0 -58
- package/staging/accumulative-shadows/accumulative-shadows.d.ts +0 -146
- package/staging/accumulative-shadows/progressive-light-map.d.ts +0 -34
- package/staging/accumulative-shadows/randomized-lights.d.ts +0 -90
- package/staging/backdrop/backdrop.d.ts +0 -30
- package/staging/bb-anchor/bb-anchor.d.ts +0 -27
- package/staging/bounds/bounds.d.ts +0 -134
- package/staging/camera-shake/camera-shake.d.ts +0 -43
- package/staging/center/center.d.ts +0 -70
- package/staging/cloud/cloud.d.ts +0 -51
- package/staging/contact-shadows/contact-shadows.d.ts +0 -70
- package/staging/environment/assets.d.ts +0 -13
- package/staging/environment/environment-cube.d.ts +0 -15
- package/staging/environment/environment-ground.d.ts +0 -13
- package/staging/environment/environment-input.d.ts +0 -68
- package/staging/environment/environment-map.d.ts +0 -16
- package/staging/environment/environment-portal.d.ts +0 -18
- package/staging/environment/environment.d.ts +0 -8
- package/staging/environment/utils.d.ts +0 -7
- package/staging/float/float.d.ts +0 -31
- package/staging/matcap-texture/matcap-texture.d.ts +0 -13
- package/staging/normal-texture/normal-texture.d.ts +0 -16
- package/staging/sky/sky.d.ts +0 -48
- package/staging/sparkles/sparkles.d.ts +0 -63
- package/staging/spot-light/shadow-mesh-input.d.ts +0 -29
- package/staging/spot-light/shadow-mesh.d.ts +0 -37
- package/staging/spot-light/spot-light-input.d.ts +0 -38
- package/staging/spot-light/spot-light.d.ts +0 -39
- package/staging/spot-light/volumetric-mesh.d.ts +0 -24
- package/staging/stage/stage.d.ts +0 -130
- package/staging/stars/stars.d.ts +0 -45
- package/staging/wireframe/wireframe-input.d.ts +0 -65
- package/staging/wireframe/wireframe.d.ts +0 -28
- package/utils/README.md +0 -3
- package/utils/content/content.d.ts +0 -8
- package/utils/index.d.ts +0 -1
- /package/misc/{bake-shadows → lib}/bake-shadows.d.ts +0 -0
package/README.md
CHANGED
|
@@ -1,7 +1,65 @@
|
|
|
1
|
-
# soba
|
|
1
|
+
# `angular-three-soba`
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
`angular-three-soba` provides a comprehensive set of utilities and abstractions for building 3D applications with Angular Three. It offers components and helpers for various aspects of your projects, including cameras, controls, loaders, materials, shaders, and more. These components are ported from the popular React Three Fiber [`drei`](https://github.com/pmndrs/drei) library, making it easier for developers familiar with `drei` to leverage its functionality within the Angular ecosystem.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Installation
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
```bash
|
|
8
|
+
npm install angular-three-soba three-stdlib
|
|
9
|
+
# yarn add angular-three-soba three-stdlib
|
|
10
|
+
# pnpm add angular-three-soba three-stdlib
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
> There are more peer dependencies that the consumers might need to install separately based on the secondary entry points that they pull in. Check the secondary entry points documentation for more information.
|
|
14
|
+
|
|
15
|
+
## Secondary Entry Points
|
|
16
|
+
|
|
17
|
+
`angular-three-soba` is organized into multiple secondary entry points, each focusing on a specific area of functionality. This modular structure allows you to import only the components you need, keeping your project lean and efficient.
|
|
18
|
+
|
|
19
|
+
### `angular-three-soba/abstractions`
|
|
20
|
+
|
|
21
|
+
Provides abstract components and patterns for building reusable and composable 3D elements in Angular Three.
|
|
22
|
+
|
|
23
|
+
[Read more about `angular-three-soba/abstractions`](./abstractions/README.md)
|
|
24
|
+
|
|
25
|
+
### `angular-three-soba/cameras`
|
|
26
|
+
|
|
27
|
+
Offers a variety of camera components, including specialized cameras like the `CubeCamera`, `OrthographicCamera`, and `PerspectiveCamera`, as well as helper components for camera controls.
|
|
28
|
+
|
|
29
|
+
[Read more about `angular-three-soba/cameras`](./cameras/README.md)
|
|
30
|
+
|
|
31
|
+
### `angular-three-soba/controls`
|
|
32
|
+
|
|
33
|
+
Includes components for user interaction and camera manipulation, such as the `OrbitControls`, `PointerLockControls`, and `TransformControls`.
|
|
34
|
+
|
|
35
|
+
[Read more about `angular-three-soba/controls`](./controls/README.md)
|
|
36
|
+
|
|
37
|
+
### `angular-three-soba/loaders`
|
|
38
|
+
|
|
39
|
+
Provides loaders for different types of 3D assets, including GLTF, texture, cube texture, HDR, and more.
|
|
40
|
+
|
|
41
|
+
[Read more about `angular-three-soba/loaders`](./loaders/README.md)
|
|
42
|
+
|
|
43
|
+
### `angular-three-soba/materials`
|
|
44
|
+
|
|
45
|
+
Offers a collection of materials with advanced features, such as `MeshReflectorMaterial`, `PhysicalMaterial`, `ShaderMaterial`, and `NormalMaterial`.
|
|
46
|
+
|
|
47
|
+
[Read more about `angular-three-soba/materials`](./materials/README.md)
|
|
48
|
+
|
|
49
|
+
### `angular-three-soba/misc`
|
|
50
|
+
|
|
51
|
+
Contains miscellaneous components for various tasks, like the `Stats` component for displaying performance statistics, the `Shadow` component for rendering shadows, and the `Text` component for adding 3D text.
|
|
52
|
+
|
|
53
|
+
[Read more about `angular-three-soba/misc`](./misc/README.md)
|
|
54
|
+
|
|
55
|
+
### `angular-three-soba/shaders`
|
|
56
|
+
|
|
57
|
+
Includes shader components and utilities for creating custom shaders and post-processing effects.
|
|
58
|
+
|
|
59
|
+
[Read more about `angular-three-soba/shaders`](./shaders/README.md)
|
|
60
|
+
|
|
61
|
+
### `angular-three-soba/staging`
|
|
62
|
+
|
|
63
|
+
Provides helpful components for staging and managing 3D scenes, such as the `Environment` component for setting up environment lighting, the `Stage` component for creating a basic stage setup, and the `PresentationControls` component for interactive scene presentations.
|
|
64
|
+
|
|
65
|
+
[Read more about `angular-three-soba/staging`](./staging/README.md)
|
package/abstractions/README.md
CHANGED
|
@@ -1,3 +1,280 @@
|
|
|
1
|
-
# angular-three-soba/abstractions
|
|
1
|
+
# `angular-three-soba/abstractions`
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
This module provides abstract components and patterns for building reusable and composable 3D elements in Angular Three. It requires the following peer dependencies:
|
|
4
|
+
|
|
5
|
+
| Package | Description |
|
|
6
|
+
| ------------------- | -------------------------------------------- |
|
|
7
|
+
| `troika-three-text` | Required for using the `NgtsText` component. |
|
|
8
|
+
| `three-mesh-bvh` | Required for `angular-three-soba/shaders` |
|
|
9
|
+
|
|
10
|
+
To install these dependencies, use one of the following commands:
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
npm install troika-three-text three-mesh-bvh
|
|
14
|
+
# yarn add troika-three-text three-mesh-bvh
|
|
15
|
+
# pnpm add troika-three-text three-mesh-bvh
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## TOC
|
|
19
|
+
|
|
20
|
+
- [NgtsGrid](#ngtsgrid)
|
|
21
|
+
- [NgtsText](#ngtstext)
|
|
22
|
+
- [NgtsText3D](#ngtstext3d)
|
|
23
|
+
- [NgtsLine](#ngtsline)
|
|
24
|
+
- [NgtsQuadraticBezierLine](#ngtsquadraticbezierline)
|
|
25
|
+
- [NgtsCubicBezierLine](#ngtscubicbezierline)
|
|
26
|
+
- [NgtsCatmullRomLine](#ngtscatmullromline)
|
|
27
|
+
- [NgtsEdges](#ngtsedges)
|
|
28
|
+
- [NgtsPrismGeometry](#ngtsprismgeometry)
|
|
29
|
+
- [NgtsGradientTexture](#ngtsgradienttexture)
|
|
30
|
+
- [injectHelper](#injecthelper)
|
|
31
|
+
- [NgtsHelper](#ngtshelper)
|
|
32
|
+
|
|
33
|
+
## NgtsGrid
|
|
34
|
+
|
|
35
|
+
A y-up oriented, shader-based grid implementation.
|
|
36
|
+
|
|
37
|
+
This component renders a grid using a shader material, allowing for efficient rendering of large grids. It provides options to customize the appearance of the grid, such as cell size, cell thickness, cell color, section size, section thickness, section color, and more.
|
|
38
|
+
|
|
39
|
+
### Object Inputs (NgtsGridOptions)
|
|
40
|
+
|
|
41
|
+
| Property | Description | Default Value |
|
|
42
|
+
| ------------------ | ------------------------------------------------------------------------------------------------------------ | ----------------- |
|
|
43
|
+
| `planeArgs` | Default plane-geometry arguments. | `[]` |
|
|
44
|
+
| `cellSize` | Cell size. | `0.5` |
|
|
45
|
+
| `cellThickness` | Cell thickness. | `0.5` |
|
|
46
|
+
| `cellColor` | Cell color. | `'black'` |
|
|
47
|
+
| `sectionSize` | Section size. | `1` |
|
|
48
|
+
| `sectionThickness` | Section thickness. | `1` |
|
|
49
|
+
| `sectionColor` | Section color. | `'#2080ff'` |
|
|
50
|
+
| `infiniteGrid` | Display the grid infinitely. | `false` |
|
|
51
|
+
| `followCamera` | Follow camera. | `false` |
|
|
52
|
+
| `fadeDistance` | Fade distance. | `100` |
|
|
53
|
+
| `fadeStrength` | Fade strength. | `1` |
|
|
54
|
+
| `fadeFrom` | Fade from camera (1) or origin (0), or somewhere in between. | `'camera'` |
|
|
55
|
+
| `side` | Which side of the faces will be rendered. Can be `THREE.FrontSide`, `THREE.BackSide`, or `THREE.DoubleSide`. | `THREE.FrontSide` |
|
|
56
|
+
|
|
57
|
+
```html
|
|
58
|
+
<ngts-grid />
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## NgtsText
|
|
62
|
+
|
|
63
|
+
High-quality text rendering with signed distance fields (SDF) and antialiasing, using `troika-three-text`
|
|
64
|
+
|
|
65
|
+
This component renders high-quality text using SDF and antialiasing techniques. It supports various options for customizing the appearance of the text, such as font, font size, color, alignment, and more.
|
|
66
|
+
|
|
67
|
+
### Object Inputs (NgtsTextOptions)
|
|
68
|
+
|
|
69
|
+
| Property | Description | Default Value |
|
|
70
|
+
| ---------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ------------- |
|
|
71
|
+
| `text` | (Required) Text content. | |
|
|
72
|
+
| `font` | Font family or URL. | `undefined` |
|
|
73
|
+
| `fontSize` | Font size. | `1` |
|
|
74
|
+
| `color` | Text color. | `'black'` |
|
|
75
|
+
| `fontWeight` | Font weight. | `'normal'` |
|
|
76
|
+
| `fontStyle` | Font style. | `'normal'` |
|
|
77
|
+
| `maxWidth` | Maximum width of the text block. | `undefined` |
|
|
78
|
+
| `lineHeight` | Line height. | `1` |
|
|
79
|
+
| `letterSpacing` | Letter spacing. | `0` |
|
|
80
|
+
| `textAlign` | Text alignment. | `'left'` |
|
|
81
|
+
| `anchorX` | Horizontal anchor point. Can be `'left'`, `'center'`, `'right'`, or a number between 0 and 1. | `'center'` |
|
|
82
|
+
| `anchorY` | Vertical anchor point. Can be `'top'`, `'top-baseline'`, `'middle'`, `'bottom-baseline'`, `'bottom'`, or a number between 0 and 1. | `'middle'` |
|
|
83
|
+
| `clipRect` | Clip rectangle. | `undefined` |
|
|
84
|
+
| `depthOffset` | Depth offset. | `0` |
|
|
85
|
+
| `direction` | Text direction. Can be `'auto'`, `'ltr'`, or `'rtl'`. | `'auto'` |
|
|
86
|
+
| `overflowWrap` | Overflow wrap. Can be `'normal'` or `'break-word'`. | `'normal'` |
|
|
87
|
+
| `whiteSpace` | White space. Can be `'normal'` or `'nowrap'`. | `'normal'` |
|
|
88
|
+
| `outlineWidth` | Outline width. | `0` |
|
|
89
|
+
| `outlineOffsetX` | Outline X offset. | `0` |
|
|
90
|
+
| `outlineOffsetY` | Outline Y offset. | `0` |
|
|
91
|
+
| `outlineBlur` | Outline blur. | `0` |
|
|
92
|
+
| `outlineColor` | Outline color. | `'black'` |
|
|
93
|
+
| `outlineOpacity` | Outline opacity. | `1` |
|
|
94
|
+
| `strokeWidth` | Stroke width. | `0` |
|
|
95
|
+
| `strokeColor` | Stroke color. | `'black'` |
|
|
96
|
+
| `strokeOpacity` | Stroke opacity. | `1` |
|
|
97
|
+
| `fillOpacity` | Fill opacity. | `1` |
|
|
98
|
+
| `sdfGlyphSize` | SDF glyph size. | `64` |
|
|
99
|
+
| `debugSDF` | Debug SDF. | `false` |
|
|
100
|
+
|
|
101
|
+
```html
|
|
102
|
+
<ngts-text text="Hello, World!" />
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## NgtsText3D
|
|
106
|
+
|
|
107
|
+
Renders 3D text using ThreeJS's TextGeometry.
|
|
108
|
+
|
|
109
|
+
This component renders 3D text using TextGeometry. It requires fonts in JSON format generated through typeface.json.
|
|
110
|
+
|
|
111
|
+
### Object Inputs (NgtsText3DOptions)
|
|
112
|
+
|
|
113
|
+
| Property | Description | Default Value |
|
|
114
|
+
| ---------------- | ------------------------ | ------------- |
|
|
115
|
+
| `text` | (Required) Text content. | |
|
|
116
|
+
| `font` | Font family or URL. | `undefined` |
|
|
117
|
+
| `size` | Font size. | `1` |
|
|
118
|
+
| `height` | Text height. | `0.2` |
|
|
119
|
+
| `curveSegments` | Curve segments. | `8` |
|
|
120
|
+
| `bevelEnabled` | Enable bevel. | `false` |
|
|
121
|
+
| `bevelThickness` | Bevel thickness. | `0.1` |
|
|
122
|
+
| `bevelSize` | Bevel size. | `0.01` |
|
|
123
|
+
| `bevelOffset` | Bevel offset. | `0` |
|
|
124
|
+
| `bevelSegments` | Bevel segments. | `4` |
|
|
125
|
+
| `smooth` | Smoothness level. | `undefined` |
|
|
126
|
+
|
|
127
|
+
```html
|
|
128
|
+
<ngts-text-3d text="Hello, World!" [options]="{ font: 'path/to/font.json' }" />
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
## NgtsLine
|
|
132
|
+
|
|
133
|
+
Renders a `THREE.Line2` or `THREE.LineSegments2` (depending on the value of `segments`).
|
|
134
|
+
|
|
135
|
+
### Object Inputs (NgtsLineOptions)
|
|
136
|
+
|
|
137
|
+
| Property | Description | Default Value |
|
|
138
|
+
| -------------- | ------------------------------------------------------------ | ------------- |
|
|
139
|
+
| `points` | (Required) Array of points. | |
|
|
140
|
+
| `color` | Line color. | `'black'` |
|
|
141
|
+
| `linewidth` | Line width. | `1` |
|
|
142
|
+
| `segments` | Whether to render as `THREE.Line2` or `THREE.LineSegments2`. | `false` |
|
|
143
|
+
| `dashed` | Whether the line is dashed. | `false` |
|
|
144
|
+
| `vertexColors` | Vertex colors. | undefined |
|
|
145
|
+
|
|
146
|
+
```html
|
|
147
|
+
<ngts-line [points]="[[0, 0, 0], [1, 1, 1]]" />
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
## NgtsQuadraticBezierLine
|
|
151
|
+
|
|
152
|
+
Renders a `THREE.Line2` using `THREE.QuadraticBezierCurve3` for interpolation.
|
|
153
|
+
|
|
154
|
+
### Object Inputs (NgtsQuadraticBezierLineOptions)
|
|
155
|
+
|
|
156
|
+
| Property | Description | Default Value |
|
|
157
|
+
| --------- | ----------------------- | ------------- |
|
|
158
|
+
| `start` | (Required) Start point. | |
|
|
159
|
+
| `end` | (Required) End point. | |
|
|
160
|
+
| `mid` | Mid point. | |
|
|
161
|
+
| `options` | Line options. | `{}` |
|
|
162
|
+
|
|
163
|
+
```html
|
|
164
|
+
<ngts-quadratic-bezier-line [start]="[0, 0, 0]" [end]="[1, 1, 1]" />
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
## NgtsCubicBezierLine
|
|
168
|
+
|
|
169
|
+
Renders a `THREE.Line2` using `THREE.CubicBezierCurve3` for interpolation.
|
|
170
|
+
|
|
171
|
+
### Object Inputs (NgtsCubicBezierLineOptions)
|
|
172
|
+
|
|
173
|
+
| Property | Description | Default Value |
|
|
174
|
+
| --------- | ----------------------- | ------------- |
|
|
175
|
+
| `start` | (Required) Start point. | |
|
|
176
|
+
| `end` | (Required) End point. | |
|
|
177
|
+
| `midA` | (Required) Mid point 1. | |
|
|
178
|
+
| `midB` | (Required) Mid point 2. | |
|
|
179
|
+
| `options` | Line options. | `{}` |
|
|
180
|
+
|
|
181
|
+
```html
|
|
182
|
+
<ngts-cubic-bezier-line [start]="[0, 0, 0]" [end]="[1, 1, 1]" [midA]="[0.5, 0.5, 0.5]" [midB]="[0.5, 0.5, 0.5]" />
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
## NgtsCatmullRomLine
|
|
186
|
+
|
|
187
|
+
Renders a `THREE.Line2` using `THREE.CatmullRomCurve3` for interpolation.
|
|
188
|
+
|
|
189
|
+
### Object Inputs (NgtsCatmullRomLineOptions)
|
|
190
|
+
|
|
191
|
+
| Property | Description | Default Value |
|
|
192
|
+
| ----------- | ---------------------------------------------------------------------- | --------------- |
|
|
193
|
+
| `points` | (Required) Array of points. | |
|
|
194
|
+
| `closed` | Whether the curve is closed. | `false` |
|
|
195
|
+
| `curveType` | Type of curve. Can be `'centripetal'`, `'chordal'`, or `'catmullrom'`. | `'centripetal'` |
|
|
196
|
+
| `tension` | Tension of the curve. | `0.5` |
|
|
197
|
+
| `options` | Line options. | `{}` |
|
|
198
|
+
|
|
199
|
+
```html
|
|
200
|
+
<ngts-catmull-rom-line [points]="[[0, 0, 0], [1, 1, 1]]" />
|
|
201
|
+
```
|
|
202
|
+
|
|
203
|
+
## NgtsEdges
|
|
204
|
+
|
|
205
|
+
Abstracts [THREE.EdgesGeometry](https://threejs.org/docs/#api/en/geometries/EdgesGeometry). It pulls the geometry automatically from its parent, optionally you can ungroup it and give it a `geometry` prop. You can give it children, for instance a custom material. `NgtsEdges` is based on `NgtsLine` and supports all of its options.
|
|
206
|
+
|
|
207
|
+
### Object Inputs (NgtsEdgesOptions)
|
|
208
|
+
|
|
209
|
+
| Property | Description | Default Value |
|
|
210
|
+
| ----------- | ----------------------------------------------------------------------- | ------------- |
|
|
211
|
+
| `geometry` | Geometry to use for the edges. | `undefined` |
|
|
212
|
+
| `threshold` | Display edges only when the angle between two faces exceeds this value. | `15` |
|
|
213
|
+
|
|
214
|
+
```html
|
|
215
|
+
<ngt-mesh>
|
|
216
|
+
<ngt-box-geometry />
|
|
217
|
+
<ngt-mesh-basic-material />
|
|
218
|
+
<ngts-edges [options]="{ threshold: 15, scale: 1.1, color: 'white', linewidth: 4 }" />
|
|
219
|
+
</ngt-mesh>
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
## NgtsPrismGeometry
|
|
223
|
+
|
|
224
|
+
Abstracts [THREE.ExtrudeGeometry](https://threejs.org/docs/#api/en/geometries/ExtrudeGeometry) to create a prism geometry.
|
|
225
|
+
|
|
226
|
+
### Object Inputs (NgtsPrismGeometryOptions)
|
|
227
|
+
|
|
228
|
+
| Property | Description | Default Value |
|
|
229
|
+
| ---------- | ---------------------------- | ------------- |
|
|
230
|
+
| `vertices` | (Required) Array of Vector2. | |
|
|
231
|
+
|
|
232
|
+
```html
|
|
233
|
+
<ngt-mesh>
|
|
234
|
+
<ngts-prism-geometry [vertices]="[[0, 0], [1, 0], [1, 1], [0, 1]]" />
|
|
235
|
+
<ngt-mesh-basic-material />
|
|
236
|
+
</ngt-mesh>
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
## NgtsGradientTexture
|
|
240
|
+
|
|
241
|
+
A declarative `THREE.Texture` which attaches to "map" by default. You can use this to create gradient backgrounds.
|
|
242
|
+
|
|
243
|
+
### Object Inputs (NgtsGradientTextureOptions)
|
|
244
|
+
|
|
245
|
+
| Property | Description | Default Value |
|
|
246
|
+
| ------------------- | ------------------------------------------------------- | ------------- |
|
|
247
|
+
| `stops` | Gradient stops array. | required |
|
|
248
|
+
| `colors` | Gradient colors array. Must be the same size as `stops` | required |
|
|
249
|
+
| `type` | Gradient type. Can be `'linear'` or `'radial'`. | `'linear'` |
|
|
250
|
+
| `size` | Texture size. | `1024` |
|
|
251
|
+
| `width` | Texture width. | `16` |
|
|
252
|
+
| `innerCircleRadius` | Inner circle radius for radial gradients. | `0` |
|
|
253
|
+
| `outerCircleRadius` | Outer circle radius for radial gradients. | `auto` |
|
|
254
|
+
|
|
255
|
+
```html
|
|
256
|
+
<ngt-mesh-basic-material>
|
|
257
|
+
<ngts-gradient-texture [stops]="[0, 0.5, 1]" [colors]="['red', 'green', 'blue']" />
|
|
258
|
+
</ngt-mesh-basic-material>
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
## `injectHelper`
|
|
262
|
+
|
|
263
|
+
A custom inject function to add helpers to existing nodes in the scene. It handles removal of the helper on destroy and auto-updates it by default.
|
|
264
|
+
|
|
265
|
+
```ts
|
|
266
|
+
class MyCmp {
|
|
267
|
+
mesh = viewChild.required<ElementRef<Mesh>>('mesh');
|
|
268
|
+
helper = injectHelper(this.mesh, () => BoxHelper, { args: ['cyan'] });
|
|
269
|
+
}
|
|
270
|
+
```
|
|
271
|
+
|
|
272
|
+
### `NgtsHelper`
|
|
273
|
+
|
|
274
|
+
A declarative way to add helpers to existing nodes in the scene. It handles removal of the helper on destroy and auto-updates it by default.
|
|
275
|
+
|
|
276
|
+
```html
|
|
277
|
+
<ngt-mesh>
|
|
278
|
+
<ngts-helper [type]="BoxHelper" [options]="['cyan']" />
|
|
279
|
+
</ngt-mesh>
|
|
280
|
+
```
|
package/abstractions/index.d.ts
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
|
-
export * from './
|
|
2
|
-
export * from './
|
|
3
|
-
export * from './
|
|
4
|
-
export * from './
|
|
5
|
-
export * from './
|
|
6
|
-
export * from './
|
|
1
|
+
export * from './lib/billboard';
|
|
2
|
+
export * from './lib/catmull-rom-line';
|
|
3
|
+
export * from './lib/cubic-bezier-line';
|
|
4
|
+
export * from './lib/edges';
|
|
5
|
+
export * from './lib/gradient-texture';
|
|
6
|
+
export * from './lib/grid';
|
|
7
|
+
export * from './lib/helper';
|
|
8
|
+
export * from './lib/line';
|
|
9
|
+
export * from './lib/prism-geometry';
|
|
10
|
+
export * from './lib/quadratic-bezier-line';
|
|
11
|
+
export * from './lib/rounded-box';
|
|
12
|
+
export * from './lib/text';
|
|
13
|
+
export * from './lib/text-3d';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ElementRef } from '@angular/core';
|
|
2
|
+
import { NgtGroup } from 'angular-three';
|
|
3
|
+
import { Group } from 'three';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export interface NgtsBillboardOptions extends Partial<NgtGroup> {
|
|
6
|
+
follow?: boolean;
|
|
7
|
+
lockX?: boolean;
|
|
8
|
+
lockY?: boolean;
|
|
9
|
+
lockZ?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export declare class NgtsBillboard {
|
|
12
|
+
options: import("@angular/core").InputSignalWithTransform<NgtsBillboardOptions, "" | Partial<NgtsBillboardOptions>>;
|
|
13
|
+
parameters: import("@angular/core").Signal<Omit<NgtsBillboardOptions, "follow" | "lockX" | "lockY" | "lockZ">>;
|
|
14
|
+
groupRef: import("@angular/core").Signal<ElementRef<Group<import("three").Object3DEventMap>>>;
|
|
15
|
+
innerRef: import("@angular/core").Signal<ElementRef<Group<import("three").Object3DEventMap>>>;
|
|
16
|
+
constructor();
|
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgtsBillboard, never>;
|
|
18
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NgtsBillboard, "ngts-billboard", never, { "options": { "alias": "options"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
19
|
+
}
|