@tresjs/cientos 0.2.0 → 0.4.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/dist/core/OrbitControls.vue.d.ts +8 -4
- package/dist/core/useGLTF/component.d.ts +9 -0
- package/dist/core/useGLTF/index.d.ts +16 -0
- package/dist/index.d.ts +3 -1
- package/dist/trescientos.js +6294 -4580
- package/dist/trescientos.umd.cjs +11 -5
- package/package.json +3 -3
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { useRenderLoop } from '@tresjs/core';
|
|
2
|
+
import { Camera, WebGLRenderer } from 'three';
|
|
2
3
|
import { OrbitControls as OrbitControlsImp } from 'three-stdlib';
|
|
3
|
-
import { inject, unref, watch } from 'vue';
|
|
4
|
+
import { inject, type Ref, unref, watch } from 'vue';
|
|
4
5
|
declare const _sfc_main: import("vue").DefineComponent<{}, {
|
|
5
6
|
controls: OrbitControlsImp;
|
|
6
|
-
|
|
7
|
-
|
|
7
|
+
camera: Ref<Camera> | undefined;
|
|
8
|
+
renderer: Ref<WebGLRenderer> | undefined;
|
|
9
|
+
readonly useRenderLoop: typeof useRenderLoop;
|
|
10
|
+
readonly Camera: typeof Camera;
|
|
11
|
+
readonly WebGLRenderer: typeof WebGLRenderer;
|
|
8
12
|
readonly OrbitControlsImp: typeof OrbitControlsImp;
|
|
9
13
|
inject: typeof inject;
|
|
10
14
|
unref: typeof unref;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const GLTFModel: import("vue").DefineComponent<{
|
|
2
|
+
path: StringConstructor;
|
|
3
|
+
draco: BooleanConstructor;
|
|
4
|
+
}, () => null, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
5
|
+
path: StringConstructor;
|
|
6
|
+
draco: BooleanConstructor;
|
|
7
|
+
}>>, {
|
|
8
|
+
draco: boolean;
|
|
9
|
+
}>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { GLTFLoader } from 'three-stdlib';
|
|
2
|
+
import { Object3D } from 'three';
|
|
3
|
+
export interface GLTFLoaderOptions {
|
|
4
|
+
draco?: boolean;
|
|
5
|
+
decoderPath?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface TresObject extends Object3D {
|
|
8
|
+
geometry: THREE.BufferGeometry;
|
|
9
|
+
material: THREE.Material;
|
|
10
|
+
}
|
|
11
|
+
export interface GLTFResult {
|
|
12
|
+
nodes: Array<TresObject>;
|
|
13
|
+
materials: Array<THREE.Material>;
|
|
14
|
+
scene: THREE.Scene;
|
|
15
|
+
}
|
|
16
|
+
export declare function useGLTF(path: string | string[], options?: GLTFLoaderOptions, extendLoader?: (loader: GLTFLoader) => void): Promise<GLTFResult>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import OrbitControls from './core/OrbitControls.vue';
|
|
2
2
|
import { useTweakPane } from './core/useTweakPane';
|
|
3
|
-
|
|
3
|
+
import { GLTFModel } from './core/useGLTF/component';
|
|
4
|
+
export * from './core/useGLTF';
|
|
5
|
+
export { OrbitControls, useTweakPane, GLTFModel };
|