@pixiv/three-vrm-core 1.0.0-beta.9 → 1.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/lib/three-vrm-core.js +3367 -2551
- package/lib/three-vrm-core.min.js +2 -2
- package/lib/three-vrm-core.module.js +3365 -2552
- package/lib/three-vrm-core.module.min.js +2 -2
- package/package.json +12 -12
- package/ts3.4/types/VRMCore.d.ts +7 -7
- package/ts3.4/types/VRMCoreLoaderPluginOptions.d.ts +1 -0
- package/ts3.4/types/VRMCoreParameters.d.ts +2 -2
- package/ts3.4/types/expressions/VRMExpression.d.ts +1 -1
- package/ts3.4/types/expressions/VRMExpressionMaterialColorBind.d.ts +3 -0
- package/ts3.4/types/expressions/VRMExpressionMaterialColorType.d.ts +4 -0
- package/ts3.4/types/humanoid/VRMHumanBoneList.d.ts +5 -0
- package/ts3.4/types/humanoid/VRMHumanBoneName.d.ts +7 -2
- package/ts3.4/types/humanoid/VRMHumanBoneParentMap.d.ts +9 -0
- package/ts3.4/types/humanoid/VRMHumanoid.d.ts +130 -21
- package/ts3.4/types/humanoid/VRMHumanoidLoaderPlugin.d.ts +9 -1
- package/ts3.4/types/humanoid/VRMHumanoidLoaderPluginOptions.d.ts +15 -0
- package/ts3.4/types/humanoid/VRMHumanoidRig.d.ts +31 -0
- package/ts3.4/types/humanoid/VRMRig.d.ts +62 -0
- package/ts3.4/types/humanoid/helpers/VRMHumanoidHelper.d.ts +9 -0
- package/ts3.4/types/humanoid/helpers/index.d.ts +1 -0
- package/ts3.4/types/humanoid/index.d.ts +4 -0
- package/ts3.4/types/lookAt/VRMLookAt.d.ts +48 -6
- package/ts3.4/types/lookAt/VRMLookAtApplier.d.ts +8 -2
- package/ts3.4/types/lookAt/VRMLookAtBoneApplier.d.ts +35 -2
- package/ts3.4/types/lookAt/VRMLookAtExpressionApplier.d.ts +7 -2
- package/ts3.4/types/lookAt/tests/VRMLookAt.test.d.ts +1 -0
- package/ts3.4/types/lookAt/tests/VRMLookAtBoneApplier.test.d.ts +1 -0
- package/ts3.4/types/lookAt/utils/calcAzimuthAltitude.d.ts +16 -0
- package/ts3.4/types/lookAt/utils/sanitizeAngle.d.ts +11 -0
- package/ts3.4/types/lookAt/utils/tests/calcAzimuthAltitude.test.d.ts +1 -0
- package/ts3.4/types/lookAt/utils/tests/sanitizeAngle.test.d.ts +1 -0
- package/ts3.4/types/meta/VRMMetaLoaderPlugin.d.ts +1 -1
- package/ts3.4/types/meta/VRMMetaLoaderPluginOptions.d.ts +1 -1
- package/ts3.4/types/tests/matchers/toBeCloseToQuaternion.d.ts +10 -0
- package/ts3.4/types/tests/matchers/toBeCloseToVector3.d.ts +10 -0
- package/ts3.4/types/utils/renameMaterialProperty.d.ts +1 -0
- package/types/VRMCore.d.ts +58 -58
- package/types/VRMCoreLoaderPlugin.d.ts +18 -18
- package/types/VRMCoreLoaderPluginOptions.d.ts +19 -18
- package/types/VRMCoreParameters.d.ts +16 -16
- package/types/expressions/VRMExpression.d.ts +64 -64
- package/types/expressions/VRMExpressionBind.d.ts +11 -11
- package/types/expressions/VRMExpressionLoaderPlugin.d.ts +23 -23
- package/types/expressions/VRMExpressionManager.d.ts +124 -124
- package/types/expressions/VRMExpressionMaterialColorBind.d.ts +45 -42
- package/types/expressions/VRMExpressionMaterialColorType.d.ts +12 -8
- package/types/expressions/VRMExpressionMorphTargetBind.d.ts +35 -35
- package/types/expressions/VRMExpressionOverrideType.d.ts +6 -6
- package/types/expressions/VRMExpressionPresetName.d.ts +21 -21
- package/types/expressions/VRMExpressionTextureTransformBind.d.ts +40 -40
- package/types/expressions/index.d.ts +10 -10
- package/types/firstPerson/VRMFirstPerson.d.ts +84 -84
- package/types/firstPerson/VRMFirstPersonLoaderPlugin.d.ts +20 -20
- package/types/firstPerson/VRMFirstPersonMeshAnnotation.d.ts +5 -5
- package/types/firstPerson/VRMFirstPersonMeshAnnotationType.d.ts +7 -7
- package/types/firstPerson/index.d.ts +4 -4
- package/types/humanoid/VRMHumanBone.d.ts +10 -10
- package/types/humanoid/VRMHumanBoneList.d.ts +5 -0
- package/types/humanoid/VRMHumanBoneName.d.ts +63 -58
- package/types/humanoid/VRMHumanBoneParentMap.d.ts +9 -0
- package/types/humanoid/VRMHumanBones.d.ts +11 -11
- package/types/humanoid/VRMHumanoid.d.ts +182 -73
- package/types/humanoid/VRMHumanoidLoaderPlugin.d.ts +32 -24
- package/types/humanoid/VRMHumanoidLoaderPluginOptions.d.ts +15 -0
- package/types/humanoid/VRMHumanoidRig.d.ts +31 -0
- package/types/humanoid/VRMPose.d.ts +24 -24
- package/types/humanoid/VRMPoseTransform.d.ts +15 -15
- package/types/humanoid/VRMRequiredHumanBoneName.d.ts +18 -18
- package/types/humanoid/VRMRig.d.ts +62 -0
- package/types/humanoid/helpers/VRMHumanoidHelper.d.ts +9 -0
- package/types/humanoid/helpers/index.d.ts +1 -0
- package/types/humanoid/index.d.ts +12 -8
- package/types/index.d.ts +9 -9
- package/types/lookAt/VRMLookAt.d.ts +148 -104
- package/types/lookAt/VRMLookAtApplier.d.ts +18 -12
- package/types/lookAt/VRMLookAtBoneApplier.d.ts +83 -50
- package/types/lookAt/VRMLookAtExpressionApplier.d.ts +56 -51
- package/types/lookAt/VRMLookAtLoaderPlugin.d.ts +30 -30
- package/types/lookAt/VRMLookAtLoaderPluginOptions.d.ts +8 -8
- package/types/lookAt/VRMLookAtRangeMap.d.ts +23 -23
- package/types/lookAt/VRMLookAtTypeName.d.ts +8 -8
- package/types/lookAt/helpers/VRMLookAtHelper.d.ts +11 -11
- package/types/lookAt/helpers/index.d.ts +1 -1
- package/types/lookAt/helpers/utils/FanBufferGeometry.d.ts +13 -13
- package/types/lookAt/helpers/utils/LineAndSphereBufferGeometry.d.ts +13 -13
- package/types/lookAt/index.d.ts +8 -8
- package/types/lookAt/tests/VRMLookAt.test.d.ts +1 -0
- package/types/lookAt/tests/VRMLookAtBoneApplier.test.d.ts +1 -0
- package/types/lookAt/utils/calcAzimuthAltitude.d.ts +13 -0
- package/types/lookAt/utils/sanitizeAngle.d.ts +11 -0
- package/types/lookAt/utils/tests/calcAzimuthAltitude.test.d.ts +1 -0
- package/types/lookAt/utils/tests/sanitizeAngle.test.d.ts +1 -0
- package/types/meta/VRM0Meta.d.ts +62 -62
- package/types/meta/VRM1Meta.d.ts +86 -86
- package/types/meta/VRMMeta.d.ts +6 -6
- package/types/meta/VRMMetaLoaderPlugin.d.ts +32 -32
- package/types/meta/VRMMetaLoaderPluginOptions.d.ts +22 -22
- package/types/meta/index.d.ts +5 -5
- package/types/tests/matchers/toBeCloseToQuaternion.d.ts +10 -0
- package/types/tests/matchers/toBeCloseToVector3.d.ts +10 -0
- package/types/utils/getWorldQuaternionLite.d.ts +8 -8
- package/types/utils/gltfExtractPrimitivesFromNode.d.ts +21 -21
- package/types/utils/gltfGetAssociatedMaterialIndex.d.ts +10 -10
- package/types/utils/quatInvertCompat.d.ts +8 -8
- package/types/utils/renameMaterialProperty.d.ts +1 -0
- package/types/utils/resolveURL.d.ts +4 -4
- package/types/utils/saturate.d.ts +6 -6
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import type { GLTF } from 'three/examples/jsm/loaders/GLTFLoader.js';
|
|
2
|
-
/**
|
|
3
|
-
* Extract primitives ( `THREE.Mesh[]` ) of a node from a loaded GLTF.
|
|
4
|
-
* The main purpose of this function is to distinguish primitives and children from a node that has both meshes and children.
|
|
5
|
-
*
|
|
6
|
-
* It utilizes the behavior that GLTFLoader adds mesh primitives to the node object ( `THREE.Group` ) first then adds its children.
|
|
7
|
-
*
|
|
8
|
-
* @param gltf A GLTF object taken from GLTFLoader
|
|
9
|
-
* @param nodeIndex The index of the node
|
|
10
|
-
*/
|
|
11
|
-
export declare function gltfExtractPrimitivesFromNode(gltf: GLTF, nodeIndex: number): Promise<THREE.Mesh[] | null>;
|
|
12
|
-
/**
|
|
13
|
-
* Extract primitives ( `THREE.Mesh[]` ) of nodes from a loaded GLTF.
|
|
14
|
-
* See {@link gltfExtractPrimitivesFromNode} for more details.
|
|
15
|
-
*
|
|
16
|
-
* It returns a map from node index to extraction result.
|
|
17
|
-
* If a node does not have a mesh, the entry for the node will not be put in the returning map.
|
|
18
|
-
*
|
|
19
|
-
* @param gltf A GLTF object taken from GLTFLoader
|
|
20
|
-
*/
|
|
21
|
-
export declare function gltfExtractPrimitivesFromNodes(gltf: GLTF): Promise<Map<number, THREE.Mesh[]>>;
|
|
1
|
+
import type { GLTF } from 'three/examples/jsm/loaders/GLTFLoader.js';
|
|
2
|
+
/**
|
|
3
|
+
* Extract primitives ( `THREE.Mesh[]` ) of a node from a loaded GLTF.
|
|
4
|
+
* The main purpose of this function is to distinguish primitives and children from a node that has both meshes and children.
|
|
5
|
+
*
|
|
6
|
+
* It utilizes the behavior that GLTFLoader adds mesh primitives to the node object ( `THREE.Group` ) first then adds its children.
|
|
7
|
+
*
|
|
8
|
+
* @param gltf A GLTF object taken from GLTFLoader
|
|
9
|
+
* @param nodeIndex The index of the node
|
|
10
|
+
*/
|
|
11
|
+
export declare function gltfExtractPrimitivesFromNode(gltf: GLTF, nodeIndex: number): Promise<THREE.Mesh[] | null>;
|
|
12
|
+
/**
|
|
13
|
+
* Extract primitives ( `THREE.Mesh[]` ) of nodes from a loaded GLTF.
|
|
14
|
+
* See {@link gltfExtractPrimitivesFromNode} for more details.
|
|
15
|
+
*
|
|
16
|
+
* It returns a map from node index to extraction result.
|
|
17
|
+
* If a node does not have a mesh, the entry for the node will not be put in the returning map.
|
|
18
|
+
*
|
|
19
|
+
* @param gltf A GLTF object taken from GLTFLoader
|
|
20
|
+
*/
|
|
21
|
+
export declare function gltfExtractPrimitivesFromNodes(gltf: GLTF): Promise<Map<number, THREE.Mesh[]>>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as THREE from 'three';
|
|
2
|
-
import { GLTFParser } from 'three/examples/jsm/loaders/GLTFLoader.js';
|
|
3
|
-
/**
|
|
4
|
-
* Get a material definition index of glTF from associated material.
|
|
5
|
-
* It's basically a comat code between Three.js r133 or above and previous versions.
|
|
6
|
-
* @param parser GLTFParser
|
|
7
|
-
* @param material A material of gltf
|
|
8
|
-
* @returns Material definition index of glTF
|
|
9
|
-
*/
|
|
10
|
-
export declare function gltfGetAssociatedMaterialIndex(parser: GLTFParser, material: THREE.Material): number | null;
|
|
1
|
+
import * as THREE from 'three';
|
|
2
|
+
import { GLTFParser } from 'three/examples/jsm/loaders/GLTFLoader.js';
|
|
3
|
+
/**
|
|
4
|
+
* Get a material definition index of glTF from associated material.
|
|
5
|
+
* It's basically a comat code between Three.js r133 or above and previous versions.
|
|
6
|
+
* @param parser GLTFParser
|
|
7
|
+
* @param material A material of gltf
|
|
8
|
+
* @returns Material definition index of glTF
|
|
9
|
+
*/
|
|
10
|
+
export declare function gltfGetAssociatedMaterialIndex(parser: GLTFParser, material: THREE.Material): number | null;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as THREE from 'three';
|
|
2
|
-
/**
|
|
3
|
-
* A compat function for `Quaternion.invert()` / `Quaternion.inverse()`.
|
|
4
|
-
* `Quaternion.invert()` is introduced in r123 and `Quaternion.inverse()` emits a warning.
|
|
5
|
-
* We are going to use this compat for a while.
|
|
6
|
-
* @param target A target quaternion
|
|
7
|
-
*/
|
|
8
|
-
export declare function quatInvertCompat<T extends THREE.Quaternion>(target: T): T;
|
|
1
|
+
import * as THREE from 'three';
|
|
2
|
+
/**
|
|
3
|
+
* A compat function for `Quaternion.invert()` / `Quaternion.inverse()`.
|
|
4
|
+
* `Quaternion.invert()` is introduced in r123 and `Quaternion.inverse()` emits a warning.
|
|
5
|
+
* We are going to use this compat for a while.
|
|
6
|
+
* @param target A target quaternion
|
|
7
|
+
*/
|
|
8
|
+
export declare function quatInvertCompat<T extends THREE.Quaternion>(target: T): T;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function renameMaterialProperty(name: string): string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Yoinked from https://github.com/mrdoob/three.js/blob/master/examples/jsm/loaders/GLTFLoader.js
|
|
3
|
-
*/
|
|
4
|
-
export declare function resolveURL(url: string, path: string): string;
|
|
1
|
+
/**
|
|
2
|
+
* Yoinked from https://github.com/mrdoob/three.js/blob/master/examples/jsm/loaders/GLTFLoader.js
|
|
3
|
+
*/
|
|
4
|
+
export declare function resolveURL(url: string, path: string): string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Clamp the input value within [0.0 - 1.0].
|
|
3
|
-
*
|
|
4
|
-
* @param value The input value
|
|
5
|
-
*/
|
|
6
|
-
export declare function saturate(value: number): number;
|
|
1
|
+
/**
|
|
2
|
+
* Clamp the input value within [0.0 - 1.0].
|
|
3
|
+
*
|
|
4
|
+
* @param value The input value
|
|
5
|
+
*/
|
|
6
|
+
export declare function saturate(value: number): number;
|