@tresjs/cientos 4.0.0-next.0 → 4.0.0-next.1

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.
Files changed (107) hide show
  1. package/dist/composables/useOnDemandInvalidation.d.ts +3 -0
  2. package/dist/core/abstractions/AnimatedSprite/Atlas.d.ts +38 -0
  3. package/dist/core/abstractions/AnimatedSprite/AtlasAnimationDefinitionParser.d.ts +10 -0
  4. package/dist/core/abstractions/AnimatedSprite/StringOps.d.ts +2 -0
  5. package/dist/core/abstractions/AnimatedSprite/component.vue.d.ts +130 -0
  6. package/dist/core/abstractions/GlobalAudio.d.ts +1 -1
  7. package/dist/core/abstractions/Lensflare/RandUtils.d.ts +2 -2
  8. package/dist/core/abstractions/Lensflare/component.vue.d.ts +13 -12
  9. package/dist/core/abstractions/Lensflare/constants.d.ts +2 -1
  10. package/dist/core/abstractions/Lensflare/index.d.ts +5 -4
  11. package/dist/core/abstractions/Levioso.vue.d.ts +16 -14
  12. package/dist/core/abstractions/MouseParallax.vue.d.ts +22 -11
  13. package/dist/core/abstractions/PositionalAudio.vue.d.ts +69 -0
  14. package/dist/core/abstractions/Reflector.vue.d.ts +12 -9
  15. package/dist/core/abstractions/Text3D.vue.d.ts +8 -6
  16. package/dist/core/abstractions/index.d.ts +11 -8
  17. package/dist/core/abstractions/useAnimations.d.ts +4 -4
  18. package/dist/core/abstractions/useFBO/component.vue.d.ts +6 -5
  19. package/dist/core/abstractions/useFBO/index.d.ts +5 -5
  20. package/dist/core/abstractions/useSurfaceSampler/component.vue.d.ts +8 -5
  21. package/dist/core/abstractions/useSurfaceSampler/index.d.ts +167 -139
  22. package/dist/core/controls/CameraControls.vue.d.ts +4135 -3850
  23. package/dist/core/controls/KeyboardControls.vue.d.ts +44 -90
  24. package/dist/core/controls/MapControls.vue.d.ts +9498 -4
  25. package/dist/core/controls/OrbitControls.vue.d.ts +5897 -5651
  26. package/dist/core/controls/PointerLockControls.vue.d.ts +6 -5
  27. package/dist/core/controls/ScrollControls.vue.d.ts +25 -21
  28. package/dist/core/controls/TransformControls.vue.d.ts +11 -5
  29. package/dist/core/controls/index.d.ts +9 -8
  30. package/dist/core/index.d.ts +0 -1
  31. package/dist/core/loaders/SVG/component.vue.d.ts +14 -13
  32. package/dist/core/loaders/index.d.ts +4 -3
  33. package/dist/core/loaders/useFBX/component.vue.d.ts +9 -9
  34. package/dist/core/loaders/useFBX/index.d.ts +2 -1
  35. package/dist/core/loaders/useGLTF/component.vue.d.ts +16 -16
  36. package/dist/core/loaders/useGLTF/index.d.ts +14 -9
  37. package/dist/core/loaders/useProgress.d.ts +2 -1
  38. package/dist/core/loaders/useVideoTexture.d.ts +1 -0
  39. package/dist/core/materials/customShaderMaterial/index.vue.d.ts +6 -4
  40. package/dist/core/materials/holographicMaterial/HolographicMaterialParameters.d.ts +41 -0
  41. package/dist/core/materials/holographicMaterial/index.vue.d.ts +86 -0
  42. package/dist/core/materials/holographicMaterial/material.d.ts +27 -0
  43. package/dist/core/materials/index.d.ts +7 -5
  44. package/dist/core/materials/meshGlassMaterial/index.vue.d.ts +3 -3
  45. package/dist/core/materials/meshGlassMaterial/material.d.ts +2 -2
  46. package/dist/core/materials/{blurPass.d.ts → meshReflectionMaterial/BlurPass.d.ts} +8 -6
  47. package/dist/core/materials/{convolutionMaterial.d.ts → meshReflectionMaterial/ConvolutionMaterial.d.ts} +1 -0
  48. package/dist/core/materials/meshReflectionMaterial/index.vue.d.ts +171 -40
  49. package/dist/core/materials/meshReflectionMaterial/material.d.ts +33 -36
  50. package/dist/core/materials/meshWobbleMaterial/index.vue.d.ts +8 -6
  51. package/dist/core/materials/meshWobbleMaterial/material.d.ts +2 -2
  52. package/dist/core/misc/BakeShadows.d.ts +1 -1
  53. package/dist/core/misc/Stats.d.ts +2 -2
  54. package/dist/core/misc/StatsGl.d.ts +1 -1
  55. package/dist/core/misc/html/HTML.vue.d.ts +13 -8
  56. package/dist/core/misc/html/utils.d.ts +3 -3
  57. package/dist/core/misc/index.d.ts +3 -3
  58. package/dist/core/misc/useGLTFExporter.d.ts +2 -1
  59. package/dist/core/shapes/Box.vue.d.ts +13 -10
  60. package/dist/core/shapes/CatmullRomCurve3.vue.d.ts +6 -3
  61. package/dist/core/shapes/Circle.vue.d.ts +13 -10
  62. package/dist/core/shapes/Cone.vue.d.ts +13 -10
  63. package/dist/core/shapes/Cylinder.vue.d.ts +60 -0
  64. package/dist/core/shapes/Dodecahedron.vue.d.ts +13 -10
  65. package/dist/core/shapes/Icosahedron.vue.d.ts +13 -10
  66. package/dist/core/shapes/Line2.vue.d.ts +7 -4
  67. package/dist/core/shapes/Octahedron.vue.d.ts +13 -10
  68. package/dist/core/shapes/Plane.vue.d.ts +13 -10
  69. package/dist/core/shapes/Ring.vue.d.ts +13 -10
  70. package/dist/core/shapes/RoundedBox.vue.d.ts +13 -10
  71. package/dist/core/shapes/Sphere.vue.d.ts +13 -10
  72. package/dist/core/shapes/Superformula.vue.d.ts +26 -23
  73. package/dist/core/shapes/Tetrahedron.vue.d.ts +13 -10
  74. package/dist/core/shapes/Torus.vue.d.ts +13 -10
  75. package/dist/core/shapes/TorusKnot.vue.d.ts +13 -10
  76. package/dist/core/shapes/Tube.vue.d.ts +13 -11
  77. package/dist/core/shapes/index.d.ts +20 -18
  78. package/dist/core/staging/Backdrop.vue.d.ts +9 -5
  79. package/dist/core/staging/ContactShadows.vue.d.ts +173 -0
  80. package/dist/core/staging/Fit.vue.d.ts +59 -0
  81. package/dist/core/staging/Ocean.vue.d.ts +15 -12
  82. package/dist/core/staging/Precipitation.vue.d.ts +10 -7
  83. package/dist/core/staging/Sky.vue.d.ts +5 -4
  84. package/dist/core/staging/Smoke.vue.d.ts +7 -6
  85. package/dist/core/staging/Sparkles/ShaderData.d.ts +4 -3
  86. package/dist/core/staging/Sparkles/ShaderDataBuilder.d.ts +7 -7
  87. package/dist/core/staging/Sparkles/component.vue.d.ts +21 -19
  88. package/dist/core/staging/Sparkles/useEmptyDataTexture.d.ts +1 -0
  89. package/dist/core/staging/Stars.vue.d.ts +7 -7
  90. package/dist/core/staging/index.d.ts +13 -10
  91. package/dist/core/staging/useEnvironment/component.vue.d.ts +64 -0
  92. package/dist/core/staging/useEnvironment/const.d.ts +28 -0
  93. package/dist/core/staging/useEnvironment/envSence.d.ts +9 -0
  94. package/dist/core/staging/useEnvironment/index.d.ts +5 -3
  95. package/dist/core/staging/useEnvironment/lightformer/index.vue.d.ts +56 -0
  96. package/dist/trescientos.js +7493 -6606
  97. package/dist/trescientos.umd.cjs +562 -424
  98. package/dist/utils/Gradient.d.ts +3 -2
  99. package/dist/utils/index.d.ts +1 -0
  100. package/dist/utils/types.d.ts +4 -0
  101. package/package.json +28 -28
  102. package/dist/core/directives/index.d.ts +0 -5
  103. package/dist/core/directives/vAlwaysLookAt.d.ts +0 -4
  104. package/dist/core/directives/vDistanceTo.d.ts +0 -4
  105. package/dist/core/directives/vLightHelper.d.ts +0 -5
  106. package/dist/core/directives/vLog.d.ts +0 -3
  107. package/dist/core/misc/useTweakPane/index.d.ts +0 -10
