@tresjs/cientos 5.4.0 → 5.5.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 +1 -17
- package/dist/trescientos.d.ts +2602 -2602
- package/dist/trescientos.js +7 -5
- package/package.json +7 -6
package/dist/trescientos.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* name: @tresjs/cientos
|
|
3
|
-
* version: v5.
|
|
3
|
+
* version: v5.5.0
|
|
4
4
|
* (c) 2026
|
|
5
5
|
* description: Collection of useful helpers and fully functional, ready-made abstractions for Tres
|
|
6
6
|
* author: Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
import { Fragment, Suspense, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createVNode, defineComponent, inject, isReactive, isRef, mergeDefaults, mergeProps, nextTick, normalizeProps, onBeforeUnmount, onMounted, onUnmounted, openBlock, provide, reactive, ref, render, renderList, renderSlot, shallowReactive, shallowRef, toRaw, toRefs, toValue, triggerRef, unref, useAttrs, useSlots, watch, watchEffect, withAsyncContext, withCtx } from "vue";
|
|
9
9
|
import { buildGraph, extend, isObject3D, logError, logWarning, normalizeColor, normalizeVectorFlexibleParam, useLoader, useLoop, useTres, useTresContext } from "@tresjs/core";
|
|
10
10
|
import * as THREE from "three";
|
|
11
|
-
import { AdditiveBlending, AlwaysStencilFunc, AnimationMixer, Audio, AudioListener, AudioLoader, BackSide, Box2, Box3, BoxGeometry, BufferAttribute, BufferGeometry, Camera, CatmullRomCurve3, ClampToEdgeWrapping,
|
|
11
|
+
import { AdditiveBlending, AlwaysStencilFunc, AnimationMixer, Audio, AudioListener, AudioLoader, BackSide, Box2, Box3, BoxGeometry, BufferAttribute, BufferGeometry, Camera, CatmullRomCurve3, ClampToEdgeWrapping, Color, CubeCamera, CubeReflectionMapping, CubeTextureLoader, CubicBezierCurve3, DataTexture, DefaultLoadingManager, DepthTexture, DirectionalLight, DoubleSide, EdgesGeometry, EqualStencilFunc, EquirectangularReflectionMapping, Euler, FloatType, FramebufferTexture, FrontSide, Group, HalfFloatType, IcosahedronGeometry, InstancedMesh, InterleavedBuffer, InterleavedBufferAttribute, KeepStencilOp, LOD, LinearFilter, MOUSE, MathUtils, Matrix4, Mesh, MeshBasicMaterial, MeshDepthMaterial, MeshLambertMaterial, MeshStandardMaterial, NearestFilter, NoBlending, NotEqualStencilFunc, Object3D, OrthographicCamera, PerspectiveCamera, Plane, PlaneGeometry, Points, PointsMaterial, QuadraticBezierCurve3, Quaternion, REVISION, RGBAFormat, RawShaderMaterial, Raycaster, RepeatWrapping, ReplaceStencilOp, Scene, ShaderChunk, ShaderMaterial, ShapeGeometry, SkinnedMesh, Sphere, Spherical, TOUCH, TangentSpaceNormalMap, Texture, TextureLoader, Timer, UVMapping, Uniform, UniformsUtils, UnsignedByteType, Vector2, Vector3, Vector4, VideoTexture, WebGLCubeRenderTarget, WebGLRenderTarget, WebGLRenderer } from "three";
|
|
12
12
|
import { tryOnScopeDispose, useDebounceFn, useElementSize, useEventListener, useMagicKeys, useMouse, useScroll, useWindowScroll, useWindowSize, watchThrottled, whenever } from "@vueuse/core";
|
|
13
13
|
import { DRACOLoader, FBXLoader, FontLoader, GLTFExporter, GLTFLoader, HorizontalBlurShader, Line2, LineGeometry, LineMaterial, MapControls, MarchingCubes, MeshSurfaceSampler, OrbitControls, PointerLockControls, PositionalAudioHelper, RGBELoader, Reflector, RoundedBoxGeometry, SVGLoader, SimplexNoise, Sky, TextGeometry, TransformControls, VerticalBlurShader, Water, toCreasedNormals } from "three-stdlib";
|
|
14
14
|
import BaseCameraControls, { default as CameraControls } from "camera-controls";
|
|
@@ -5417,7 +5417,8 @@ var HolographicMaterial = class extends ShaderMaterial {
|
|
|
5417
5417
|
blinkFresnelOnly: new Uniform(parameters.blinkFresnelOnly !== void 0 ? parameters.blinkFresnelOnly : true),
|
|
5418
5418
|
hologramOpacity: new Uniform(parameters.hologramOpacity !== void 0 ? parameters.hologramOpacity : 1)
|
|
5419
5419
|
};
|
|
5420
|
-
this.clock = new
|
|
5420
|
+
this.clock = new Timer();
|
|
5421
|
+
if (typeof document !== "undefined") this.clock.connect(document);
|
|
5421
5422
|
this.setValues(parameters);
|
|
5422
5423
|
this.depthTest = parameters.depthTest !== void 0 ? parameters.depthTest : false;
|
|
5423
5424
|
this.blending = parameters.blendMode !== void 0 ? parameters.blendMode : AdditiveBlending;
|
|
@@ -5425,7 +5426,8 @@ var HolographicMaterial = class extends ShaderMaterial {
|
|
|
5425
5426
|
this.side = parameters.side !== void 0 ? parameters.side : FrontSide;
|
|
5426
5427
|
}
|
|
5427
5428
|
update() {
|
|
5428
|
-
this.
|
|
5429
|
+
this.clock.update();
|
|
5430
|
+
this.uniforms.time.value = this.clock.getElapsed();
|
|
5429
5431
|
}
|
|
5430
5432
|
};
|
|
5431
5433
|
var HolographicMaterialParameters_default = HolographicMaterial;
|
|
@@ -7494,7 +7496,7 @@ const useBVH = (target, { enabled = true, firstHitOnly = false, splitStrategy =
|
|
|
7494
7496
|
whenever(() => toValue(target), () => {
|
|
7495
7497
|
const objectValue = toValue(target);
|
|
7496
7498
|
if (objectValue && toValue(enabled)) applyBVH(objectValue);
|
|
7497
|
-
});
|
|
7499
|
+
}, { immediate: true });
|
|
7498
7500
|
watch(() => toValue(enabled), (enabled$1) => {
|
|
7499
7501
|
if (enabled$1) {
|
|
7500
7502
|
const objectValue = toValue(target);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tresjs/cientos",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "5.
|
|
4
|
+
"version": "5.5.0",
|
|
5
5
|
"description": "Collection of useful helpers and fully functional, ready-made abstractions for Tres",
|
|
6
6
|
"author": "Alvaro Saburido <hola@alvarosaburido.dev> (https://github.com/alvarosabu/)",
|
|
7
7
|
"license": "MIT",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"access": "public"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
|
41
|
-
"@tresjs/core": "5.
|
|
41
|
+
"@tresjs/core": "5.6.0",
|
|
42
42
|
"three": ">=0.133",
|
|
43
43
|
"vue": ">=3.5.17"
|
|
44
44
|
},
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
55
|
"@types/node": "^24.5.2",
|
|
56
|
-
"@types/three": "^0.
|
|
56
|
+
"@types/three": "^0.183.0",
|
|
57
57
|
"@typescript-eslint/eslint-plugin": "^8.42.0",
|
|
58
58
|
"@typescript-eslint/parser": "^8.42.0",
|
|
59
59
|
"@vitejs/plugin-vue": "^6.0.1",
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"pathe": "^2.0.3",
|
|
64
64
|
"rollup-plugin-analyzer": "^4.0.0",
|
|
65
65
|
"rollup-plugin-visualizer": "^6.0.3",
|
|
66
|
-
"three": "^0.
|
|
66
|
+
"three": "^0.183.0",
|
|
67
67
|
"tsdown": "0.18.3",
|
|
68
68
|
"typescript": "^5.8.3",
|
|
69
69
|
"vite": "^7.1.9",
|
|
@@ -72,8 +72,8 @@
|
|
|
72
72
|
"vite-plugin-glsl": "^1.5.1",
|
|
73
73
|
"vite-svg-loader": "^5.1.0",
|
|
74
74
|
"vue-tsc": "^3.2.1",
|
|
75
|
-
"@tresjs/
|
|
76
|
-
"@tresjs/
|
|
75
|
+
"@tresjs/core": "5.6.0",
|
|
76
|
+
"@tresjs/eslint-config": "1.5.1"
|
|
77
77
|
},
|
|
78
78
|
"nx": {
|
|
79
79
|
"implicitDependencies": [
|
|
@@ -83,6 +83,7 @@
|
|
|
83
83
|
"scripts": {
|
|
84
84
|
"dev": "cd playground/vue && pnpm dev",
|
|
85
85
|
"build": "tsdown",
|
|
86
|
+
"build:analyze": "ANALYZE=true tsdown",
|
|
86
87
|
"lint": "eslint .",
|
|
87
88
|
"typecheck": "vue-tsc --noEmit",
|
|
88
89
|
"lint:fix": "eslint . --fix"
|