@@ -1,5 +1,6 @@
1
- import type { TresColor } from '@tresjs/core';
2
- import type { TorusKnotGeometry } from 'three';
1
+ import { TresColor } from '@tresjs/core';
2
+ import { TorusKnotGeometry } from 'three';
3
+
3
4
  export interface TorusKnotProps {
4
5
  /**
5
6
  * The radius, tube, radialSegments, tubularSegments and p, q of the torus knot.
@@ -18,20 +19,22 @@ export interface TorusKnotProps {
18
19
  */
19
20
  color?: TresColor;
20
21
  }
21
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TorusKnotProps>, {
22
+ declare function __VLS_template(): {
23
+ default?(_: {}): any;
24
+ };
25
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TorusKnotProps>, {
22
26
  args: () => number[];
23
27
  color: string;
24
28
  }>, {
25
- value: import("vue").ShallowRef<any>;
26
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TorusKnotProps>, {
29
+ instance: import('vue').ShallowRef<any>;
30
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TorusKnotProps>, {
27
31
  args: () => number[];
28
32
  color: string;
29
33
  }>>>, {
30
- color: import("three").ColorRepresentation | [r: number, g: number, b: number];
31
- args: [radius?: number | undefined, tube?: number | undefined, tubularSegments?: number | undefined, radialSegments?: number | undefined, p?: number | undefined, q?: number | undefined];
32
- }, {}>, {
33
- default?(_: {}): any;
34
- }>;
34
+ color: TresColor;
35
+ args: ConstructorParameters<typeof TorusKnotGeometry>;
36
+ }, {}>;
37
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
35
38
  export default _default;
36
39
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
37
40
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -1,6 +1,6 @@
1
- import type { TresColor } from '@tresjs/core';
2
- import type { TubeGeometry } from 'three';
3
- import { QuadraticBezierCurve3, Vector3 } from 'three';
1
+ import { TresColor } from '@tresjs/core';
2
+ import { TubeGeometry, QuadraticBezierCurve3 } from 'three';
3
+
4
4
  export interface TubeProps {
5
5
  /**
6
6
  * The curve, segments, radius, radialSegments, closed.
@@ -19,20 +19,22 @@ export interface TubeProps {
19
19
  */
20
20
  color?: TresColor;
21
21
  }
22
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TubeProps>, {
22
+ declare function __VLS_template(): {
23
+ default?(_: {}): any;
24
+ };
25
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TubeProps>, {
23
26
  args: () => (number | boolean | QuadraticBezierCurve3)[];
24
27
  color: string;
25
28
  }>, {
26
- value: import("vue").ShallowRef<any>;
27
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TubeProps>, {
29
+ instance: import('vue').ShallowRef<any>;
30
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<TubeProps>, {
28
31
  args: () => (number | boolean | QuadraticBezierCurve3)[];
29
32
  color: string;
30
33
  }>>>, {
31
- color: import("three").ColorRepresentation | [r: number, g: number, b: number];
32
- args: [path?: import("three").Curve<Vector3> | undefined, tubularSegments?: number | undefined, radius?: number | undefined, radialSegments?: number | undefined, closed?: boolean | undefined];
33
- }, {}>, {
34
- default?(_: {}): any;
35
- }>;
34
+ color: TresColor;
35
+ args: ConstructorParameters<typeof TubeGeometry>;
36
+ }, {}>;
37
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
36
38
  export default _default;
37
39
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
38
40
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -1,18 +1,20 @@
1
- import Box from './Box.vue';
2
- import CatmullRomCurve3 from './CatmullRomCurve3.vue';
3
- import Circle from './Circle.vue';
4
- import Cone from './Cone.vue';
5
- import Dodecahedron from './Dodecahedron.vue';
6
- import Icosahedron from './Icosahedron.vue';
7
- import Line2 from './Line2.vue';
8
- import Octahedron from './Octahedron.vue';
9
- import Plane from './Plane.vue';
10
- import Ring from './Ring.vue';
11
- import RoundedBox from './RoundedBox.vue';
12
- import Sphere from './Sphere.vue';
13
- import Superformula from './Superformula.vue';
14
- import Tetrahedron from './Tetrahedron.vue';
15
- import Torus from './Torus.vue';
16
- import TorusKnot from './TorusKnot.vue';
17
- import Tube from './Tube.vue';
18
- export { Box, CatmullRomCurve3, Circle, Cone, Dodecahedron, Icosahedron, Line2, Octahedron, Plane, Ring, RoundedBox, Sphere, Superformula, Tetrahedron, Torus, TorusKnot, Tube, };
1
+ import { default as Box } from './Box.vue';
2
+ import { default as CatmullRomCurve3 } from './CatmullRomCurve3.vue';
3
+ import { default as Circle } from './Circle.vue';
4
+ import { default as Cone } from './Cone.vue';
5
+ import { default as Cylinder } from './Cylinder.vue';
6
+ import { default as Dodecahedron } from './Dodecahedron.vue';
7
+ import { default as Icosahedron } from './Icosahedron.vue';
8
+ import { default as Line2 } from './Line2.vue';
9
+ import { default as Octahedron } from './Octahedron.vue';
10
+ import { default as Plane } from './Plane.vue';
11
+ import { default as Ring } from './Ring.vue';
12
+ import { default as RoundedBox } from './RoundedBox.vue';
13
+ import { default as Sphere } from './Sphere.vue';
14
+ import { default as Superformula } from './Superformula.vue';
15
+ import { default as Tetrahedron } from './Tetrahedron.vue';
16
+ import { default as Torus } from './Torus.vue';
17
+ import { default as TorusKnot } from './TorusKnot.vue';
18
+ import { default as Tube } from './Tube.vue';
19
+
20
+ export { Box, CatmullRomCurve3, Circle, Cone, Cylinder, Dodecahedron, Icosahedron, Line2, Octahedron, Plane, Ring, RoundedBox, Sphere, Superformula, Tetrahedron, Torus, TorusKnot, Tube, };
@@ -3,11 +3,16 @@ export interface BackdropProps {
3
3
  segments?: number;
4
4
  receiveShadow?: boolean;
5
5
  }
6
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<BackdropProps>, {
6
+ declare function __VLS_template(): {
7
+ default?(_: {}): any;
8
+ };
9
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<BackdropProps>, {
7
10
  floor: number;
8
11
  segments: number;
9
12
  receiveShadow: boolean;
10
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<BackdropProps>, {
13
+ }>, {
14
+ instance: import('vue').ShallowRef<any>;
15
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<BackdropProps>, {
11
16
  floor: number;
12
17
  segments: number;
13
18
  receiveShadow: boolean;
@@ -15,9 +20,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
15
20
  receiveShadow: boolean;
16
21
  floor: number;
17
22
  segments: number;
18
- }, {}>, {
19
- default?(_: {}): any;
20
- }>;
23
+ }, {}>;
24
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
21
25
  export default _default;
22
26
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
23
27
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -0,0 +1,173 @@
1
+ import { TresColor } from '@tresjs/core';
2
+
3
+ export interface ContactShadowsProps {
4
+ /**
5
+ *
6
+ * The opacity of the shadows.
7
+ *
8
+ * @default 1
9
+ * @type {number}
10
+ * @memberof ContactShadowsProps
11
+ *
12
+ */
13
+ opacity?: number;
14
+ /**
15
+ * The width of the shadows.
16
+ *
17
+ * @default 1
18
+ * @type {number}
19
+ * @memberof ContactShadowsProps
20
+ *
21
+ */
22
+ width?: number;
23
+ /**
24
+ * The height of the shadows.
25
+ *
26
+ * @default 1
27
+ * @type {number}
28
+ * @memberof ContactShadowsProps
29
+ *
30
+ */
31
+ height?: number;
32
+ /**
33
+ * The blur of the shadows.
34
+ *
35
+ * @default 1
36
+ * @type {number}
37
+ * @memberof ContactShadowsProps
38
+ *
39
+ */
40
+ blur?: number;
41
+ /**
42
+ * How far the OrthographicCamera should be to capture the shadows.
43
+ *
44
+ * @default 10
45
+ * @type {number}
46
+ * @memberof ContactShadowsProps
47
+ *
48
+ */
49
+ far?: number;
50
+ /**
51
+ * Whether the shadows should be smooth or not.
52
+ *
53
+ * @default true
54
+ * @type {boolean}
55
+ * @memberof ContactShadowsProps
56
+ *
57
+ */
58
+ smooth?: boolean;
59
+ /**
60
+ * The resolution of the shadows.
61
+ *
62
+ * @default 512
63
+ * @type {number}
64
+ * @memberof ContactShadowsProps
65
+ *
66
+ */
67
+ resolution?: number;
68
+ /**
69
+ * The number of frames to render the shadows.
70
+ *
71
+ * @default Infinity
72
+ * @type {number}
73
+ * @memberof ContactShadowsProps
74
+ *
75
+ */
76
+ frames?: number;
77
+ /**
78
+ * The scale of the shadows.
79
+ *
80
+ * @default 10
81
+ * @type {(number | [x: number, y: number])}
82
+ * @memberof ContactShadowsProps
83
+ *
84
+ */
85
+ scale?: number | [x: number, y: number];
86
+ /**
87
+ * The color of the shadows.
88
+ *
89
+ * @default '#000000'
90
+ * @type {TresColor}
91
+ * @memberof ContactShadowsProps
92
+ *
93
+ */
94
+ color?: TresColor;
95
+ /**
96
+ * Whether the shadows should write to the depth buffer or not.
97
+ *
98
+ * @default false
99
+ * @type {boolean}
100
+ * @memberof ContactShadowsProps
101
+ *
102
+ */
103
+ depthWrite?: boolean;
104
+ /**
105
+ * Whether the OrthographicCamera helper should be visible or not.
106
+ *
107
+ * @default false
108
+ * @type {boolean}
109
+ * @memberof ContactShadowsProps
110
+ *
111
+ */
112
+ helper?: boolean;
113
+ }
114
+ declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ContactShadowsProps>, {
115
+ scale: number;
116
+ frames: number;
117
+ opacity: number;
118
+ width: number;
119
+ height: number;
120
+ blur: number;
121
+ far: number;
122
+ resolution: number;
123
+ smooth: boolean;
124
+ color: string;
125
+ depthWrite: boolean;
126
+ helper: boolean;
127
+ }>, {
128
+ instance: import('vue').ShallowRef<any>;
129
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ContactShadowsProps>, {
130
+ scale: number;
131
+ frames: number;
132
+ opacity: number;
133
+ width: number;
134
+ height: number;
135
+ blur: number;
136
+ far: number;
137
+ resolution: number;
138
+ smooth: boolean;
139
+ color: string;
140
+ depthWrite: boolean;
141
+ helper: boolean;
142
+ }>>>, {
143
+ color: TresColor;
144
+ scale: number | [x: number, y: number];
145
+ width: number;
146
+ height: number;
147
+ helper: boolean;
148
+ depthWrite: boolean;
149
+ opacity: number;
150
+ blur: number;
151
+ resolution: number;
152
+ far: number;
153
+ smooth: boolean;
154
+ frames: number;
155
+ }, {}>;
156
+ export default _default;
157
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
158
+ type __VLS_TypePropsToRuntimeProps<T> = {
159
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
160
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
161
+ } : {
162
+ type: import('vue').PropType<T[K]>;
163
+ required: true;
164
+ };
165
+ };
166
+ type __VLS_WithDefaults<P, D> = {
167
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
168
+ default: D[K];
169
+ }> : P[K];
170
+ };
171
+ type __VLS_Prettify<T> = {
172
+ [K in keyof T]: T[K];
173
+ } & {};
@@ -0,0 +1,59 @@
1
+ import { Object3D, Box3, Vector3 } from 'three';
2
+
3
+ export interface Props {
4
+ /**
5
+ * If `into` is:
6
+ * - omitted or explicitly `undefined`: position/scale children to fit into a 1 × 1 × 1 `Box3` at world origin.
7
+ * - `null`: turn off `<Fit />`; reset scale/position of children.
8
+ * - `number`: convert argument to `Vector3(number, number, number)`.
9
+ * - `[number, number, number]`: convert argument to `Vector3`.
10
+ * - `Vector3`: position/scale children to fit inside a `Box3` of size `Vector3` at target objects' cumulative center.
11
+ * - `Box3`: position/scale children to fit inside `Box3`.
12
+ * - `Object3D`: position/scale children to fit inside calculated `Box3`. [See `THREE.Box3.setFromObject`](https://threejs.org/docs/#api/en/math/Box3.setFromObject). `<Fit />` must not contain the `Object3D` and vice-versa.
13
+ */
14
+ into?: number | [number, number, number] | Vector3 | Box3 | Object3D | null;
15
+ /** [See `precise` argument in `THREE.Box3.setFromObject`](https://threejs.org/docs/index.html?q=box3#api/en/math/Box3.setFromObject) */
16
+ precise?: boolean;
17
+ }
18
+ declare const props: Props;
19
+ declare function __VLS_template(): {
20
+ default?(_: {}): any;
21
+ };
22
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<Props>, {
23
+ into: () => Box3;
24
+ precise: boolean;
25
+ }>, {
26
+ instance: import('vue').ShallowRef<any>;
27
+ fit: (into?: typeof props.into, precise?: boolean) => void;
28
+ update: () => void;
29
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<Props>, {
30
+ into: () => Box3;
31
+ precise: boolean;
32
+ }>>>, {
33
+ into: number | [number, number, number] | Vector3 | Box3 | Object3D | null;
34
+ precise: boolean;
35
+ }, {}>;
36
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
37
+ export default _default;
38
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
39
+ type __VLS_TypePropsToRuntimeProps<T> = {
40
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
41
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
42
+ } : {
43
+ type: import('vue').PropType<T[K]>;
44
+ required: true;
45
+ };
46
+ };
47
+ type __VLS_WithDefaults<P, D> = {
48
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
49
+ default: D[K];
50
+ }> : P[K];
51
+ };
52
+ type __VLS_Prettify<T> = {
53
+ [K in keyof T]: T[K];
54
+ } & {};
55
+ type __VLS_WithTemplateSlots<T, S> = T & {
56
+ new (): {
57
+ $slots: S;
58
+ };
59
+ };
@@ -1,5 +1,6 @@
1
- import type { TresColor, TresVector3 } from '@tresjs/core';
1
+ import { TresColor, TresVector3 } from '@tresjs/core';
2
2
  import { Vector3 } from 'three';
3
+
3
4
  export interface OceanProps {
4
5
  /**
5
6
  * The textureWidth of the internal WebGLRenderTarget.
@@ -53,7 +54,7 @@ export interface OceanProps {
53
54
  */
54
55
  waterColor?: TresColor;
55
56
  /**
56
- * The distortion scale of the reflections.
57
+ * The distortion scale of the reflections.
57
58
  * @default 3.7
58
59
  * @type {number}
59
60
  * @memberof OceanProps
@@ -97,7 +98,10 @@ export interface OceanProps {
97
98
  */
98
99
  side?: TresVector3;
99
100
  }
100
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<OceanProps>, {
101
+ declare function __VLS_template(): {
102
+ default?(_: {}): any;
103
+ };
104
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<OceanProps>, {
101
105
  textureWidth: number;
102
106
  textureHeight: number;
103
107
  waterNormals: string;
@@ -110,8 +114,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
110
114
  alpha: number;
111
115
  side: 0;
112
116
  }>, {
113
- root: import("vue").ShallowRef<any>;
114
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<OceanProps>, {
117
+ instance: import('vue').ShallowRef<any>;
118
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<OceanProps>, {
115
119
  textureWidth: number;
116
120
  textureHeight: number;
117
121
  waterNormals: string;
@@ -124,20 +128,19 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
124
128
  alpha: number;
125
129
  side: 0;
126
130
  }>>>, {
127
- side: number | Vector3 | import("@tresjs/core").VectorCoordinates | [x: number, y: number, z: number];
131
+ side: TresVector3;
128
132
  textureWidth: number;
129
133
  textureHeight: number;
130
134
  clipBias: number;
131
135
  size: number;
132
136
  waterNormals: string;
133
- sunDirection: number | Vector3 | import("@tresjs/core").VectorCoordinates | [x: number, y: number, z: number];
134
- sunColor: import("three").ColorRepresentation | [r: number, g: number, b: number];
135
- waterColor: import("three").ColorRepresentation | [r: number, g: number, b: number];
137
+ sunDirection: TresVector3;
138
+ sunColor: TresColor;
139
+ waterColor: TresColor;
136
140
  distortionScale: number;
137
141
  alpha: number;
138
- }, {}>, {
139
- default?(_: {}): any;
140
- }>;
142
+ }, {}>;
143
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
141
144
  export default _default;
142
145
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
143
146
  type __VLS_TypePropsToRuntimeProps<T> = {
@@ -1,4 +1,5 @@
1
- import type { TresColor } from '@tresjs/core';
1
+ import { TresColor } from '@tresjs/core';
2
+
2
3
  export interface PrecipitationProps {
3
4
  /**
4
5
  * The size of the drops.
@@ -108,7 +109,7 @@ export interface PrecipitationProps {
108
109
  */
109
110
  sizeAttenuation?: boolean;
110
111
  }
111
- declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<PrecipitationProps>, {
112
+ declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<PrecipitationProps>, {
112
113
  size: number;
113
114
  area: () => number[];
114
115
  color: number;
@@ -120,7 +121,9 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
120
121
  depthWrite: boolean;
121
122
  transparent: boolean;
122
123
  sizeAttenuation: boolean;
123
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<PrecipitationProps>, {
124
+ }>, {
125
+ instance: import('vue').ShallowRef<any>;
126
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<PrecipitationProps>, {
124
127
  size: number;
125
128
  area: () => number[];
126
129
  color: number;
@@ -134,16 +137,16 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
134
137
  sizeAttenuation: boolean;
135
138
  }>>>, {
136
139
  speed: number;
137
- color: import("three").ColorRepresentation | [r: number, g: number, b: number];
138
- alphaTest: number;
140
+ color: TresColor;
139
141
  depthWrite: boolean;
140
142
  opacity: number;
141
143
  transparent: boolean;
142
- count: number;
144
+ alphaTest: number;
143
145
  size: number;
146
+ sizeAttenuation: boolean;
147
+ count: number;
144
148
  area: [number, number, number];
145
149
  randomness: number;
146
- sizeAttenuation: boolean;
147
150
  }, {}>;
148
151
  export default _default;
149
152
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
@@ -1,5 +1,6 @@
1
1
  import { Vector3 } from 'three';
2
- import { Sky as SkyImpl } from 'three/examples/jsm/objects/Sky';
2
+ import { Sky as SkyImpl } from 'three-stdlib';
3
+
3
4
  export interface SkyProps {
4
5
  /**
5
6
  * Haziness
@@ -31,7 +32,7 @@ export interface SkyProps {
31
32
  */
32
33
  distance?: number;
33
34
  }
34
- declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SkyProps>, {
35
+ declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SkyProps>, {
35
36
  turbidity: number;
36
37
  rayleigh: number;
37
38
  mieCoefficient: number;
@@ -40,9 +41,9 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
40
41
  azimuth: number;
41
42
  distance: number;
42
43
  }>, {
43
- root: import("vue").ShallowRef<SkyImpl | undefined>;
44
+ instance: import('vue').ShallowRef<SkyImpl | undefined>;
44
45
  sunPosition: Vector3;
45
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SkyProps>, {
46
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SkyProps>, {
46
47
  turbidity: number;
47
48
  rayleigh: number;
48
49
  mieCoefficient: number;
@@ -1,4 +1,5 @@
1
- import type { TresColor } from '@tresjs/core';
1
+ import { TresColor } from '@tresjs/core';
2
+
2
3
  export interface SmokeProps {
3
4
  /**
4
5
  * The color of the smoke.
@@ -65,7 +66,7 @@ export interface SmokeProps {
65
66
  */
66
67
  depthTest?: boolean;
67
68
  }
68
- declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SmokeProps>, {
69
+ declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SmokeProps>, {
69
70
  opacity: number;
70
71
  speed: number;
71
72
  width: number;
@@ -75,8 +76,8 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
75
76
  color: string;
76
77
  depthTest: boolean;
77
78
  }>, {
78
- value: import("vue").ShallowRef<any>;
79
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SmokeProps>, {
79
+ instance: import('vue').ShallowRef<any>;
80
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<SmokeProps>, {
80
81
  opacity: number;
81
82
  speed: number;
82
83
  width: number;
@@ -87,11 +88,11 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
87
88
  depthTest: boolean;
88
89
  }>>>, {
89
90
  speed: number;
90
- color: import("three").ColorRepresentation | [r: number, g: number, b: number];
91
+ color: TresColor;
91
92
  texture: string;
93
+ width: number;
92
94
  depthTest: boolean;
93
95
  opacity: number;
94
- width: number;
95
96
  depth: number;
96
97
  segments: number;
97
98
  }, {}>;
@@ -1,13 +1,14 @@
1
1
  import { DataTexture } from 'three';
2
- import type { Ref, MaybeRef } from 'vue';
3
- import type { GradientTresColor, GradientScalar, GradientVectorFlexibleParams } from './../../../utils/Gradient';
2
+ import { MaybeRef, Ref } from 'vue';
3
+ import { GradientScalar, GradientTresColor, GradientVectorFlexibleParams } from './../../../utils/Gradient';
4
+
4
5
  export type CanvasGradientRenderer<T> = (g: CanvasGradient, entry: ShaderDataEntry<T>) => void;
5
6
  export declare class ShaderData {
6
7
  private entries;
7
8
  private resolution;
8
9
  constructor(entries: ShaderDataEntry<any>[], resolution: number);
9
10
  useTexture(): {
10
- texture: import("vue").ShallowRef<DataTexture>;
11
+ texture: import('vue').ShallowRef<DataTexture>;
11
12
  dispose: () => void;
12
13
  yFor: Record<string, number>;
13
14
  };
@@ -1,10 +1,10 @@
1
- import type { MaybeRef } from 'vue';
2
- import type { GradientTresColor, GradientScalar, GradientVectorFlexibleParams } from './../../../utils/Gradient';
3
- import type { ShaderDataEntry, CanvasGradientRenderer } from './ShaderData';
4
- import { ShaderData } from './ShaderData';
5
- declare const rgbaSuffixes: readonly ["r", "rg", "rgb", "rgba"];
6
- declare const xyzwSuffixes: readonly ["x", "xy", "xyz", "xyzw"];
7
- type ShaderSuffix = (typeof rgbaSuffixes)[number] | (typeof xyzwSuffixes)[number];
1
+ import { MaybeRef } from 'vue';
2
+ import { GradientScalar, GradientTresColor, GradientVectorFlexibleParams } from './../../../utils/Gradient';
3
+ import { CanvasGradientRenderer, ShaderDataEntry, ShaderData } from './ShaderData';
4
+
5
+ type rgbaSuffixes = ['r', 'rg', 'rgb', 'rgba'];
6
+ type xyzwSuffixes = ['x', 'xy', 'xyz', 'xyzw'];
7
+ type ShaderSuffix = (rgbaSuffixes)[number] | (xyzwSuffixes)[number];
8
8
  export default class ShaderDataBuilder {
9
9
  private entries;
10
10
  private resolution;