diff --git a/examples/jsm/WebGL.d.ts b/examples/jsm/WebGL.d.ts deleted file mode 100644 index 1cad0510c4372f..00000000000000 --- a/examples/jsm/WebGL.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -export namespace WEBGL { - - export function isWebGLAvailable(): boolean; - export function isWebGL2Available(): boolean; - export function getWebGLErrorMessage(): HTMLElement; - export function getWebGL2ErrorMessage(): HTMLElement; - export function getErrorMessage( version: number ): HTMLElement; - -} diff --git a/examples/jsm/animation/AnimationClipCreator.d.ts b/examples/jsm/animation/AnimationClipCreator.d.ts deleted file mode 100644 index b0b9f9b89d27ee..00000000000000 --- a/examples/jsm/animation/AnimationClipCreator.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { - AnimationClip, - Vector3 -} from '../../../src/Three'; - -export class AnimationClipCreator { - - constructor(); - - static CreateRotationAnimation( period: number, axis: string ): AnimationClip; - static CreateScaleAxisAnimation( period: number, axis: string ): AnimationClip; - static CreateShakeAnimation( duration: number, shakeScale: Vector3 ): AnimationClip; - static CreatePulsationAnimation( duration: number, pulseScale: number ): AnimationClip; - static CreateVisibilityAnimation( duration: number ): AnimationClip; - static CreateMaterialColorAnimation( duration: number, colors: number[] ): AnimationClip; - -} diff --git a/examples/jsm/animation/CCDIKSolver.d.ts b/examples/jsm/animation/CCDIKSolver.d.ts deleted file mode 100644 index 26971a87901b14..00000000000000 --- a/examples/jsm/animation/CCDIKSolver.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { - SkinnedMesh, -} from '../../../src/Three'; - -export interface IKS { - effector: number; - iteration: number; - links: { - enabled: boolean; - index: number; - } - maxAngle: number; - target: number; -} - -export class CCDIKSolver { - - constructor( mesh: SkinnedMesh, iks: IKS[] ); - - update(): this; - createHelper(): CCDIKHelper; - -} - -export class CCDIKHelper { - - constructor( mesh: SkinnedMesh, iks: IKS[] ); - -} diff --git a/examples/jsm/animation/MMDAnimationHelper.d.ts b/examples/jsm/animation/MMDAnimationHelper.d.ts deleted file mode 100644 index f47fb245e28512..00000000000000 --- a/examples/jsm/animation/MMDAnimationHelper.d.ts +++ /dev/null @@ -1,91 +0,0 @@ -import { - AnimationClip, - Audio, - Camera, - Mesh, - Object3D, - SkinnedMesh -} from '../../../src/Three'; - -export interface MMDAnimationHelperParameter { - sync?: boolean; - afterglow?: number; - resetPhysicsOnLoop?: boolean; -} - -export interface MMDAnimationHelperAddParameter { - animation?: AnimationClip | AnimationClip[]; - physics?: boolean; - warmup?: number; - unitStep?: number; - maxStepNum?: number; - gravity?: number; - delayTime?: number; -} - -export interface MMDAnimationHelperPoseParameter { - resetPose?: boolean; - ik?: boolean; - grant?: boolean; -} - -export class MMDAnimationHelper { - - constructor( params?: MMDAnimationHelperParameter ); - meshes: Mesh[]; - camera: Camera | null; - cameraTarget: Object3D; - audio: Audio; - audioManager: AudioManager; - configuration: { - sync: boolean; - afterglow: number; - resetPhysicsOnLoop: boolean; - }; - enabled: { - animation: boolean; - ik: boolean; - grant: boolean; - physics: boolean; - cameraAnimation: boolean; - }; - onBeforePhysics: ( mesh: SkinnedMesh ) => void; - sharedPhysics: boolean; - masterPhysics: null; - - add( object: SkinnedMesh | Camera | Audio, params?: MMDAnimationHelperAddParameter ): this; - remove( object: SkinnedMesh | Camera | Audio ): this; - update( delta: number ): this; - pose( mesh: SkinnedMesh, vpd: object, params?: MMDAnimationHelperPoseParameter ): this; - enable( key: string, enabled: boolean ): this; - createGrantSolver( mesh: SkinnedMesh ): GrantSolver; - -} - -export interface AudioManagerParameter { - delayTime?: number; -} - -export class AudioManager { - - constructor( audio: Audio, params?: AudioManagerParameter ); - audio: Audio; - elapsedTime: number; - currentTime: number; - delayTime: number; - audioDuration: number; - duration: number; - - control( delta: number ): this; - -} - -export class GrantSolver { - - constructor( mesh: SkinnedMesh, grants: object[] ); - mesh: SkinnedMesh; - grants: object[]; - - update(): this; - -} diff --git a/examples/jsm/animation/MMDPhysics.d.ts b/examples/jsm/animation/MMDPhysics.d.ts deleted file mode 100644 index 1a6f3ff5cfec3c..00000000000000 --- a/examples/jsm/animation/MMDPhysics.d.ts +++ /dev/null @@ -1,118 +0,0 @@ -import { - Bone, - Euler, - Matrix4, - Object3D, - Quaternion, - SkinnedMesh, - Vector3 -} from '../../../src/Three'; - -export interface MMDPhysicsParameter { - unitStep?: number; - maxStepNum?: number; - gravity?: Vector3; -} - -export class MMDPhysics { - - constructor( mesh: SkinnedMesh, rigidBodyParams: object[], constraintParams?: object[], params?: MMDPhysicsParameter ); - manager: ResourceManager; - mesh: SkinnedMesh; - unitStep: number; - maxStepNum: number; - gravity: Vector3; - world: null; - bodies: RigidBody[]; - constraints: Constraint[]; - - update( delta: number ): this; - reset(): this; - warmup( cycles: number ): this; - setGravity( gravity: Vector3 ): this; - createHelper(): MMDPhysicsHelper; - -} - -export class ResourceManager { - - constructor(); - threeVector3s: Vector3[]; - threeMatrix4s: Matrix4[]; - threeQuaternions: Quaternion[]; - threeEulers: Euler[]; - transforms: object[]; - quaternions: object[]; - vector3s: object[]; - - allocThreeVector3(): void; - freeThreeVector3( v: Vector3 ): void; - allocThreeMatrix4(): void; - freeThreeMatrix4( m: Matrix4 ): void; - allocThreeQuaternion(): void; - freeThreeQuaternion( q: Quaternion ): void; - allocThreeEuler(): void; - freeThreeEuler( e: Euler ): void; - allocTransform(): void; - freeTransform( t: object ): void; - allocQuaternion(): void; - freeQuaternion( q: object ): void; - allocVector3(): void; - freeVector3( v: object ): void; - setIdentity(): void; - getBasis( t: object ): object; - getBasisAsMatrix3( t: object ): object; - getOrigin( t: object ): object; - setOrigin( t: object, v: object ): void; - copyOrigin( t1: object, t2: object ): void; - setBasis( t: object, q: object ): void; - setBasisFromMatrix3( t: object, m: object ): void; - setOriginFromArray3( t: object, a: number[] ): void; - setOriginFromThreeVector3( t: object, v: Vector3 ): void; - setBasisFromArray3( t: object, a: number[] ): void; - setBasisFromThreeQuaternion( t: object, a: Quaternion ): void; - multiplyTransforms( t1: object, t2: object ): object; - inverseTransform( t: object ): object; - multiplyMatrices3( m1: object, m2: object ): object; - addVector3( v1: object, v2: object ): object; - dotVectors3( v1: object, v2: object ): number; - rowOfMatrix3( m: object, i: number ): object; - columnOfMatrix3( m: object, i: number ): object; - negativeVector3( v: object ): object; - multiplyMatrix3ByVector3( m: object, v: object ): object; - transposeMatrix3( m: object ): object; - quaternionToMatrix3( q: object ): object; - matrix3ToQuaternion( m: object ): object; - -} - -export class RigidBody { - - constructor( mesh: SkinnedMesh, world: object, params: object, manager: ResourceManager ); - mesh: SkinnedMesh; - world: object; - params: object; - manager: ResourceManager; - - body: object; - bone: Bone; - boneOffsetForm: object; - boneOffsetFormInverse: object; - - reset(): this; - updateFromBone(): this; - updateBone(): this; - -} - -export class Constraint { - - constructor( mesh: SkinnedMesh, world: object, bodyA: RigidBody, bodyB: RigidBody, params: object, manager: ResourceManager ); - -} - -export class MMDPhysicsHelper extends Object3D { - - constructor(); - -} diff --git a/examples/jsm/cameras/CinematicCamera.d.ts b/examples/jsm/cameras/CinematicCamera.d.ts deleted file mode 100644 index 708b6b69beb86e..00000000000000 --- a/examples/jsm/cameras/CinematicCamera.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - PerspectiveCamera, - ShaderMaterial, - Scene, - WebGLRenderer -} from '../../../src/Three'; - -export class CinematicCamera extends PerspectiveCamera { - - constructor( fov: number, aspect: number, near: number, far: number ); - - postprocessing: { - enabled: boolean; - }; - shaderSettings: { - rings: number; - samples: number; - }; - materialDepth: ShaderMaterial; - coc: number; - aperture: number; - fNumber: number; - hyperFocal: number; - filmGauge: number; - - linearize( depth: number ): number; - smoothstep( near: number, far: number, depth: number ): number; - saturate( x: number ): number; - focusAt( focusDistance: number ): void; - initPostProcessing(): void; - renderCinematic( scene: Scene, renderer: WebGLRenderer ): void; - -} diff --git a/examples/jsm/controls/DeviceOrientationControls.d.ts b/examples/jsm/controls/DeviceOrientationControls.d.ts deleted file mode 100644 index 0917848a535b0b..00000000000000 --- a/examples/jsm/controls/DeviceOrientationControls.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { Camera, EventDispatcher } from '../../../src/Three'; - -export class DeviceOrientationControls extends EventDispatcher { - - constructor( object: Camera ); - - object: Camera; - - // API - - alphaOffset: number; - deviceOrientation: any; - enabled: boolean; - screenOrientation: number; - - connect(): void; - disconnect(): void; - dispose(): void; - update(): void; - -} diff --git a/examples/jsm/controls/DragControls.d.ts b/examples/jsm/controls/DragControls.d.ts deleted file mode 100644 index e4570a456016bc..00000000000000 --- a/examples/jsm/controls/DragControls.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - Camera, - EventDispatcher, - Object3D -} from '../../../src/Three'; - -export class DragControls extends EventDispatcher { - - constructor( objects: Object3D[], camera: Camera, domElement?: HTMLElement ); - - object: Camera; - - // API - - enabled: boolean; - transformGroup: boolean; - - activate(): void; - deactivate(): void; - dispose(): void; - getObjects(): Object3D[]; - -} diff --git a/examples/jsm/controls/FirstPersonControls.d.ts b/examples/jsm/controls/FirstPersonControls.d.ts deleted file mode 100644 index 6d64eb4a1e13a6..00000000000000 --- a/examples/jsm/controls/FirstPersonControls.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - Camera, - Vector3 -} from '../../../src/Three'; - -export class FirstPersonControls { - - constructor( object: Camera, domElement?: HTMLElement ); - - object: Camera; - domElement: HTMLElement | HTMLDocument; - - enabled: boolean; - movementSpeed: number; - lookSpeed: number; - lookVertical: boolean; - autoForward: boolean; - activeLook: boolean; - heightSpeed: boolean; - heightCoef: number; - heightMin: number; - heightMax: number; - constrainVertical: boolean; - verticalMin: number; - verticalMax: number; - mouseDragOn: boolean; - - handleResize(): void; - lookAt( x: number | Vector3, y: number, z: number ): this; - update( delta: number ): this; - dispose(): void; - -} diff --git a/examples/jsm/controls/FlyControls.d.ts b/examples/jsm/controls/FlyControls.d.ts deleted file mode 100644 index 96bbbc41ba2892..00000000000000 --- a/examples/jsm/controls/FlyControls.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { - Camera, EventDispatcher -} from '../../../src/Three'; - -export class FlyControls extends EventDispatcher { - - constructor( object: Camera, domElement?: HTMLElement ); - - object: Camera; - domElement: HTMLElement | HTMLDocument; - - movementSpeed: number; - rollSpeed: number; - dragToLook: boolean; - autoForward: boolean; - - update( delta: number ): void; - dispose(): void; - -} diff --git a/examples/jsm/controls/OrbitControls.d.ts b/examples/jsm/controls/OrbitControls.d.ts deleted file mode 100644 index f6656334271ffc..00000000000000 --- a/examples/jsm/controls/OrbitControls.d.ts +++ /dev/null @@ -1,80 +0,0 @@ -import { Camera, MOUSE, TOUCH, Vector3 } from '../../../src/Three'; - -export class OrbitControls { - - constructor( object: Camera, domElement?: HTMLElement ); - - object: Camera; - domElement: HTMLElement | HTMLDocument; - - // API - enabled: boolean; - target: Vector3; - - // deprecated - center: Vector3; - - minDistance: number; - maxDistance: number; - - minZoom: number; - maxZoom: number; - - minPolarAngle: number; - maxPolarAngle: number; - - minAzimuthAngle: number; - maxAzimuthAngle: number; - - enableDamping: boolean; - dampingFactor: number; - - enableZoom: boolean; - zoomSpeed: number; - - enableRotate: boolean; - rotateSpeed: number; - - enablePan: boolean; - panSpeed: number; - screenSpacePanning: boolean; - keyPanSpeed: number; - - autoRotate: boolean; - autoRotateSpeed: number; - - enableKeys: boolean; - keys: { LEFT: number; UP: number; RIGHT: number; BOTTOM: number; }; - mouseButtons: { LEFT: MOUSE; MIDDLE: MOUSE; RIGHT: MOUSE; }; - touches: { ONE: TOUCH; TWO: TOUCH }; - - update(): boolean; - - listenToKeyEvents( domElement: HTMLElement ): void; - - saveState(): void; - - reset(): void; - - dispose(): void; - - getPolarAngle(): number; - - getAzimuthalAngle(): number; - - // EventDispatcher mixins - addEventListener( type: string, listener: ( event: any ) => void ): void; - - hasEventListener( type: string, listener: ( event: any ) => void ): boolean; - - removeEventListener( type: string, listener: ( event: any ) => void ): void; - - dispatchEvent( event: { type: string; target: any; } ): void; - -} - -export class MapControls extends OrbitControls { - - constructor( object: Camera, domElement?: HTMLElement ); - -} diff --git a/examples/jsm/controls/PointerLockControls.d.ts b/examples/jsm/controls/PointerLockControls.d.ts deleted file mode 100644 index 9bf66859728cc8..00000000000000 --- a/examples/jsm/controls/PointerLockControls.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { - Camera, - EventDispatcher, - Vector3 -} from '../../../src/Three'; - -export class PointerLockControls extends EventDispatcher { - - constructor( camera: Camera, domElement?: HTMLElement ); - - domElement: HTMLElement; - - // API - - isLocked: boolean; - - minPolarAngle: number; - maxPolarAngle: number; - - connect(): void; - disconnect(): void; - dispose(): void; - getObject(): Camera; - getDirection( v: Vector3 ): Vector3; - moveForward( distance: number ): void; - moveRight( distance: number ): void; - lock(): void; - unlock(): void; - -} diff --git a/examples/jsm/controls/TrackballControls.d.ts b/examples/jsm/controls/TrackballControls.d.ts deleted file mode 100644 index db049a4d728bde..00000000000000 --- a/examples/jsm/controls/TrackballControls.d.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Camera, EventDispatcher, MOUSE, Vector3 } from '../../../src/Three'; - -export class TrackballControls extends EventDispatcher { - - constructor( object: Camera, domElement?: HTMLElement ); - - object: Camera; - domElement: HTMLElement; - - // API - enabled: boolean; - screen: {left: number; top: number; width: number; height: number}; - rotateSpeed: number; - zoomSpeed: number; - panSpeed: number; - noRotate: boolean; - noZoom: boolean; - noPan: boolean; - noRoll: boolean; - staticMoving: boolean; - dynamicDampingFactor: number; - minDistance: number; - maxDistance: number; - keys: number[]; - mouseButtons: { LEFT: MOUSE; MIDDLE: MOUSE; RIGHT: MOUSE }; - - target: Vector3; - position0: Vector3; - target0: Vector3; - up0: Vector3; - - update(): void; - - reset(): void; - - dispose(): void; - - checkDistances(): void; - - zoomCamera(): void; - - panCamera(): void; - - rotateCamera(): void; - - handleResize(): void; - -} diff --git a/examples/jsm/controls/TransformControls.d.ts b/examples/jsm/controls/TransformControls.d.ts deleted file mode 100644 index e7c37ed48ddb55..00000000000000 --- a/examples/jsm/controls/TransformControls.d.ts +++ /dev/null @@ -1,46 +0,0 @@ -import { - Object3D, - Camera, - MOUSE -} from '../../../src/Three'; - -export class TransformControls extends Object3D { - - constructor( object: Camera, domElement?: HTMLElement ); - - domElement: HTMLElement; - - // API - - camera: Camera; - object: Object3D | undefined; - enabled: boolean; - axis: string | null; - mode: string; - translationSnap: number | null; - rotationSnap: number | null; - space: string; - size: number; - dragging: boolean; - showX: boolean; - showY: boolean; - showZ: boolean; - readonly isTransformControls: true; - mouseButtons: { - LEFT: MOUSE; - MIDDLE: MOUSE; - RIGHT: MOUSE; - }; - - attach( object: Object3D ): this; - detach(): this; - getMode(): string; - setMode( mode: string ): void; - setTranslationSnap( translationSnap: Number | null ): void; - setRotationSnap( rotationSnap: Number | null ): void; - setScaleSnap( scaleSnap: Number | null ): void; - setSize( size: number ): void; - setSpace( space: string ): void; - dispose(): void; - -} diff --git a/examples/jsm/csm/CSM.d.ts b/examples/jsm/csm/CSM.d.ts deleted file mode 100644 index aa089317b4d9bb..00000000000000 --- a/examples/jsm/csm/CSM.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -export class CSM { - - constructor( data: any ); - camera: any; - parent: any; - cascades: any; - maxFar: any; - mode: any; - shadowMapSize: any; - shadowBias: any; - lightDirection: any; - lightIntensity: any; - lightNear: any; - lightFar: any; - lightMargin: any; - customSplitsCallback: any; - fade: boolean; - mainFrustum: Frustum; - frustums: any[]; - breaks: any[]; - lights: any[]; - shaders: Map; - createLights(): void; - initCascades(): void; - updateShadowBounds(): void; - getBreaks(): void; - update(): void; - injectInclude(): void; - setupMaterial( material: any ): void; - updateUniforms(): void; - getExtendedBreaks( target: any ): void; - updateFrustums(): void; - remove(): void; - dispose(): void; - -} - -import Frustum from './Frustum.js'; diff --git a/examples/jsm/csm/CSMHelper.d.ts b/examples/jsm/csm/CSMHelper.d.ts deleted file mode 100644 index 69568e3a9d0dea..00000000000000 --- a/examples/jsm/csm/CSMHelper.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -export class CSMHelper { - - constructor( csm: any ); - csm: any; - displayFrustum: boolean; - displayPlanes: boolean; - displayShadowBounds: boolean; - frustumLines: any; - cascadeLines: any[]; - cascadePlanes: any[]; - shadowLines: any[]; - updateVisibility(): void; - update(): void; - -} diff --git a/examples/jsm/csm/Frustum.d.ts b/examples/jsm/csm/Frustum.d.ts deleted file mode 100644 index 2e3d99f667e7ec..00000000000000 --- a/examples/jsm/csm/Frustum.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -export default class Frustum { - - constructor( data: any ); - vertices: { - near: any[]; - far: any[]; - }; - setFromProjectionMatrix( projectionMatrix: any, maxFar: any ): { - near: any[]; - far: any[]; - }; - split( breaks: any, target: any ): void; - toSpace( cameraMatrix: any, target: any ): void; - -} diff --git a/examples/jsm/csm/Shader.d.ts b/examples/jsm/csm/Shader.d.ts deleted file mode 100644 index 52a1a0245a0d3e..00000000000000 --- a/examples/jsm/csm/Shader.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -declare namespace _default { - - export const lights_fragment_begin: string; - export const lights_pars_begin: string; - -} - -export default _default; diff --git a/examples/jsm/curves/CurveExtras.d.ts b/examples/jsm/curves/CurveExtras.d.ts deleted file mode 100644 index 344b3d837d80ae..00000000000000 --- a/examples/jsm/curves/CurveExtras.d.ts +++ /dev/null @@ -1,104 +0,0 @@ -import { - Curve, - Vector3 -} from '../../../src/Three'; - - -export namespace Curves { - - export class GrannyKnot extends Curve { - - constructor(); - - } - - export class HeartCurve extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class VivianiCurve extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class KnotCurve extends Curve { - - constructor(); - - } - - export class HelixCurve extends Curve { - - constructor(); - - } - - export class TrefoilKnot extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class TorusKnot extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class CinquefoilKnot extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class TrefoilPolynomialKnot extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class FigureEightPolynomialKnot extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class DecoratedTorusKnot4a extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class DecoratedTorusKnot4b extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class DecoratedTorusKnot5a extends Curve { - - constructor( scale?: number ); - scale: number; - - } - - export class DecoratedTorusKnot5c extends Curve { - - constructor( scale?: number ); - scale: number; - - } - -} diff --git a/examples/jsm/curves/NURBSCurve.d.ts b/examples/jsm/curves/NURBSCurve.d.ts deleted file mode 100644 index 64aa9c6285714d..00000000000000 --- a/examples/jsm/curves/NURBSCurve.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Curve, - Vector2, - Vector3, - Vector4 -} from '../../../src/Three'; - -export class NURBSCurve extends Curve { - - constructor( degree: number, knots: number[], controlPoints: Vector2[] | Vector3[] | Vector4[], startKnot: number, endKnot: number ); - -} diff --git a/examples/jsm/curves/NURBSSurface.d.ts b/examples/jsm/curves/NURBSSurface.d.ts deleted file mode 100644 index fbccdd4e54f48d..00000000000000 --- a/examples/jsm/curves/NURBSSurface.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Vector2, - Vector3, - Vector4 -} from '../../../src/Three'; - -export class NURBSSurface { - - constructor( degree1: number, degree2: number, knots1: number[], knots2: number[], controlPoints: Vector2[][] | Vector3[][] | Vector4[][] ); - - getPoint( t1: number, t2: number, target: Vector3 ): void; - -} diff --git a/examples/jsm/curves/NURBSUtils.d.ts b/examples/jsm/curves/NURBSUtils.d.ts deleted file mode 100644 index 80af0a236c2e26..00000000000000 --- a/examples/jsm/curves/NURBSUtils.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - Vector3, - Vector4 -} from '../../../src/Three'; - -export namespace NURBSUtils { - - export function findSpan( p: number, u: number, U: number[] ): number; - export function calcBasisFunctions( span: number, u: number, p: number, U: number[] ): number[]; - export function calcBSplinePoint( p: number, U: number[], P: Vector4[], u: number ): Vector4; - export function calcBasisFunctionDerivatives( span: number, u: number, p: number, n: number, U: number[] ): number[][]; - export function calcBSplineDerivatives( p: number, U: number[], P: Vector4[], u: number, nd: number ): Vector4[]; - export function calcKoverI( k: number, i: number ): number; - export function calcRationalCurveDerivatives( Pders: Vector4[] ): Vector3[]; - export function calcNURBSDerivatives( p: number, U: number[], P: Vector4[], u: number, nd: number ): Vector3[]; - export function calcSurfacePoint( p: number, q: number, U: number[], V: number[], P: Vector4[], u: number, v: number, target: Vector3 ): Vector3; - -} diff --git a/examples/jsm/deprecated/Geometry.d.ts b/examples/jsm/deprecated/Geometry.d.ts deleted file mode 100644 index cb44bc5f8467e7..00000000000000 --- a/examples/jsm/deprecated/Geometry.d.ts +++ /dev/null @@ -1,374 +0,0 @@ -import { - Vector3, - Color, - Vector2, - Vector4, - Box3, - Sphere, - Matrix4, - BufferGeometry, - Matrix, - Mesh, - Bone, - AnimationClip, - EventDispatcher, - Object3D -} from '../../../src/Three'; - -/** - * @deprecated Use Face3 instead. - */ - -export interface MorphTarget { - name: string; - vertices: Vector3[]; -} - -export interface MorphColor { - name: string; - colors: Color[]; -} - -export interface MorphNormals { - name: string; - normals: Vector3[]; -} - -/** - * Base class for geometries - */ -export class Geometry extends EventDispatcher { - - constructor(); - - /** - * Unique number of this geometry instance - */ - id: number; - - uuid: string; - - readonly isGeometry: true; - - /** - * Name for this geometry. Default is an empty string. - * @default '' - */ - name: string; - - /** - * @default 'Geometry' - */ - type: string; - - /** - * The array of vertices hold every position of points of the model. - * To signal an update in this array, Geometry.verticesNeedUpdate needs to be set to true. - * @default [] - */ - vertices: Vector3[]; - - /** - * Array of vertex colors, matching number and order of vertices. - * Used in ParticleSystem, Line and Ribbon. - * Meshes use per-face-use-of-vertex colors embedded directly in faces. - * To signal an update in this array, Geometry.colorsNeedUpdate needs to be set to true. - * @default [] - */ - colors: Color[]; - - /** - * Array of triangles or/and quads. - * The array of faces describe how each vertex in the model is connected with each other. - * To signal an update in this array, Geometry.elementsNeedUpdate needs to be set to true. - * @default [] - */ - faces: Face3[]; - - /** - * Array of face UV layers. - * Each UV layer is an array of UV matching order and number of vertices in faces. - * To signal an update in this array, Geometry.uvsNeedUpdate needs to be set to true. - * @default [[]] - */ - faceVertexUvs: Vector2[][][]; - - /** - * Array of morph targets. Each morph target is a Javascript object: - * - * { name: "targetName", vertices: [ new THREE.Vector3(), ... ] } - * - * Morph vertices match number and order of primary vertices. - * @default [] - */ - morphTargets: MorphTarget[]; - - /** - * Array of morph normals. Morph normals have similar structure as morph targets, each normal set is a Javascript object: - * - * morphNormal = { name: "NormalName", normals: [ new THREE.Vector3(), ... ] } - * @default [] - */ - morphNormals: MorphNormals[]; - - /** - * Array of skinning weights, matching number and order of vertices. - * @default [] - */ - skinWeights: Vector4[]; - - /** - * Array of skinning indices, matching number and order of vertices. - * @default [] - */ - skinIndices: Vector4[]; - - /** - * @default [] - */ - lineDistances: number[]; - - /** - * Bounding box. - * @default null - */ - boundingBox: Box3 | null; - - /** - * Bounding sphere. - * @default null - */ - boundingSphere: Sphere | null; - - /** - * Set to true if the vertices array has been updated. - * @default false - */ - verticesNeedUpdate: boolean; - - /** - * Set to true if the faces array has been updated. - * @default false - */ - elementsNeedUpdate: boolean; - - /** - * Set to true if the uvs array has been updated. - * @default false - */ - uvsNeedUpdate: boolean; - - /** - * Set to true if the normals array has been updated. - * @default false - */ - normalsNeedUpdate: boolean; - - /** - * Set to true if the colors array has been updated. - * @default false - */ - colorsNeedUpdate: boolean; - - /** - * Set to true if the linedistances array has been updated. - * @default false - */ - lineDistancesNeedUpdate: boolean; - - /** - * - * @default false - */ - groupsNeedUpdate: boolean; - - /** - * Bakes matrix transform directly into vertex coordinates. - */ - applyMatrix4( matrix: Matrix4 ): Geometry; - - rotateX( angle: number ): Geometry; - rotateY( angle: number ): Geometry; - rotateZ( angle: number ): Geometry; - - translate( x: number, y: number, z: number ): Geometry; - scale( x: number, y: number, z: number ): Geometry; - lookAt( vector: Vector3 ): void; - - fromBufferGeometry( geometry: BufferGeometry ): Geometry; - - center(): Geometry; - - normalize(): Geometry; - - /** - * Computes face normals. - */ - computeFaceNormals(): void; - - /** - * Computes vertex normals by averaging face normals. - * Face normals must be existing / computed beforehand. - */ - computeVertexNormals( areaWeighted?: boolean ): void; - - /** - * Compute vertex normals, but duplicating face normals. - */ - computeFlatVertexNormals(): void; - - /** - * Computes morph normals. - */ - computeMorphNormals(): void; - - /** - * Computes bounding box of the geometry, updating {@link Geometry.boundingBox} attribute. - */ - computeBoundingBox(): void; - - /** - * Computes bounding sphere of the geometry, updating Geometry.boundingSphere attribute. - * Neither bounding boxes or bounding spheres are computed by default. They need to be explicitly computed, otherwise they are null. - */ - computeBoundingSphere(): void; - - merge( - geometry: Geometry, - matrix?: Matrix, - materialIndexOffset?: number - ): void; - - mergeMesh( mesh: Mesh ): void; - - /** - * Checks for duplicate vertices using hashmap for specified number of decimal points, e.g. 4 for epsilon of 0.0001 - * Duplicated vertices are removed and faces' vertices are updated. - */ - mergeVertices( precisionPoints?: number ): number; - - setFromPoints( points: Array | Array ): this; - - sortFacesByMaterialIndex(): void; - - toBufferGeometry(): BufferGeometry; - - static createBufferGeometryFromObject( object: Object3D ): BufferGeometry; - - toJSON(): any; - - /** - * Creates a new clone of the Geometry. - */ - clone(): Geometry; - - copy( source: Geometry ): this; - - /** - * Removes The object from memory. - * Don't forget to call this method when you remove an geometry because it can cuase meomory leaks. - */ - dispose(): void; - - // These properties do not exist in a normal Geometry class, but if you use the instance that was passed by JSONLoader, it will be added. - bones: Bone[]; - animation: AnimationClip; - animations: AnimationClip[]; - -} - -/** - * Triangle face. - */ -export class Face3 { - - /** - * @param a Vertex A index. - * @param b Vertex B index. - * @param c Vertex C index. - * @param normal Face normal or array of vertex normals. - * @param color Face color or array of vertex colors. - * @param materialIndex Material index. - */ - constructor( - a: number, - b: number, - c: number, - normal?: Vector3, - color?: Color, - materialIndex?: number - ); - constructor( - a: number, - b: number, - c: number, - normal?: Vector3, - vertexColors?: Color[], - materialIndex?: number - ); - constructor( - a: number, - b: number, - c: number, - vertexNormals?: Vector3[], - color?: Color, - materialIndex?: number - ); - constructor( - a: number, - b: number, - c: number, - vertexNormals?: Vector3[], - vertexColors?: Color[], - materialIndex?: number - ); - - /** - * Vertex A index. - */ - a: number; - - /** - * Vertex B index. - */ - b: number; - - /** - * Vertex C index. - */ - c: number; - - /** - * Face normal. - * @default new THREE.Vector3() - */ - normal: Vector3; - - /** - * Array of 3 vertex normals. - * @default [] - */ - vertexNormals: Vector3[]; - - /** - * Face color. - * @default new THREE.Color() - */ - color: Color; - - /** - * Array of 3 vertex colors. - * @default [] - */ - vertexColors: Color[]; - - /** - * Material index (points to {@link Mesh.material}). - * @default 0 - */ - materialIndex: number; - - clone(): Face3; - copy( source: Face3 ): this; - -} diff --git a/examples/jsm/effects/AnaglyphEffect.d.ts b/examples/jsm/effects/AnaglyphEffect.d.ts deleted file mode 100644 index 6c778def670b78..00000000000000 --- a/examples/jsm/effects/AnaglyphEffect.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - Camera, - Matrix3, - Scene, - WebGLRenderer -} from '../../../src/Three'; - -export class AnaglyphEffect { - - constructor( renderer: WebGLRenderer, width?: number, height?: number ); - colorMatrixLeft: Matrix3; - colorMatrixRight: Matrix3; - - dispose(): void; - render( scene: Scene, camera: Camera ): void; - setSize( width: number, height: number ): void; - -} diff --git a/examples/jsm/effects/AsciiEffect.d.ts b/examples/jsm/effects/AsciiEffect.d.ts deleted file mode 100644 index 0c9bd0711eb328..00000000000000 --- a/examples/jsm/effects/AsciiEffect.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - Camera, - Scene, - WebGLRenderer -} from '../../../src/Three'; - -export interface AsciiEffectOptions { - resolution?: number; - scale?: number; - color?: boolean; - alpha?: boolean; - block?: boolean; - invert?: boolean; -} - -export class AsciiEffect { - - constructor( renderer: WebGLRenderer, charSet?: string, options?: AsciiEffectOptions ); - domElement: HTMLElement; - - render( scene: Scene, camera: Camera ): void; - setSize( width: number, height: number ): void; - -} diff --git a/examples/jsm/effects/OutlineEffect.d.ts b/examples/jsm/effects/OutlineEffect.d.ts deleted file mode 100644 index 92d67a3a74d6ff..00000000000000 --- a/examples/jsm/effects/OutlineEffect.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { - Camera, - Scene, - Vector2, - Vector4, - WebGLRenderer, - WebGLRenderTarget, - WebGLShadowMap -} from '../../../src/Three'; - -export interface OutlineEffectParameters { - defaultThickness?: number; - defaultColor?: number[]; - defaultAlpha?: number; - defaultKeepAlive?: boolean; -} - -export class OutlineEffect { - - constructor( renderer: WebGLRenderer, parameters: OutlineEffectParameters ); - enabled: boolean; - autoClear: boolean; - domElement: HTMLElement; - shadowMap: WebGLShadowMap; - - clear( color?: boolean, depth?: boolean, stencil?: boolean ): void; - getPixelRatio(): number; - getSize( target: Vector2 ): Vector2; - render( scene: Scene, camera: Camera ): void; - renderOutline( scene: Scene, camera: Camera ): void; - setRenderTarget( renderTarget: WebGLRenderTarget | null ): void; - setPixelRatio( value: number ): void; - setScissor( x: Vector4 | number, y?: number, width?: number, height?: number ): void; - setScissorTest( enable: boolean ): void; - setSize( width: number, height: number, updateStyle?: boolean ): void; - setViewport( x: Vector4 | number, y?: number, width?: number, height?: number ): void; - -} diff --git a/examples/jsm/effects/ParallaxBarrierEffect.d.ts b/examples/jsm/effects/ParallaxBarrierEffect.d.ts deleted file mode 100644 index 99f67eef869606..00000000000000 --- a/examples/jsm/effects/ParallaxBarrierEffect.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Camera, - Scene, - WebGLRenderer -} from '../../../src/Three'; - -export class ParallaxBarrierEffect { - - constructor( renderer: WebGLRenderer ); - - render( scene: Scene, camera: Camera ): void; - setSize( width: number, height: number ): void; - -} diff --git a/examples/jsm/effects/PeppersGhostEffect.d.ts b/examples/jsm/effects/PeppersGhostEffect.d.ts deleted file mode 100644 index be37dab18d854b..00000000000000 --- a/examples/jsm/effects/PeppersGhostEffect.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Camera, - Scene, - WebGLRenderer -} from '../../../src/Three'; - -export class PeppersGhostEffect { - - constructor( renderer: WebGLRenderer ); - cameraDistance: number; - reflectFromAbove: boolean; - - render( scene: Scene, camera: Camera ): void; - setSize( width: number, height: number ): void; - -} diff --git a/examples/jsm/effects/StereoEffect.d.ts b/examples/jsm/effects/StereoEffect.d.ts deleted file mode 100644 index cf6654f94a291b..00000000000000 --- a/examples/jsm/effects/StereoEffect.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Camera, - Scene, - WebGLRenderer -} from '../../../src/Three'; - -export class StereoEffect { - - constructor( renderer: WebGLRenderer ); - - setEyeSeparation( eyeSep: number ): void; - render( scene: Scene, camera: Camera ): void; - setSize( width: number, height: number ): void; - -} diff --git a/examples/jsm/environments/RoomEnvironment.d.ts b/examples/jsm/environments/RoomEnvironment.d.ts deleted file mode 100644 index d7ae129d76ce07..00000000000000 --- a/examples/jsm/environments/RoomEnvironment.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { Scene } from '../../../src/Three'; - -export class RoomEnvironment extends Scene { - - constructor(); - -} diff --git a/examples/jsm/exporters/ColladaExporter.d.ts b/examples/jsm/exporters/ColladaExporter.d.ts deleted file mode 100644 index 6c17f94e9313b6..00000000000000 --- a/examples/jsm/exporters/ColladaExporter.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { Object3D } from '../../../src/Three'; - -export interface ColladaExporterOptions { - author?: string; - textureDirectory?: string; - version?: string; -} - -export interface ColladaExporterResult { - data: string; - textures: object[]; -} - -export class ColladaExporter { - - constructor(); - - parse( object: Object3D, onDone: ( res: ColladaExporterResult ) => void, options: ColladaExporterOptions ): ColladaExporterResult | null; - -} diff --git a/examples/jsm/exporters/DRACOExporter.d.ts b/examples/jsm/exporters/DRACOExporter.d.ts deleted file mode 100644 index 9f117533c646e8..00000000000000 --- a/examples/jsm/exporters/DRACOExporter.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - Mesh, - Points -} from '../../../src/Three'; - -export interface DRACOExporterOptions { - decodeSpeed?: number; - encodeSpeed?: number; - encoderMethod?: number; - quantization?: number[]; - exportUvs?: boolean; - exportNormals?: boolean; - exportColor?: boolean; -} - -export class DRACOExporter { - - constructor(); - - parse( object: Mesh | Points, options: DRACOExporterOptions ): Int8Array; - -} diff --git a/examples/jsm/exporters/GLTFExporter.d.ts b/examples/jsm/exporters/GLTFExporter.d.ts deleted file mode 100644 index 8229511b403d9a..00000000000000 --- a/examples/jsm/exporters/GLTFExporter.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - Object3D, - AnimationClip -} from '../../../src/Three'; - -export interface GLTFExporterOptions { - binary?: boolean; - trs?: boolean; - onlyVisible?: boolean; - truncateDrawRange?: boolean; - embedImages?: boolean; - animations?: AnimationClip[]; - forceIndices?: boolean; - forcePowerOfTwoTextures?: boolean; - includeCustomExtensions?: boolean; -} - -export class GLTFExporter { - - constructor(); - - parse( input: Object3D, onCompleted: ( gltf: object ) => void, options: GLTFExporterOptions ): void; - -} diff --git a/examples/jsm/exporters/MMDExporter.d.ts b/examples/jsm/exporters/MMDExporter.d.ts deleted file mode 100644 index 9c0ad870f5cb6d..00000000000000 --- a/examples/jsm/exporters/MMDExporter.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Object3D } from '../../../src/Three'; - -export class MMDExporter { - - constructor(); - - parseVpd( skin: Object3D, outputShiftJis: boolean, useOriginalBones: boolean ): [] | Uint8Array - -} diff --git a/examples/jsm/exporters/OBJExporter.d.ts b/examples/jsm/exporters/OBJExporter.d.ts deleted file mode 100644 index 7cf476ebee2ec1..00000000000000 --- a/examples/jsm/exporters/OBJExporter.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Object3D } from '../../../src/Three'; - -export class OBJExporter { - - constructor(); - - parse( object: Object3D ): string; - -} diff --git a/examples/jsm/exporters/PLYExporter.d.ts b/examples/jsm/exporters/PLYExporter.d.ts deleted file mode 100644 index 901565e1cc426c..00000000000000 --- a/examples/jsm/exporters/PLYExporter.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { Object3D } from '../../../src/Three'; - -export interface PLYExporterOptions { - binary?: boolean; - excludeAttributes?: string[]; - littleEndian?: boolean; -} - -export class PLYExporter { - - constructor(); - - parse( object: Object3D, onDone: ( res: string ) => void, options: PLYExporterOptions ): string | null; - -} diff --git a/examples/jsm/exporters/STLExporter.d.ts b/examples/jsm/exporters/STLExporter.d.ts deleted file mode 100644 index c57563662c7b87..00000000000000 --- a/examples/jsm/exporters/STLExporter.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { Object3D } from '../../../src/Three'; - -export interface STLExporterOptions { - binary?: boolean; -} - -export class STLExporter { - - constructor(); - - parse( scene: Object3D, options?: STLExporterOptions ): string; - -} diff --git a/examples/jsm/exporters/USDZExporter.d.ts b/examples/jsm/exporters/USDZExporter.d.ts deleted file mode 100644 index f67cef9e4b830f..00000000000000 --- a/examples/jsm/exporters/USDZExporter.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Object3D } from '../../../src/Three'; - -export class USDZExporter { - - constructor(); - - parse( scene: Object3D ): Uint8Array; - -} diff --git a/examples/jsm/geometries/BoxLineGeometry.d.ts b/examples/jsm/geometries/BoxLineGeometry.d.ts deleted file mode 100644 index b99fde36ba921c..00000000000000 --- a/examples/jsm/geometries/BoxLineGeometry.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { - BufferGeometry -} from '../../../src/Three'; - -export class BoxLineGeometry extends BufferGeometry { - - constructor( width?: number, height?: number, depth?: number, widthSegments?: number, heightSegments?: number, depthSegments?: number ); - -} diff --git a/examples/jsm/geometries/ConvexGeometry.d.ts b/examples/jsm/geometries/ConvexGeometry.d.ts deleted file mode 100644 index 051c62cd692e20..00000000000000 --- a/examples/jsm/geometries/ConvexGeometry.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { - BufferGeometry, - Vector3 -} from '../../../src/Three'; - -export class ConvexGeometry extends BufferGeometry { - - constructor( points: Vector3[] ); - -} diff --git a/examples/jsm/geometries/DecalGeometry.d.ts b/examples/jsm/geometries/DecalGeometry.d.ts deleted file mode 100644 index 9259f9fdcddb25..00000000000000 --- a/examples/jsm/geometries/DecalGeometry.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - BufferGeometry, - Euler, - Mesh, - Vector3 -} from '../../../src/Three'; - -export class DecalGeometry extends BufferGeometry { - - constructor( mesh: Mesh, position: Vector3, orientation: Euler, size: Vector3 ); - -} - -export class DecalVertex { - - constructor( position: Vector3, normal: Vector3 ); - clone(): DecalVertex; - -} diff --git a/examples/jsm/geometries/LightningStrike.d.ts b/examples/jsm/geometries/LightningStrike.d.ts deleted file mode 100644 index dd57efc4ef949b..00000000000000 --- a/examples/jsm/geometries/LightningStrike.d.ts +++ /dev/null @@ -1,107 +0,0 @@ -import { - Vector3 -} from '../../../src/Three'; - -export interface RandomGenerator { - random(): number; - getSeed(): number; - setSeed( seed: number ): void; -} - -export interface LightningSegment { - iteration: number; - pos0: Vector3; - pos1: Vector3; - linPos0: Vector3; - linPos1: Vector3; - up0: Vector3; - up1: Vector3; - radius0: number; - radius1: number; - fraction0: number; - fraction1: number; - positionVariationFactor: number; -} - -export interface LightningSubray { - seed: number; - maxIterations: number; - recursion: number; - pos0: Vector3; - pos1: Vector3; - linPos0: Vector3; - linPos1: Vector3; - up0: Vector3; - up1: Vector3; - radius0: number; - radius1: number; - birthTime: number; - deathTime: number; - timeScale: number; - roughness: number; - straightness: number; - propagationTimeFactor: number; - vanishingTimeFactor: number; - endPropagationTime: number; - beginVanishingTime: number; -} - -export interface RayParameters { - sourceOffset?: Vector3; - destOffset?: Vector3; - - timeScale?: number; - roughness?: number; - straightness?: number; - - up0?: Vector3; - up1?: Vector3; - radius0?: number; - radius1?: number; - radius0Factor? : number; - radius1Factor? : number; - minRadius? : number; - - isEternal?: boolean; - birthTime?: number; - deathTime?: number; - propagationTimeFactor?: number; - vanishingTimeFactor?: number; - subrayPeriod?: number; - subrayDutyCycle?: number; - - maxIterations?: number; - isStatic?: boolean; - ramification?: number; - maxSubrayRecursion?: number; - recursionProbability?: number; - generateUVs?: boolean; - - randomGenerator?: RandomGenerator; - noiseSeed?: number; - - onDecideSubrayCreation?: ( segment: LightningSegment, lightningStrike: LightningStrike ) => void; - onSubrayCreation?: ( segment: LightningSegment, parentSubray: LightningSubray, childSubray: LightningSubray, lightningStrike: LightningStrike ) => void; -} - -export class LightningStrike { - - constructor( rayParameters?: RayParameters ); - copyParameters( dest?: RayParameters, source?: RayParameters ): RayParameters; - - // Ray states - static readonly RAY_INITIALIZED: number; - static readonly RAY_UNBORN: number; - static readonly RAY_PROPAGATING: number; - static readonly RAY_STEADY: number; - static readonly RAY_VANISHING: number; - static readonly RAY_EXTINGUISHED: number; - - state: number; - - update( time: number ): void; - - copy( source: LightningStrike ): LightningStrike; - clone(): LightningStrike; - -} diff --git a/examples/jsm/geometries/ParametricGeometries.d.ts b/examples/jsm/geometries/ParametricGeometries.d.ts deleted file mode 100644 index 5b91def1ba79dd..00000000000000 --- a/examples/jsm/geometries/ParametricGeometries.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { - Curve, - Vector3 -} from '../../../src/Three'; - -export namespace ParametricGeometries { - export function klein( v: number, u: number, target: Vector3 ): Vector3; - export function plane( width: number, height: number, target: Vector3 ): Vector3; - export function mobius( u: number, t: number, target: Vector3 ): Vector3; - export function mobius3d( u: number, t: number, target: Vector3 ): Vector3; - - export class TubeGeometry { - - constructor( path: Curve, segments?: number, radius?: number, segmentsRadius?: number, closed?: boolean ); - - } - - export class TorusKnotGeometry { - - constructor( radius?: number, tube?: number, segmentsT?: number, segmentsR?: number, p?: number, q?: number ); - - } - - export class SphereGeometry { - - constructor( size: number, u: number, v: number ); - - } - - export class PlaneGeometry { - - constructor( width: number, depth: number, segmentsWidth: number, segmentsDepth: number ); - - } -} diff --git a/examples/jsm/geometries/RoundedBoxGeometry.d.ts b/examples/jsm/geometries/RoundedBoxGeometry.d.ts deleted file mode 100644 index cf5a687cb8db08..00000000000000 --- a/examples/jsm/geometries/RoundedBoxGeometry.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { - BoxGeometry -} from '../../../src/Three'; - -export class RoundedBoxGeometry extends BoxGeometry { - - constructor( width?: number, height?: number, depth?: number, segments?: number, radius?: number ); - -} diff --git a/examples/jsm/geometries/TeapotGeometry.d.ts b/examples/jsm/geometries/TeapotGeometry.d.ts deleted file mode 100644 index 8839d1ea390837..00000000000000 --- a/examples/jsm/geometries/TeapotGeometry.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { - BufferGeometry -} from '../../../src/Three'; - -export class TeapotGeometry extends BufferGeometry { - - constructor( size?: number, segments?: number, bottom?: boolean, lid?: boolean, body?: boolean, fitLid?: boolean, blinn?: number ); - -} diff --git a/examples/jsm/helpers/LightProbeHelper.d.ts b/examples/jsm/helpers/LightProbeHelper.d.ts deleted file mode 100644 index 969b5188a1a846..00000000000000 --- a/examples/jsm/helpers/LightProbeHelper.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - LightProbe, - Mesh -} from '../../../src/Three'; - -export class LightProbeHelper extends Mesh { - - constructor( lightProbe: LightProbe, size: number ); - - lightProbe: LightProbe; - size: number; - - dispose(): void; - -} diff --git a/examples/jsm/helpers/PositionalAudioHelper.d.ts b/examples/jsm/helpers/PositionalAudioHelper.d.ts deleted file mode 100644 index b33c119ff49fc3..00000000000000 --- a/examples/jsm/helpers/PositionalAudioHelper.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - Line, - PositionalAudio -} from '../../../src/Three'; - -export class PositionalAudioHelper extends Line { - - constructor( audio: PositionalAudio, range?: number, divisionsInnerAngle?: number, divisionsOuterAngle?: number ); - - audio: PositionalAudio; - range: number; - divisionsInnerAngle: number; - divisionsOuterAngle: number; - - dispose(): void; - update(): void; - -} diff --git a/examples/jsm/helpers/RectAreaLightHelper.d.ts b/examples/jsm/helpers/RectAreaLightHelper.d.ts deleted file mode 100644 index ebaf849aa4160f..00000000000000 --- a/examples/jsm/helpers/RectAreaLightHelper.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { - Color, - Line, - RectAreaLight -} from '../../../src/Three'; - -export class RectAreaLightHelper extends Line { - - constructor( light: RectAreaLight, color?: Color | string | number ); - - light: RectAreaLight; - color: Color | string | number | undefined; - - update(): void; - dispose(): void; - -} diff --git a/examples/jsm/helpers/VertexNormalsHelper.d.ts b/examples/jsm/helpers/VertexNormalsHelper.d.ts deleted file mode 100644 index 725ee17604417b..00000000000000 --- a/examples/jsm/helpers/VertexNormalsHelper.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - Object3D, - LineSegments -} from '../../../src/Three'; - -export class VertexNormalsHelper extends LineSegments { - - constructor( - object: Object3D, - size?: number, - hex?: number - ); - - object: Object3D; - size: number; - - update(): void; - -} diff --git a/examples/jsm/helpers/VertexTangentsHelper.d.ts b/examples/jsm/helpers/VertexTangentsHelper.d.ts deleted file mode 100644 index a775e36fc3e99a..00000000000000 --- a/examples/jsm/helpers/VertexTangentsHelper.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - Object3D, - LineSegments -} from '../../../src/Three'; - -export class VertexTangentsHelper extends LineSegments { - - constructor( - object: Object3D, - size?: number, - hex?: number - ); - - object: Object3D; - size: number; - - update(): void; - -} diff --git a/examples/jsm/interactive/SelectionBox.d.ts b/examples/jsm/interactive/SelectionBox.d.ts deleted file mode 100644 index ce64ccd4dfa846..00000000000000 --- a/examples/jsm/interactive/SelectionBox.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - Camera, - Frustum, - Mesh, - Object3D, - Scene, - Vector3 -} from '../../../src/Three'; - -export class SelectionBox { - - constructor( camera: Camera, scene: Scene, deep?: number ); - camera: Camera; - collection: Mesh[]; - deep: number; - endPoint: Vector3; - scene: Scene; - startPoint: Vector3; - - select( startPoint?: Vector3, endPoint?: Vector3 ): Mesh[]; - updateFrustum( startPoint: Vector3, endPoint: Vector3 ): void; - searchChildInFrustum( frustum: Frustum, object: Object3D ): void; - -} diff --git a/examples/jsm/interactive/SelectionHelper.d.ts b/examples/jsm/interactive/SelectionHelper.d.ts deleted file mode 100644 index 338e4112990edc..00000000000000 --- a/examples/jsm/interactive/SelectionHelper.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - WebGLRenderer, - Vector2 -} from '../../../src/Three'; - -import { SelectionBox } from './SelectionBox'; - -export class SelectionHelper { - - constructor( selectionBox: SelectionBox, renderer: WebGLRenderer, cssClassName: string ); - element: HTMLElement; - isDown: boolean; - pointBottomRight: Vector2; - pointTopLeft: Vector2; - renderer: WebGLRenderer; - startPoint: Vector2; - - onSelectStart( event: Event ): void; - onSelectMove( event: Event ): void; - onSelectOver( event: Event ): void; - -} diff --git a/examples/jsm/libs/stats.module.d.ts b/examples/jsm/libs/stats.module.d.ts deleted file mode 100644 index 04f8de29cd5486..00000000000000 --- a/examples/jsm/libs/stats.module.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -declare interface Stats { - REVISION: number; - dom: HTMLDivElement; - addPanel( panel: Stats.Panel ): Stats.Panel; - showPanel( id: number ): void; - begin(): void; - end(): void; - update(): void; - domElement: HTMLDivElement; - setMode( id: number ): void; -} - -declare function Stats(): Stats; - -declare namespace Stats { - interface Panel { - dom: HTMLCanvasElement; - update( value: number, maxValue: number ): void; - } - - function Panel( name?: string, fg?: string, bg?: string ): Panel; -} - -export default Stats; diff --git a/examples/jsm/lights/LightProbeGenerator.d.ts b/examples/jsm/lights/LightProbeGenerator.d.ts deleted file mode 100644 index e96902d09fd222..00000000000000 --- a/examples/jsm/lights/LightProbeGenerator.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - CubeTexture, - LightProbe, - WebGLRenderer, - WebGLCubeRenderTarget, -} from '../../../src/Three'; - -export namespace LightProbeGenerator { - - export function fromCubeTexture( cubeTexture: CubeTexture ): LightProbe; - export function fromCubeRenderTarget( renderer: WebGLRenderer, cubeRenderTarget: WebGLCubeRenderTarget ): LightProbe; - -} diff --git a/examples/jsm/lights/RectAreaLightUniformsLib.d.ts b/examples/jsm/lights/RectAreaLightUniformsLib.d.ts deleted file mode 100644 index e188d403604a62..00000000000000 --- a/examples/jsm/lights/RectAreaLightUniformsLib.d.ts +++ /dev/null @@ -1,5 +0,0 @@ -export namespace RectAreaLightUniformsLib { - - export function init(): void; - -} diff --git a/examples/jsm/lines/Line2.d.ts b/examples/jsm/lines/Line2.d.ts deleted file mode 100644 index fa316c11e00b81..00000000000000 --- a/examples/jsm/lines/Line2.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { LineGeometry } from './LineGeometry'; -import { LineSegments2 } from './LineSegments2'; -import { LineMaterial } from './LineMaterial'; - -export class Line2 extends LineSegments2 { - - geometry: LineGeometry; - material: LineMaterial; - - constructor( geometry?: LineGeometry, material?: LineMaterial ); - readonly isLine2: true; - -} diff --git a/examples/jsm/lines/LineGeometry.d.ts b/examples/jsm/lines/LineGeometry.d.ts deleted file mode 100644 index bba22614f53ce4..00000000000000 --- a/examples/jsm/lines/LineGeometry.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Line -} from '../../../src/Three'; - -import { LineSegmentsGeometry } from './LineSegmentsGeometry'; - -export class LineGeometry extends LineSegmentsGeometry { - - constructor(); - readonly isLineGeometry: true; - - fromLine( line: Line ): this; - -} diff --git a/examples/jsm/lines/LineMaterial.d.ts b/examples/jsm/lines/LineMaterial.d.ts deleted file mode 100644 index 1dfeb8a27ec66b..00000000000000 --- a/examples/jsm/lines/LineMaterial.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - Color, - MaterialParameters, - ShaderMaterial, - Vector2 -} from '../../../src/Three'; - -export interface LineMaterialParameters extends MaterialParameters { - color?: number; - dashed?: boolean; - dashScale?: number; - dashSize?: number; - dashOffset?: number; - gapSize?: number; - linewidth?: number; - resolution?: Vector2; -} - -export class LineMaterial extends ShaderMaterial { - - constructor( parameters?: LineMaterialParameters ); - color: Color; - dashed: boolean; - dashScale: number; - dashSize: number; - dashOffset: number; - gapSize: number; - opacity: number; - readonly isLineMaterial: true; - linewidth: number; - resolution: Vector2; - -} diff --git a/examples/jsm/lines/LineSegments2.d.ts b/examples/jsm/lines/LineSegments2.d.ts deleted file mode 100644 index 4d90eae844140c..00000000000000 --- a/examples/jsm/lines/LineSegments2.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - Mesh, -} from '../../../src/Three'; - -import { LineMaterial } from './LineMaterial'; -import { LineSegmentsGeometry } from './LineSegmentsGeometry'; - -export class LineSegments2 extends Mesh { - - geometry: LineSegmentsGeometry; - material: LineMaterial; - - constructor( geometry?: LineSegmentsGeometry, material?: LineMaterial ); - readonly isLineSegments2: true; - - computeLineDistances(): this; - -} diff --git a/examples/jsm/lines/LineSegmentsGeometry.d.ts b/examples/jsm/lines/LineSegmentsGeometry.d.ts deleted file mode 100644 index da9d67af596ffb..00000000000000 --- a/examples/jsm/lines/LineSegmentsGeometry.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - EdgesGeometry, - InstancedBufferGeometry, - LineSegments, - Matrix4, - Mesh, - WireframeGeometry -} from '../../../src/Three'; - -export class LineSegmentsGeometry extends InstancedBufferGeometry { - - constructor(); - readonly isLineSegmentsGeometry: true; - - applyMatrix4( matrix: Matrix4 ): this; - computeBoundingBox(): void; - computeBoundingSphere(): void; - fromEdgesGeometry( geometry: WireframeGeometry ): this; - fromLineSegments( lineSegments: LineSegments ): this; - fromMesh( mesh: Mesh ): this; - fromWireframeGeometry( geometry: EdgesGeometry ): this; - setColors( array: number[] | Float32Array ): this; - setPositions( array: number[] | Float32Array ): this; - -} diff --git a/examples/jsm/lines/Wireframe.d.ts b/examples/jsm/lines/Wireframe.d.ts deleted file mode 100644 index 9c3648ea34f11e..00000000000000 --- a/examples/jsm/lines/Wireframe.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Mesh, -} from '../../../src/Three'; - -import { LineMaterial } from './LineMaterial'; -import { LineSegmentsGeometry } from './LineSegmentsGeometry'; - -export class Wireframe extends Mesh { - - constructor( geometry?: LineSegmentsGeometry, material?: LineMaterial ); - readonly isWireframe: true; - - computeLineDistances(): this; - -} diff --git a/examples/jsm/lines/WireframeGeometry2.d.ts b/examples/jsm/lines/WireframeGeometry2.d.ts deleted file mode 100644 index 5ece27a702047c..00000000000000 --- a/examples/jsm/lines/WireframeGeometry2.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - BufferGeometry, - Geometry -} from '../../../src/Three'; - -import { LineSegmentsGeometry } from './LineSegmentsGeometry'; - -export class WireframeGeometry2 extends LineSegmentsGeometry { - - constructor( geometry: Geometry | BufferGeometry ); - readonly sWireframeGeometry2: boolean; - -} diff --git a/examples/jsm/loaders/3DMLoader.d.ts b/examples/jsm/loaders/3DMLoader.d.ts deleted file mode 100644 index 981954a8d9e009..00000000000000 --- a/examples/jsm/loaders/3DMLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - Loader, - LoadingManager, - Object3D -} from '../../../src/Three'; - -export class Rhino3dmLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( object: Object3D ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBufferLike, onLoad: ( object: Object3D ) => void, onError?: ( event: ErrorEvent ) => void ): void; - setLibraryPath( path: string ): Rhino3dmLoader; - setWorkerLimit( workerLimit: number ): Rhino3dmLoader; - dispose(): Rhino3dmLoader; - -} diff --git a/examples/jsm/loaders/3MFLoader.d.ts b/examples/jsm/loaders/3MFLoader.d.ts deleted file mode 100644 index 5a52717516b41e..00000000000000 --- a/examples/jsm/loaders/3MFLoader.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { - Loader, - LoadingManager, - Group -} from '../../../src/Three'; - -export class ThreeMFLoader extends Loader { - - constructor( manager?: LoadingManager ); - availableExtensions: object[]; - - load( url: string, onLoad: ( object: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ): Group; - addExtension( extension: object ): void - -} diff --git a/examples/jsm/loaders/AMFLoader.d.ts b/examples/jsm/loaders/AMFLoader.d.ts deleted file mode 100644 index 6791ffb83336a9..00000000000000 --- a/examples/jsm/loaders/AMFLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Loader, - LoadingManager, - Group -} from '../../../src/Three'; - -export class AMFLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( object: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ): Group; - -} diff --git a/examples/jsm/loaders/AssimpLoader.d.ts b/examples/jsm/loaders/AssimpLoader.d.ts deleted file mode 100644 index 3ea87269465eba..00000000000000 --- a/examples/jsm/loaders/AssimpLoader.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - Object3D, - Loader, - LoadingManager -} from '../../../src/Three'; - - -export interface Assimp { - animation: any; - object: Object3D; -} - -export class AssimpLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( result: Assimp ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( buffer: ArrayBuffer, path: string ) : Assimp; - -} diff --git a/examples/jsm/loaders/BVHLoader.d.ts b/examples/jsm/loaders/BVHLoader.d.ts deleted file mode 100644 index 9b5ff31b36f1fd..00000000000000 --- a/examples/jsm/loaders/BVHLoader.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - AnimationClip, - Skeleton, - Loader, - LoadingManager -} from '../../../src/Three'; - - -export interface BVH { - clip: AnimationClip; - skeleton: Skeleton; -} - -export class BVHLoader extends Loader { - - constructor( manager?: LoadingManager ); - animateBonePositions: boolean; - animateBoneRotations: boolean; - - load( url: string, onLoad: ( bvh: BVH ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( text: string ) : BVH; - -} diff --git a/examples/jsm/loaders/BasisTextureLoader.d.ts b/examples/jsm/loaders/BasisTextureLoader.d.ts deleted file mode 100644 index 39f4b7397fb585..00000000000000 --- a/examples/jsm/loaders/BasisTextureLoader.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { - CompressedTexture, - Loader, - LoadingManager, - WebGLRenderer -} from '../../../src/Three'; - -export class BasisTextureLoader extends Loader { - - constructor( manager?: LoadingManager ); - transcoderBinary: ArrayBuffer | null; - transcoderPath: string; - transcoderPending: Promise | null; - - workerConfig: { - format: number; - astcSupported: boolean; - etcSupported: boolean; - dxtSupported: boolean; - pvrtcSupported: boolean; - } - workerLimit: number; - workerNextTaskID: number; - workerPool: object[]; - workerSourceURL: string; - - detectSupport( renderer: WebGLRenderer ): this; - load( url: string, onLoad: ( texture: CompressedTexture ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setTranscoderPath( path: string ): this; - setWorkerLimit( workerLimit: number ): this; - dispose(): void; - -} diff --git a/examples/jsm/loaders/ColladaLoader.d.ts b/examples/jsm/loaders/ColladaLoader.d.ts deleted file mode 100644 index e3b49228bc62a0..00000000000000 --- a/examples/jsm/loaders/ColladaLoader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - Loader, - LoadingManager, - Scene -} from '../../../src/Three'; - - -export interface Collada { - kinematics: object; - library: object; - scene: Scene; -} - -export class ColladaLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( collada: Collada ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( text: string, path: string ) : Collada; - -} diff --git a/examples/jsm/loaders/DDSLoader.d.ts b/examples/jsm/loaders/DDSLoader.d.ts deleted file mode 100644 index b9d2e041c34023..00000000000000 --- a/examples/jsm/loaders/DDSLoader.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - LoadingManager, - CompressedTextureLoader, - PixelFormat, - CompressedPixelFormat -} from '../../../src/Three'; - -export interface DDS { - mipmaps: object[]; - width: number; - height: number; - format: PixelFormat | CompressedPixelFormat; - mipmapCount: number; - isCubemap: boolean; -} - -export class DDSLoader extends CompressedTextureLoader { - - constructor( manager?: LoadingManager ); - - parse( buffer: ArrayBuffer, loadMipmaps: boolean ) : DDS; - -} diff --git a/examples/jsm/loaders/DRACOLoader.d.ts b/examples/jsm/loaders/DRACOLoader.d.ts deleted file mode 100644 index 65031c5a5107d6..00000000000000 --- a/examples/jsm/loaders/DRACOLoader.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - Loader, - LoadingManager, - BufferGeometry -} from '../../../src/Three'; - -export class DRACOLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setDecoderPath( path: string ): DRACOLoader; - setDecoderConfig( config: object ): DRACOLoader; - setWorkerLimit( workerLimit: number ): DRACOLoader; - preload(): DRACOLoader; - dispose(): DRACOLoader; - -} diff --git a/examples/jsm/loaders/EXRLoader.d.ts b/examples/jsm/loaders/EXRLoader.d.ts deleted file mode 100644 index 68b4231a52fa8c..00000000000000 --- a/examples/jsm/loaders/EXRLoader.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - LoadingManager, - DataTextureLoader, - TextureDataType, - PixelFormat -} from '../../../src/Three'; - -export interface EXR { - header: object; - width: number; - height: number; - data: Float32Array; - format: PixelFormat; - type: TextureDataType; -} - -export class EXRLoader extends DataTextureLoader { - - constructor( manager?: LoadingManager ); - type: TextureDataType; - - parse( buffer: ArrayBuffer ) : EXR; - setDataType( type: TextureDataType ): this; - -} diff --git a/examples/jsm/loaders/FBXLoader.d.ts b/examples/jsm/loaders/FBXLoader.d.ts deleted file mode 100644 index 8a8cd7be04f5b6..00000000000000 --- a/examples/jsm/loaders/FBXLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Group, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class FBXLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( object: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( FBXBuffer: ArrayBuffer | string, path: string ) : Group; - -} diff --git a/examples/jsm/loaders/GCodeLoader.d.ts b/examples/jsm/loaders/GCodeLoader.d.ts deleted file mode 100644 index b6ad7b784873da..00000000000000 --- a/examples/jsm/loaders/GCodeLoader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Group, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class GCodeLoader extends Loader { - - constructor( manager?: LoadingManager ); - splitLayer: boolean; - - load( url: string, onLoad: ( object: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: string ) : Group; - -} diff --git a/examples/jsm/loaders/GLTFLoader.d.ts b/examples/jsm/loaders/GLTFLoader.d.ts deleted file mode 100644 index 98df26d1c12b85..00000000000000 --- a/examples/jsm/loaders/GLTFLoader.d.ts +++ /dev/null @@ -1,84 +0,0 @@ -import { - AnimationClip, - Camera, - Group, - Loader, - LoadingManager, - Mesh, - Object3D, - Material, - SkinnedMesh, - Texture -} from '../../../src/Three'; - -import { DRACOLoader } from './DRACOLoader'; -import { DDSLoader } from './DDSLoader'; -import { KTX2Loader } from './KTX2Loader'; - -export interface GLTF { - animations: AnimationClip[]; - scene: Group; - scenes: Group[]; - cameras: Camera[]; - asset: { - copyright?: string; - generator?: string; - version?: string; - minVersion?: string; - extensions?: any; - extras?: any; - }; - parser: GLTFParser; - userData: any; -} - -export class GLTFLoader extends Loader { - - constructor( manager?: LoadingManager ); - dracoLoader: DRACOLoader | null; - ddsLoader: DDSLoader | null; - - load( url: string, onLoad: ( gltf: GLTF ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - - setDRACOLoader( dracoLoader: DRACOLoader ): GLTFLoader; - setDDSLoader( ddsLoader: DDSLoader ): GLTFLoader; - - register( callback: ( parser: GLTFParser ) => GLTFLoaderPlugin ): GLTFLoader; - unregister( callback: ( parser: GLTFParser ) => GLTFLoaderPlugin ): GLTFLoader; - - setKTX2Loader( ktx2Loader: KTX2Loader ): GLTFLoader; - setMeshoptDecoder( meshoptDecoder: /* MeshoptDecoder */ any ): GLTFLoader; - - parse( data: ArrayBuffer | string, path: string, onLoad: ( gltf: GLTF ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - -} - -export interface GLTFReference { - type: 'materials'|'nodes'|'textures'; - index: number; -} - -export class GLTFParser { - - json: any; - - associations: Map; - - getDependency: ( type: string, index: number ) => Promise; - getDependencies: ( type: string ) => Promise; - assignFinalMaterial: ( object: Mesh ) => void; - -} - -export interface GLTFLoaderPlugin { - - loadMesh?: ( meshIndex: number ) => Promise | null; - loadBufferView?: ( bufferViewIndex: number ) => Promise | null; - loadMaterial?: ( materialIndex: number ) => Promise | null; - loadTexture?: ( textureIndex: number ) => Promise | null; - getMaterialType?: ( materialIndex: number ) => typeof Material | null; - extendMaterialParams?: ( materialIndex: number, materialParams: { [ key: string ]: any } ) => Promise | null; - createNodeAttachment?: ( nodeIndex: number ) => Promise | null; - -} diff --git a/examples/jsm/loaders/HDRCubeTextureLoader.d.ts b/examples/jsm/loaders/HDRCubeTextureLoader.d.ts deleted file mode 100644 index 72a57413cd13bd..00000000000000 --- a/examples/jsm/loaders/HDRCubeTextureLoader.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { - CubeTexture, - Loader, - LoadingManager, - TextureDataType -} from '../../../src/Three'; - -import { RGBELoader } from './RGBELoader'; - -export class HDRCubeTextureLoader extends Loader { - - constructor( manager?: LoadingManager ); - hdrLoader: RGBELoader; - type: TextureDataType; - - load( urls: string[], onLoad: ( texture: CubeTexture ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setDataType( type: TextureDataType ): this; - -} diff --git a/examples/jsm/loaders/KMZLoader.d.ts b/examples/jsm/loaders/KMZLoader.d.ts deleted file mode 100644 index c6c85214c07c58..00000000000000 --- a/examples/jsm/loaders/KMZLoader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Loader, - LoadingManager -} from '../../../src/Three'; - -import { Collada } from './ColladaLoader'; - -export class KMZLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( kmz: Collada ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ): Collada; - -} diff --git a/examples/jsm/loaders/KTX2Loader.d.ts b/examples/jsm/loaders/KTX2Loader.d.ts deleted file mode 100644 index 778d7a5d1a1e4e..00000000000000 --- a/examples/jsm/loaders/KTX2Loader.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - LoadingManager, - CompressedTextureLoader, - CompressedTexture, - WebGLRenderer -} from '../../../src/Three'; - -export class KTX2Loader extends CompressedTextureLoader { - - constructor( manager?: LoadingManager ); - - setTranscoderPath( path: string ): KTX2Loader; - setWorkerLimit( limit: number ): KTX2Loader; - detectSupport( renderer: WebGLRenderer ): KTX2Loader; - dispose(): KTX2Loader; - - parse( - buffer: ArrayBuffer, - onLoad: ( texture: CompressedTexture ) => void, - onError?: ( event: ErrorEvent ) => void - ): KTX2Loader; - -} diff --git a/examples/jsm/loaders/KTXLoader.d.ts b/examples/jsm/loaders/KTXLoader.d.ts deleted file mode 100644 index 3d08ab35feb863..00000000000000 --- a/examples/jsm/loaders/KTXLoader.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - LoadingManager, - CompressedTextureLoader, - PixelFormat, - CompressedPixelFormat -} from '../../../src/Three'; - -export interface KTX { - mipmaps: object[]; - width: number; - height: number; - format: PixelFormat | CompressedPixelFormat; - mipmapCount: number; - isCubemap: boolean; -} - -export class KTXLoader extends CompressedTextureLoader { - - constructor( manager?: LoadingManager ); - - parse( buffer: ArrayBuffer, loadMipmaps: boolean ) : KTX; - -} diff --git a/examples/jsm/loaders/LDrawLoader.d.ts b/examples/jsm/loaders/LDrawLoader.d.ts deleted file mode 100644 index a9b8aed8a26ced..00000000000000 --- a/examples/jsm/loaders/LDrawLoader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - Loader, - LoadingManager, - Group, - Material -} from '../../../src/Three'; - -export class LDrawLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( data: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setFileMap( fileMap: Record ): void; - setMaterials( materials: Material[] ): void; - - parse( text: string, path: string, onLoad: ( data: Group ) => void ): void; - - addMaterial( material: Material ): void; - getMaterial( colourCode: string ): Material | null; - -} diff --git a/examples/jsm/loaders/LUT3dlLoader.d.ts b/examples/jsm/loaders/LUT3dlLoader.d.ts deleted file mode 100644 index 3852c004df7238..00000000000000 --- a/examples/jsm/loaders/LUT3dlLoader.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { - Loader, - LoadingManager, - DataTexture, - DataTexture3D, -} from '../../../src/Three'; - -export interface LUT3dlResult { - - size: number; - texture: DataTexture; - texture3D: DataTexture3D; - -} - -export class LUT3dlLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( result: LUT3dlResult ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: Error ) => void - ); - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: string ): LUT3dlResult; - -} diff --git a/examples/jsm/loaders/LUTCubeLoader.d.ts b/examples/jsm/loaders/LUTCubeLoader.d.ts deleted file mode 100644 index 101a01a9438701..00000000000000 --- a/examples/jsm/loaders/LUTCubeLoader.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - Loader, - LoadingManager, - Vector3, - DataTexture, - DataTexture3D, -} from '../../../src/Three'; - -export interface LUTCubeResult { - - title: string; - size: number; - domainMin: Vector3; - domainMax: Vector3; - texture: DataTexture; - texture3D: DataTexture3D; - -} - -export class LUTCubeLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( result: LUTCubeResult ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: Error ) => void - ); - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: string ): LUTCubeResult; - -} diff --git a/examples/jsm/loaders/LWOLoader.d.ts b/examples/jsm/loaders/LWOLoader.d.ts deleted file mode 100644 index 7c7a20af41f4ed..00000000000000 --- a/examples/jsm/loaders/LWOLoader.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { - Loader, - LoadingManager, - Material, - Object3D -} from '../../../src/Three'; - -export interface LWO { - materials: Material[]; - meshes: Object3D[]; -} - -export interface LWOLoaderParameters { - - /** - * Base content delivery folder path, use when it differs from Lightwave default structure - */ - resourcePath?: string; - -} - -export class LWOLoader extends Loader { - - constructor( manager?: LoadingManager, parameters?: LWOLoaderParameters ); - - load( url: string, onLoad: ( lwo: LWO ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer, path: string, modelName: string ): LWO; - -} diff --git a/examples/jsm/loaders/LottieLoader.d.ts b/examples/jsm/loaders/LottieLoader.d.ts deleted file mode 100644 index 1593dad44cf920..00000000000000 --- a/examples/jsm/loaders/LottieLoader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - CanvasTexture, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class LottieLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( texture: CanvasTexture ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - - setQuality( value: Number ) : void; - -} diff --git a/examples/jsm/loaders/MD2Loader.d.ts b/examples/jsm/loaders/MD2Loader.d.ts deleted file mode 100644 index 9959b136615eb4..00000000000000 --- a/examples/jsm/loaders/MD2Loader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class MD2Loader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ): BufferGeometry; - -} diff --git a/examples/jsm/loaders/MDDLoader.d.ts b/examples/jsm/loaders/MDDLoader.d.ts deleted file mode 100644 index 188d7ae60068f2..00000000000000 --- a/examples/jsm/loaders/MDDLoader.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - AnimationClip, - BufferAttribute, - Loader, - LoadingManager -} from '../../../src/Three'; - -export interface MDD { - morphTargets: BufferAttribute[]; - clip: AnimationClip; -} - -export class MDDLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( result: MDD ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ) : MDD; - -} diff --git a/examples/jsm/loaders/MMDLoader.d.ts b/examples/jsm/loaders/MMDLoader.d.ts deleted file mode 100644 index 9be5c09a8cb431..00000000000000 --- a/examples/jsm/loaders/MMDLoader.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - AnimationClip, - FileLoader, - Loader, - LoadingManager, - SkinnedMesh -} from '../../../src/Three'; - -export interface MMDLoaderAnimationObject { - animation: AnimationClip; - mesh: SkinnedMesh; -} - -export class MMDLoader extends Loader { - - constructor( manager?: LoadingManager ); - animationBuilder: object; - animationPath: string; - loader: FileLoader; - meshBuilder: object; - parser: object | null; - - load( url: string, onLoad: ( mesh: SkinnedMesh ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - loadAnimation( url: string, object: SkinnedMesh | THREE.Camera, onLoad: ( object: SkinnedMesh | AnimationClip ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadPMD( url: string, onLoad: ( object: object ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadPMX( url: string, onLoad: ( object: object ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadVMD( url: string, onLoad: ( object: object ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadVPD( url: string, isUnicode: boolean, onLoad: ( object: object ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadWithAnimation( url: string, vmdUrl: string | string[], onLoad: ( object: MMDLoaderAnimationObject ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - setAnimationPath( animationPath: string ): this; - -} diff --git a/examples/jsm/loaders/MTLLoader.d.ts b/examples/jsm/loaders/MTLLoader.d.ts deleted file mode 100644 index bea7e397000039..00000000000000 --- a/examples/jsm/loaders/MTLLoader.d.ts +++ /dev/null @@ -1,105 +0,0 @@ -import { - Material, - LoadingManager, - Mapping, - Loader, - BufferGeometry, - Side, - Texture, - Vector2, - Wrapping -} from '../../../src/Three'; - -export interface MaterialCreatorOptions { - /** - * side: Which side to apply the material - * THREE.FrontSide (default), THREE.BackSide, THREE.DoubleSide - */ - side?: Side; - /* - * wrap: What type of wrapping to apply for textures - * THREE.RepeatWrapping (default), THREE.ClampToEdgeWrapping, THREE.MirroredRepeatWrapping - */ - wrap?: Wrapping; - /* - * normalizeRGB: RGBs need to be normalized to 0-1 from 0-255 - * Default: false, assumed to be already normalized - */ - normalizeRGB?: boolean; - /* - * ignoreZeroRGBs: Ignore values of RGBs (Ka,Kd,Ks) that are all 0's - * Default: false - */ - ignoreZeroRGBs?: boolean; - /* - * invertTrProperty: Use values 1 of Tr field for fully opaque. This option is useful for obj - * exported from 3ds MAX, vcglib or meshlab. - * Default: false - */ - invertTrProperty?: boolean; -} - -export class MTLLoader extends Loader { - - constructor( manager?: LoadingManager ); - materialOptions: MaterialCreatorOptions; - - load( url: string, onLoad: ( materialCreator: MTLLoader.MaterialCreator ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - parse( text: string, path: string ) : MTLLoader.MaterialCreator; - setMaterialOptions( value: MaterialCreatorOptions ) : void; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} - -export interface MaterialInfo { - ks?: number[]; - kd?: number[]; - ke?: number[]; - map_kd?: string; - map_ks?: string; - map_ke?: string; - norm?: string; - map_bump?: string; - bump?: string; - map_d?: string; - ns?: number; - d?: number; - tr?: number; -} - -export interface TexParams { - scale: Vector2; - offset: Vector2; - url: string; -} - -export namespace MTLLoader { - export class MaterialCreator { - - constructor( baseUrl?: string, options?: MaterialCreatorOptions ); - - baseUrl : string; - options : MaterialCreatorOptions; - materialsInfo : {[key: string]: MaterialInfo}; - materials : {[key: string]: Material}; - private materialsArray : Material[]; - nameLookup : {[key: string]: number}; - side : Side; - wrap : Wrapping; - crossOrigin : string; - - setCrossOrigin( value: string ) : this; - setManager( value: LoadingManager ) : void; - setMaterials( materialsInfo: {[key: string]: MaterialInfo} ) : void; - convert( materialsInfo: {[key: string]: MaterialInfo} ) : {[key: string]: MaterialInfo}; - preload() : void; - getIndex( materialName: string ) : Material; - getAsArray() : Material[]; - create( materialName: string ) : Material; - createMaterial_( materialName: string ) : Material; - getTextureParams( value: string, matParams: any ) : TexParams; - loadTexture( url: string, mapping?: Mapping, onLoad?: ( bufferGeometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): Texture; - - } -} diff --git a/examples/jsm/loaders/NRRDLoader.d.ts b/examples/jsm/loaders/NRRDLoader.d.ts deleted file mode 100644 index e661337623fff0..00000000000000 --- a/examples/jsm/loaders/NRRDLoader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - LoadingManager -} from '../../../src/Three'; - -import { - Volume -} from '../misc/Volume'; - -export class NRRDLoader { - - constructor( manager?: LoadingManager ); - manager: LoadingManager; - path: string; - - fieldFunctions: object; - - load( url: string, onLoad: ( group: Volume ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - parse( data: string ) : Volume; - parseChars( array: number[], start?: number, end?: number ) : string; - setPath( value: string ) : this; - -} diff --git a/examples/jsm/loaders/OBJLoader.d.ts b/examples/jsm/loaders/OBJLoader.d.ts deleted file mode 100644 index f65e1929cfec76..00000000000000 --- a/examples/jsm/loaders/OBJLoader.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { - Loader, - LoadingManager, - Group -} from '../../../src/Three'; -import { - MTLLoader -} from './MTLLoader'; - -export class OBJLoader extends Loader { - - constructor( manager?: LoadingManager ); - materials: MTLLoader.MaterialCreator; - - load( url: string, onLoad: ( group: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: string ) : Group; - setMaterials( materials: MTLLoader.MaterialCreator ) : this; - -} diff --git a/examples/jsm/loaders/PCDLoader.d.ts b/examples/jsm/loaders/PCDLoader.d.ts deleted file mode 100644 index e667a769cab128..00000000000000 --- a/examples/jsm/loaders/PCDLoader.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { - Points, - Loader, - LoadingManager -} from '../../../src/Three'; - - -export class PCDLoader extends Loader { - - constructor( manager?: LoadingManager ); - littleEndian: boolean; - - load( url: string, onLoad: ( points: Points ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer | string, url: string ) : Points; - -} diff --git a/examples/jsm/loaders/PDBLoader.d.ts b/examples/jsm/loaders/PDBLoader.d.ts deleted file mode 100644 index b02bd4362e4a19..00000000000000 --- a/examples/jsm/loaders/PDBLoader.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - -export interface PDB { - geometryAtoms: BufferGeometry; - geometryBonds: BufferGeometry; - json: { - atoms: any[][] - } -} - - -export class PDBLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( pdb: PDB ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( text: string ) : PDB; - -} diff --git a/examples/jsm/loaders/PLYLoader.d.ts b/examples/jsm/loaders/PLYLoader.d.ts deleted file mode 100644 index 35b1f72c06318c..00000000000000 --- a/examples/jsm/loaders/PLYLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - - -export class PLYLoader extends Loader { - - constructor( manager?: LoadingManager ); - propertyNameMapping: object; - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setPropertyNameMapping( mapping: object ) : void; - parse( data: ArrayBuffer | string ) : BufferGeometry; - -} diff --git a/examples/jsm/loaders/PRWMLoader.d.ts b/examples/jsm/loaders/PRWMLoader.d.ts deleted file mode 100644 index 8ddb95d2798a68..00000000000000 --- a/examples/jsm/loaders/PRWMLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - - -export class PRWMLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ) : BufferGeometry; - - static isBigEndianPlatform(): boolean; - -} diff --git a/examples/jsm/loaders/PVRLoader.d.ts b/examples/jsm/loaders/PVRLoader.d.ts deleted file mode 100644 index bda0f100dcdbe2..00000000000000 --- a/examples/jsm/loaders/PVRLoader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - LoadingManager, - CompressedTextureLoader, - CompressedPixelFormat -} from '../../../src/Three'; - -export interface PVR { - mipmaps: object[]; - width: number; - height: number; - format: CompressedPixelFormat; - mipmapCount: number; - isCubemap: boolean; -} - -export class PVRLoader extends CompressedTextureLoader { - - constructor( manager?: LoadingManager ); - - parse( buffer: ArrayBuffer, loadMipmaps: boolean ): PVR; - -} diff --git a/examples/jsm/loaders/RGBELoader.d.ts b/examples/jsm/loaders/RGBELoader.d.ts deleted file mode 100644 index 7c7b19ba9da2b8..00000000000000 --- a/examples/jsm/loaders/RGBELoader.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { - LoadingManager, - DataTextureLoader, - TextureDataType, - PixelFormat -} from '../../../src/Three'; - -export interface RGBE { - width: number; - height: number; - data: Float32Array | Uint8Array; - header: string; - gamma: number; - exposure: number; - format: PixelFormat; - type: TextureDataType; -} - -export class RGBELoader extends DataTextureLoader { - - constructor( manager?: LoadingManager ); - type: TextureDataType; - - parse( buffer: ArrayBuffer ): RGBE; - setDataType( type: TextureDataType ): this; - -} diff --git a/examples/jsm/loaders/RGBMLoader.d.ts b/examples/jsm/loaders/RGBMLoader.d.ts deleted file mode 100644 index 02e34e2e7cea61..00000000000000 --- a/examples/jsm/loaders/RGBMLoader.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { - CubeTexture, - LoadingManager, - DataTextureLoader, - PixelFormat, - TextureDataType, - TextureEncoding -} from '../../../src/Three'; - -export interface RGBM { - width: number; - height: number; - data: Uint8Array; - header: string; - format: PixelFormat; - type: TextureDataType; - flipY: boolean; - encoding: TextureEncoding; -} - -export class RGBMLoader extends DataTextureLoader { - - constructor( manager?: LoadingManager ); - - loadCubemap( - urls: Array, - onLoad?: ( texture: CubeTexture ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): CubeTexture; - - parse( buffer: ArrayBuffer ): RGBM; - -} diff --git a/examples/jsm/loaders/STLLoader.d.ts b/examples/jsm/loaders/STLLoader.d.ts deleted file mode 100644 index fd47161492b751..00000000000000 --- a/examples/jsm/loaders/STLLoader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - - -export class STLLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer | string ) : BufferGeometry; - -} diff --git a/examples/jsm/loaders/SVGLoader.d.ts b/examples/jsm/loaders/SVGLoader.d.ts deleted file mode 100644 index 7eac0b74a14024..00000000000000 --- a/examples/jsm/loaders/SVGLoader.d.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { - Loader, - LoadingManager, - ShapePath, - BufferGeometry, - Vector3 -} from '../../../src/Three'; - -interface SVGResultPaths extends ShapePath { - userData?: { - [key: string]: any - } -} - -export interface SVGResult { - paths: SVGResultPaths[]; - xml: XMLDocument; -} - -export interface StrokeStyle { - strokeColor: string; - strokeWidth: number; - strokeLineJoin: string; - strokeLineCap: string; - strokeMiterLimit: number; -} - -export class SVGLoader extends Loader { - - constructor( manager?: LoadingManager ); - - defaultDPI: number; - defaultUnit: string; - - load( url: string, onLoad: ( data: SVGResult ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( text: string ) : SVGResult; - - static getStrokeStyle( width?: number, color?: string, lineJoin?: string, lineCap?: string, miterLimit?: number ): StrokeStyle; - static pointsToStroke( points: Vector3[], style: StrokeStyle, arcDivisions?: number, minDistance?: number ): BufferGeometry; - static pointsToStrokeWithBuffers( points: Vector3[], style: StrokeStyle, arcDivisions?: number, minDistance?: number, vertices?: number[], normals?: number[], uvs?: number[], vertexOffset?: number ): number; - -} diff --git a/examples/jsm/loaders/TDSLoader.d.ts b/examples/jsm/loaders/TDSLoader.d.ts deleted file mode 100644 index 5a16cc42d7d809..00000000000000 --- a/examples/jsm/loaders/TDSLoader.d.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { - Color, - Group, - Loader, - LoadingManager, - Material, - Mesh, - Texture -} from '../../../src/Three'; - -export class TDSLoader extends Loader { - - constructor( manager?: LoadingManager ); - debug: boolean; - group: Group; - manager: LoadingManager; - materials: Material[]; - meshes: Mesh[]; - position: number; - - load( url: string, onLoad: ( object: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( arraybuffer: ArrayBuffer, path: string ): Group; - - debugMessage( message: object ): void; - endChunk( chunk: object ): void; - nextChunk( data: DataView, chunk: object ): void; - readByte( data: DataView ): number; - readChunk( data: DataView ): object; - readColor( data: DataView ): Color; - readDWord( data: DataView ): number; - readFaceArray( data: DataView, mesh: Mesh ): void; - readFile( arraybuffer: ArrayBuffer, path: string ): void; - readFloat( data: DataView ): number; - readInt( data: DataView ): number; - readMap( data: DataView, path: string ): Texture; - readMesh( data: DataView ): Mesh; - readMeshData( data: DataView, path: string ): void; - readMaterialEntry( data: DataView, path: string ): void; - readMaterialGroup( data: DataView ): object; - readNamedObject( data: DataView ): void; - readShort( data: DataView ): number; - readString( data: DataView, maxLength: number ): string; - readWord( data: DataView ): number; - resetPosition(): void; - -} diff --git a/examples/jsm/loaders/TGALoader.d.ts b/examples/jsm/loaders/TGALoader.d.ts deleted file mode 100644 index ed071859b3e27b..00000000000000 --- a/examples/jsm/loaders/TGALoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Texture, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class TGALoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( texture: Texture ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ) : Texture; - -} diff --git a/examples/jsm/loaders/TTFLoader.d.ts b/examples/jsm/loaders/TTFLoader.d.ts deleted file mode 100644 index f3c37a6ab5a9cf..00000000000000 --- a/examples/jsm/loaders/TTFLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Loader, - LoadingManager -} from '../../../src/Three'; - -export class TTFLoader extends Loader { - - constructor( manager?: LoadingManager ); - reversed: boolean; - - load( url: string, onLoad: ( json: object ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( arraybuffer: ArrayBuffer ): object; - -} diff --git a/examples/jsm/loaders/TiltLoader.d.ts b/examples/jsm/loaders/TiltLoader.d.ts deleted file mode 100644 index f2911ae55c83bb..00000000000000 --- a/examples/jsm/loaders/TiltLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Loader, - LoadingManager, - Group -} from '../../../src/Three'; - -export class TiltLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( object: Group ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer ): Group; - -} diff --git a/examples/jsm/loaders/VOXLoader.d.ts b/examples/jsm/loaders/VOXLoader.d.ts deleted file mode 100644 index 4780761c2002d8..00000000000000 --- a/examples/jsm/loaders/VOXLoader.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Loader, - LoadingManager -} from '../../../src/Three'; - -export class VOXLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( chunks: Array ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise>; - parse( data: ArrayBuffer ): Array; - -} diff --git a/examples/jsm/loaders/VRMLLoader.d.ts b/examples/jsm/loaders/VRMLLoader.d.ts deleted file mode 100644 index d6eb14ece93436..00000000000000 --- a/examples/jsm/loaders/VRMLLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Scene, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class VRMLLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( scene: Scene ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: string, path: string ) : Scene; - -} diff --git a/examples/jsm/loaders/VRMLoader.d.ts b/examples/jsm/loaders/VRMLoader.d.ts deleted file mode 100644 index f138025b0d86a9..00000000000000 --- a/examples/jsm/loaders/VRMLoader.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - Loader, - LoadingManager -} from '../../../src/Three'; - -import { GLTFLoader, GLTF } from './GLTFLoader'; -import { DRACOLoader } from './DRACOLoader'; - -export class VRMLoader extends Loader { - - constructor( manager?: LoadingManager ); - gltfLoader: GLTFLoader; - - load( url: string, onLoad: ( scene: GLTF ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ) : void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( gltf: GLTF, onLoad: ( scene: GLTF ) => void ): void; - setDRACOLoader( dracoLoader: DRACOLoader ): this; - -} diff --git a/examples/jsm/loaders/VTKLoader.d.ts b/examples/jsm/loaders/VTKLoader.d.ts deleted file mode 100644 index f90ae666ed8bfb..00000000000000 --- a/examples/jsm/loaders/VTKLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class VTKLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer | string, path: string ): BufferGeometry; - -} diff --git a/examples/jsm/loaders/XLoader.d.ts b/examples/jsm/loaders/XLoader.d.ts deleted file mode 100644 index 3b7928b4fa1b79..00000000000000 --- a/examples/jsm/loaders/XLoader.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { - Mesh, - Loader, - LoadingManager -} from '../../../src/Three'; - -export interface XResult { - animations: object[]; - models: Mesh[]; -} - -export class XLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( object: XResult ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: ArrayBuffer | string, onLoad: ( object: object ) => void ): object; - -} diff --git a/examples/jsm/loaders/XYZLoader.d.ts b/examples/jsm/loaders/XYZLoader.d.ts deleted file mode 100644 index e89ef1a4e7277d..00000000000000 --- a/examples/jsm/loaders/XYZLoader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - BufferGeometry, - Loader, - LoadingManager -} from '../../../src/Three'; - -export class XYZLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( url: string, onLoad: ( geometry: BufferGeometry ) => void, onProgress?: ( event: ProgressEvent ) => void, onError?: ( event: ErrorEvent ) => void ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( data: string, onLoad: ( geometry: BufferGeometry ) => void ): object; - -} diff --git a/examples/jsm/math/Capsule.d.ts b/examples/jsm/math/Capsule.d.ts deleted file mode 100644 index 4d77b5f942d8a2..00000000000000 --- a/examples/jsm/math/Capsule.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - Vector3, - Line3, - Box3 -} from '../../../src/Three'; - -export class Capsule { - - constructor( start?: Vector3, end?: Vector3, radius?: number ); - start: Vector3; - end: Vector3; - radius: number; - - set( start: Vector3, end: Vector3, radius: number ): this; - clone(): Capsule; - copy( capsule: Capsule ): this; - getCenter( target: number ): Vector3; - translate( v: Vector3 ): this; - checkAABBAxis( p1x: number, p1y: number, p2x: number, p2y: number, minx: number, maxx: number, miny: number, maxy: number, radius: number ): boolean; - intersectsBox( box: Box3 ): boolean; - lineLineMinimumPoints( line1: Line3, line2: Line3 ): Vector3[]; - -} diff --git a/examples/jsm/math/ColorConverter.d.ts b/examples/jsm/math/ColorConverter.d.ts deleted file mode 100644 index bd00fc7f9974d2..00000000000000 --- a/examples/jsm/math/ColorConverter.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - Color -} from '../../../src/Three'; - -export interface HSL { - h: number; - s: number; - l: number; -} - -export interface CMYK { - c: number; - m: number; - y: number; - k: number; -} - -export namespace ColorConverter { - - export function setHSV( color: Color, h: number, s: number, v: number ): Color; - export function getHSV( color: Color, target: HSL ): HSL; - export function setCMYK( color: Color, c: number, m: number, y: number, k: number ): Color; - export function getCMYK( color: Color, target: CMYK ): CMYK; - -} diff --git a/examples/jsm/math/ConvexHull.d.ts b/examples/jsm/math/ConvexHull.d.ts deleted file mode 100644 index 3abf69bd56642a..00000000000000 --- a/examples/jsm/math/ConvexHull.d.ts +++ /dev/null @@ -1,103 +0,0 @@ -import { - Object3D, - Ray, - Vector3 -} from '../../../src/Three'; - -declare class Face { - - constructor(); - normal: Vector3; - midpoint: Vector3; - area: number; - constant: number; - outside: VertexNode; - mark: number; - edge: HalfEdge; - - static create( a: VertexNode, b: VertexNode, c: VertexNode ): Face; - - compute(): this; - getEdge( i: number ): HalfEdge; - -} - -declare class HalfEdge { - - constructor( vertex: VertexNode, face: Face ); - vertex: VertexNode; - prev: HalfEdge; - next: HalfEdge; - twin: HalfEdge; - face: Face; - - head(): VertexNode; - length(): number; - lengthSquared(): number; - setTwin( edge: HalfEdge ): this; - tail(): VertexNode; - -} - -declare class VertexNode { - - constructor( point: Vector3 ); - point: Vector3; - prev: VertexNode; - next: VertexNode; - face: Face; - -} - -declare class VertexList { - - constructor(); - head: VertexNode; - tail: VertexNode; - - append( vertex: VertexNode ): this; - appendChain( vertex: VertexNode ): this; - clear(): this; - first(): VertexNode; - insertAfter( target: VertexNode, vertex: VertexNode ): this; - insertBefore( target: VertexNode, vertex: VertexNode ): this; - isEmpty(): boolean; - last(): VertexNode; - remove( vertex: VertexNode ): this; - removeSubList( a: VertexNode, b: VertexNode ): this; - -} - -export class ConvexHull { - - constructor(); - tolerance: number; - faces: Face[]; - newFaces: Face[]; - assigned: VertexList; - unassigned: VertexList; - vertices: VertexNode[]; - - addAdjoiningFace( eyeVertex: VertexNode, horizonEdge: HalfEdge ): HalfEdge; - addNewFaces( eyeVertex: VertexNode, horizon: HalfEdge[] ): this; - addVertexToFace( vertex: VertexNode, face: Face ): this; - addVertexToHull( eyeVertex: VertexNode ): this; - cleanup(): this; - compute(): this; - computeExtremes(): object; - computeHorizon( eyePoint: Vector3, crossEdge: HalfEdge, face: Face, horizon: HalfEdge[] ): this; - computeInitialHull(): this; - containsPoint( point: Vector3 ): boolean; - deleteFaceVertices( face: Face, absorbingFace: Face ): this; - intersectRay( ray: Ray, target: Vector3 ): Vector3 | null; - intersectsRay( ray: Ray ): boolean; - makeEmpty(): this; - nextVertexToAdd(): VertexNode | undefined; - reindexFaces(): this; - removeAllVerticesFromFace( face: Face ): VertexNode | undefined; - removeVertexFromFace( vertex: VertexNode, face: Face ): this; - resolveUnassignedPoints( newFaces: Face[] ): this; - setFromPoints( points: Vector3[] ): this; - setFromObject( object: Object3D ): this; - -} diff --git a/examples/jsm/math/ImprovedNoise.d.ts b/examples/jsm/math/ImprovedNoise.d.ts deleted file mode 100644 index af46e63b6263c7..00000000000000 --- a/examples/jsm/math/ImprovedNoise.d.ts +++ /dev/null @@ -1,6 +0,0 @@ -export class ImprovedNoise { - - constructor(); - noise( x: number, y: number, z: number ): number; - -} diff --git a/examples/jsm/math/Lut.d.ts b/examples/jsm/math/Lut.d.ts deleted file mode 100644 index 767465209dea94..00000000000000 --- a/examples/jsm/math/Lut.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { - Color -} from '../../../src/Three'; - -export class Lut { - - constructor( colormap?: string, numberofcolors?: number ); - lut: Color[]; - map: object[]; - n: number; - minV: number; - maxV: number; - - set( value: Lut ): this; - setMin( min: number ): this; - setMax( max: number ): this; - setColorMap( colormap?: string, numberofcolors?: number ): this; - copy( lut: Lut ): this; - getColor( alpha: number ): Color; - addColorMap( colormapName: string, arrayOfColors: number[][] ): void; - createCanvas(): HTMLCanvasElement; - updateCanvas( canvas: HTMLCanvasElement ): HTMLCanvasElement; - -} - -export interface ColorMapKeywords { - rainbow: number[][]; - cooltowarm: number[][]; - blackbody: number[][]; - grayscale: number[][]; -} diff --git a/examples/jsm/math/MeshSurfaceSampler.d.ts b/examples/jsm/math/MeshSurfaceSampler.d.ts deleted file mode 100644 index 7ed730ca90b28d..00000000000000 --- a/examples/jsm/math/MeshSurfaceSampler.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - BufferGeometry, - Color, - Mesh, - Vector3 -} from '../../../src/Three'; - -export class MeshSurfaceSampler { - - distribution: Float32Array | null; - geometry: BufferGeometry; - positionAttribute: Float32Array; - weightAttribute: string | null; - - constructor( mesh: Mesh ); - binarySearch( x: number ): number; - build(): this; - sample( targetPosition: Vector3, targetNormal?: Vector3, targetColor?: Color ): this; - sampleFace( faceIndex: number, targetPosition: Vector3, targetNormal?: Vector3, targetColor?: Color ): this; - setWeightAttribute( name: string | null ): this; - -} diff --git a/examples/jsm/math/OBB.d.ts b/examples/jsm/math/OBB.d.ts deleted file mode 100644 index 38b052fabcb650..00000000000000 --- a/examples/jsm/math/OBB.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { - Box3, - Matrix3, - Matrix4, - Plane, - Ray, - Sphere, - Vector3 -} from '../../../src/Three'; - -export class OBB { - - center: Vector3; - halfSize: Vector3; - rotation: Matrix3; - - constructor( center: Vector3, halfSize: Vector3, rotation: Matrix3 ); - set( center: Vector3, halfSize: Vector3, rotation: Matrix3 ): this; - copy( obb: OBB ): this; - clone(): OBB; - getSize( result: Vector3 ): Vector3; - clampPoint( point: Vector3, result: Vector3 ): Vector3; - containsPoint( point: Vector3 ): boolean; - intersectsBox3( box3: Box3 ): boolean; - intersectsSphere( sphere: Sphere ): boolean; - intersectsOBB( obb: OBB, epsilon: number ): boolean; - intersectsPlane( plane: Plane ): boolean; - intersectRay( ray: Ray, result: Vector3 ): Vector3 | null; - intersectsRay( ray: Ray ): boolean; - fromBox3( box3: Box3 ): this; - equals( obb: OBB ): boolean; - applyMatrix4( matrix: Matrix4 ): this; - -} diff --git a/examples/jsm/math/Octree.d.ts b/examples/jsm/math/Octree.d.ts deleted file mode 100644 index 315e3cc22528be..00000000000000 --- a/examples/jsm/math/Octree.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { - Triangle, - Box3, - Ray, - Sphere, - Object3D -} from '../../../src/Three'; - -import { Capsule } from './Capsule'; - -export class Octree { - - constructor( box?: Box3 ); - triangles: Triangle[]; - box: Box3; - subTrees: Octree[]; - - addTriangle( triangle: Triangle ): this; - calcBox(): this; - split( level: number ): this; - build(): this; - getRayTriangles( ray: Ray, triangles: Triangle[] ): Triangle[]; - triangleCapsuleIntersect( capsule: Capsule, triangle: Triangle ): any; - triangleSphereIntersect( sphere: Sphere, triangle: Triangle ): any; - getSphereTriangles( sphere: Sphere, triangles: Triangle[] ): Triangle[]; - getCapsuleTriangles( capsule: Capsule, triangles: Triangle[] ): Triangle[]; - sphereIntersect( sphere: Sphere ): any; - capsuleIntersect( capsule: Capsule ): any; - rayIntersect( ray: Ray ): any; - fromGraphNode( group: Object3D ): this; - -} diff --git a/examples/jsm/math/SimplexNoise.d.ts b/examples/jsm/math/SimplexNoise.d.ts deleted file mode 100644 index 6085f669202eb8..00000000000000 --- a/examples/jsm/math/SimplexNoise.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -export class SimplexNoise { - - constructor( r?: object ); - dot( g: number[], x: number, y: number ): number; - dot3( g: number[], x: number, y: number, z: number ): number; - dot4( g: number[], x: number, y: number, z: number, w: number ): number; - noise( xin: number, yin: number ): number; - noise3d( xin: number, yin: number, zin: number ): number; - noise4d( x: number, y: number, z: number, w: number ): number; - -} diff --git a/examples/jsm/misc/ConvexObjectBreaker.d.ts b/examples/jsm/misc/ConvexObjectBreaker.d.ts deleted file mode 100644 index ea82580e0908cb..00000000000000 --- a/examples/jsm/misc/ConvexObjectBreaker.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - Object3D, - Plane, - Vector3 -} from '../../../src/Three'; - -export interface CutByPlaneOutput { - object1: Object3D; - object2: Object3D; -} - -export class ConvexObjectBreaker { - - constructor( minSizeForBreak?: number, smallDelta?: number ); - prepareBreakableObject( object: Object3D, mass: number, velocity: Vector3, angularVelocity: Vector3, breakable: boolean ): void; - subdivideByImpact( object: Object3D, pointOfImpact: Vector3, normal: Vector3, maxRadialIterations: number, maxRandomIterations: number ): Object3D[]; - cutByPlane( object: Object3D, plane: Plane, output: CutByPlaneOutput ): number; - -} diff --git a/examples/jsm/misc/GPUComputationRenderer.d.ts b/examples/jsm/misc/GPUComputationRenderer.d.ts deleted file mode 100644 index f95ff5140b5095..00000000000000 --- a/examples/jsm/misc/GPUComputationRenderer.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { - WebGLRenderer, - RenderTarget, - Texture, - DataTexture, - Material, - ShaderMaterial, - Wrapping, - TextureFilter, - TextureDataType -} from '../../../src/Three'; - -export interface Variable { - name: string; - initialValueTexture: Texture; - material: ShaderMaterial; - dependencies: Variable[]; - renderTargets: RenderTarget[]; - wrapS: number; - wrapT: number; - minFilter: number; - magFilter: number; -} - -export class GPUComputationRenderer { - - constructor( sizeX: number, sizeY: number, renderer: WebGLRenderer ); - - setDataType ( type: TextureDataType ): void; - - addVariable( variableName: string, computeFragmentShader: string, initialValueTexture: Texture ): Variable; - setVariableDependencies( variable: Variable, dependencies: Variable[] | null ): void; - - init(): string | null; - compute(): void; - - getCurrentRenderTarget( variable: Variable ): RenderTarget; - getAlternateRenderTarget( variable: Variable ): RenderTarget; - addResolutionDefine( materialShader: ShaderMaterial ): void; - createRenderTarget( sizeXTexture: number, sizeYTexture: number, wrapS: Wrapping, wrapT: number, minFilter: TextureFilter, magFilter: TextureFilter ): RenderTarget; - createTexture(): DataTexture; - renderTexture( input: Texture, output: Texture ): void; - doRenderTarget( material: Material, output: RenderTarget ): void; - -} diff --git a/examples/jsm/misc/Gyroscope.d.ts b/examples/jsm/misc/Gyroscope.d.ts deleted file mode 100644 index 3ad2e77db5b6b9..00000000000000 --- a/examples/jsm/misc/Gyroscope.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { - Object3D -} from '../../../src/Three'; - -export class Gyroscope extends Object3D { - - constructor(); - -} diff --git a/examples/jsm/misc/MD2Character.d.ts b/examples/jsm/misc/MD2Character.d.ts deleted file mode 100644 index d0472d8176c160..00000000000000 --- a/examples/jsm/misc/MD2Character.d.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { - Object3D, - Mesh, - Texture, - AnimationMixer -} from '../../../src/Three'; - -export interface MD2PartsConfig { - baseUrl: string, - body: string, - skins: string[], - weapons: [string, string][], -} - -export class MD2Character { - - constructor(); - scale: number; - animationFPS: number; - root: Object3D; - meshBody: Mesh | null; - meshWeapon: Mesh | null; - skinsBody: Texture[]; - skinsWeapon: Texture[]; - weapons: Mesh[]; - activeAnimation: string | null; - mixer: AnimationMixer | null; - loadCounter: number; - - onLoadComplete(): void; - loadParts( config: MD2PartsConfig ): void; - setPlaybackRate( rate: number ): void; - setWireframe( wireframeEnabled: boolean ): void; - setSkin( index: number ): void; - setWeapon( index: number ): void; - setAnimation( clipName: string ): void; - syncWeaponAnimation(): void; - update( delta: number ): void; - -} diff --git a/examples/jsm/misc/MD2CharacterComplex.d.ts b/examples/jsm/misc/MD2CharacterComplex.d.ts deleted file mode 100644 index 910fe5054cc149..00000000000000 --- a/examples/jsm/misc/MD2CharacterComplex.d.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { - Object3D, - Mesh, - Texture -} from '../../../src/Three'; - -export class MD2CharacterComplex { - - constructor(); - scale: number; - animationFPS: number; - transitionFrames: number; - maxSpeed: number; - maxReverseSpeed: number; - frontAcceleration: number; - backAcceleration: number; - frontDecceleration: number; - angularSpeed: number; - root: Object3D; - meshBody: Mesh | null; - meshWeapon: Mesh | null; - controls: null; - skinsBody: Texture[]; - skinsWeapon: Texture[]; - weapons: Mesh[]; - currentSkin: number; - onLoadComplete: () => void; - - meshes: Mesh[]; - animations: object[]; - loadCounter: number; - speed: number; - bodyOrientation: number; - walkSpeed: number; - crouchSpeed: number; - activeAnimation: string; - oldAnimation: string; - - enableShadows( enable: boolean ): void; - setVisible( enable: boolean ): void; - shareParts( original: MD2CharacterComplex ): void; - loadParts( config: object ): void; - setPlaybackRate( rate: number ): void; - setWireframe( wireframeEnabled: boolean ): void; - setSkin( index: number ): void; - setWeapon( index: number ): void; - setAnimation( animationName: string ): void; - update( delta: number ): void; - updateAnimations( delta: number ): void; - updateBehaviors(): void; - updateMovementModel( delta: number ): void; - -} diff --git a/examples/jsm/misc/MorphAnimMesh.d.ts b/examples/jsm/misc/MorphAnimMesh.d.ts deleted file mode 100644 index 3ec28b208f77d7..00000000000000 --- a/examples/jsm/misc/MorphAnimMesh.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - AnimationAction, - AnimationMixer, - BufferGeometry, - Geometry, - Material, - Mesh -} from '../../../src/Three'; - -export class MorphAnimMesh extends Mesh { - - constructor( geometry: BufferGeometry | Geometry, material: Material ); - mixer: AnimationMixer; - activeAction: AnimationAction | null; - - setDirectionForward(): void; - setDirectionBackward(): void; - playAnimation( label: string, fps: number ): void; - updateAnimation( delta: number ): void; - copy( source: MorphAnimMesh ): this; - -} diff --git a/examples/jsm/misc/MorphBlendMesh.d.ts b/examples/jsm/misc/MorphBlendMesh.d.ts deleted file mode 100644 index a3ef71a245dd24..00000000000000 --- a/examples/jsm/misc/MorphBlendMesh.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { - BufferGeometry, - Geometry, - Material, - Mesh -} from '../../../src/Three'; - -export class MorphBlendMesh extends Mesh { - - constructor( geometry: BufferGeometry | Geometry, material: Material ); - animationsMap: object; - animationsList: object[]; - - createAnimation( name: string, start: number, end: number, fps: number ): void; - autoCreateAnimations( fps: number ): void; - setAnimationDirectionForward( name: string ): void; - setAnimationDirectionBackward( name: string ): void; - setAnimationFPS( name: string, fps: number ): void; - setAnimationDuration( name: string, duration: number ): void; - setAnimationWeight( name: string, weight: number ): void; - setAnimationTime( name: string, time: number ): void; - getAnimationTime( name: string ): number; - getAnimationDuration( name: string ): number; - playAnimation( name: string ): void; - stopAnimation( name: string ): void; - update( delta: number ): void; - -} diff --git a/examples/jsm/misc/Ocean.d.ts b/examples/jsm/misc/Ocean.d.ts deleted file mode 100644 index f228d6d8a23db0..00000000000000 --- a/examples/jsm/misc/Ocean.d.ts +++ /dev/null @@ -1,69 +0,0 @@ -import { - OrthographicCamera, - Mesh, - Scene, - ShaderMaterial, - Vector3, - WebGLRenderer, - WebGLRenderTarget, -} from '../../../src/Three'; - -export class Ocean { - - constructor( renderer: WebGLRenderer, camera?: OrthographicCamera, scene?: Scene, options?: object ); - - changed: boolean; - initial: boolean; - - oceanCamera: OrthographicCamera - renderer: WebGLRenderer; - scene: Scene; - - clearColor: number[]; - geometryOrigin: number[]; - sunDirectionX: number; - sunDirectionY: number; - sunDirectionZ: number; - oceanColor: Vector3; - skyColor: Vector3; - exposure: number; - geometryResolution: number; - geometrySize: number; - resolution: number; - floatSize: number; - windX: number; - windY: number; - size: number; - choppiness: number; - - initialSpectrumFramebuffer: WebGLRenderTarget; - spectrumFramebuffer: WebGLRenderTarget; - pingPhaseFramebuffer: WebGLRenderTarget; - pongPhaseFramebuffer: WebGLRenderTarget; - pingTransformFramebuffer: WebGLRenderTarget; - pongTransformFramebuffer: WebGLRenderTarget; - displacementMapFramebuffer: WebGLRenderTarget; - normalMapFramebuffer: WebGLRenderTarget; - - matrixNeedsUpdate: boolean; - - materialOceanHorizontal: ShaderMaterial; - materialOceanVertical: ShaderMaterial; - materialInitialSpectrum: ShaderMaterial; - materialPhase: ShaderMaterial; - materialSpectrum: ShaderMaterial; - materialNormal: ShaderMaterial; - materialOcean: ShaderMaterial; - - screenQuad: Mesh; - - generateSeedPhaseTexture(): void; - generateMesh(): void; - render(): void; - renderInitialSpectrum(): void; - renderWavePhase(): void; - renderSpectrum(): void; - renderSpectrumFFT(): void; - renderNormalMap(): void; - -} diff --git a/examples/jsm/misc/RollerCoaster.d.ts b/examples/jsm/misc/RollerCoaster.d.ts deleted file mode 100644 index 758bcc2d1d3170..00000000000000 --- a/examples/jsm/misc/RollerCoaster.d.ts +++ /dev/null @@ -1,36 +0,0 @@ -import { - BufferGeometry, - Curve, - Mesh, - Vector3 -} from '../../../src/Three'; - -export class RollerCoasterGeometry extends BufferGeometry { - - constructor( curve: Curve, divisions: number ); - -} - -export class RollerCoasterLiftersGeometry extends BufferGeometry { - - constructor( curve: Curve, divisions: number ); - -} - -export class RollerCoasterShadowGeometry extends BufferGeometry { - - constructor( curve: Curve, divisions: number ); - -} - -export class SkyGeometry extends BufferGeometry { - - constructor( curve: Curve, divisions: number ); - -} - -export class TreesGeometry extends BufferGeometry { - - constructor( landscape: Mesh ); - -} diff --git a/examples/jsm/misc/TubePainter.d.ts b/examples/jsm/misc/TubePainter.d.ts deleted file mode 100644 index 61cfb42bbef259..00000000000000 --- a/examples/jsm/misc/TubePainter.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Matrix4, - Mesh, - Vector3 -} from '../../../src/Three'; - -export class TubePainter { - - constructor(); - - mesh: Mesh; - - stroke( position1: Vector3, position2: Vector3, matrix1: Matrix4, matrix2: Matrix4 ): void; - updateGeometry( start: number, end: number ): void; - -} diff --git a/examples/jsm/misc/Volume.d.ts b/examples/jsm/misc/Volume.d.ts deleted file mode 100644 index 8cce2c6206fd8d..00000000000000 --- a/examples/jsm/misc/Volume.d.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { - Matrix3, -} from '../../../src/Three'; - -import { VolumeSlice } from './VolumeSlice.js'; - -export class Volume { - - constructor( xLength?: number, yLength?: number, zLength?: number, type?:string, arrayBuffer?: ArrayLike ); - - xLength: number; - yLength: number; - zLength: number; - - data: ArrayLike; - - spacing: number[]; - offset: number[]; - - matrix: Matrix3; - - lowerThreshold: number; - upperThreshold: number; - - sliceList: VolumeSlice[]; - - getData( i: number, j: number, k: number ): number; - access( i: number, j: number, k: number ): number; - reverseAccess( index: number ): number[]; - - map( functionToMap: Function, context: this ): this; - - extractPerpendicularPlane ( axis: string, RASIndex: number ): object; - extractSlice( axis: string, index: number ): VolumeSlice; - - repaintAllSlices(): this; - computeMinMax(): number[]; - -} diff --git a/examples/jsm/misc/VolumeSlice.d.ts b/examples/jsm/misc/VolumeSlice.d.ts deleted file mode 100644 index a07ce72a1c5b1c..00000000000000 --- a/examples/jsm/misc/VolumeSlice.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - Matrix3, - Mesh, -} from '../../../src/Three'; - -import { Volume } from './Volume'; - -export class VolumeSlice { - - constructor( volume: Volume, index?: number, axis?: string ); - - index: number; - axis: string; - - canvas: HTMLCanvasElement; - canvasBuffer: HTMLCanvasElement; - - ctx: CanvasRenderingContext2D; - ctxBuffer: CanvasRenderingContext2D; - - mesh: Mesh; - - geometryNeedsUpdate: boolean; - - sliceAccess: number; - jLength: number; - iLength: number; - matrix: Matrix3; - - repaint(): void; - updateGeometry(): void; - -} diff --git a/examples/jsm/modifiers/CurveModifier.d.ts b/examples/jsm/modifiers/CurveModifier.d.ts deleted file mode 100644 index 2654fe8114c41f..00000000000000 --- a/examples/jsm/modifiers/CurveModifier.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -import { - DataTexture, - Curve, - Uniform, - Material, - InstancedMesh, - Geometry, - Mesh, - Vector3 -} from '../../../src/Three'; - -interface SplineUniform { - spineTexture: Uniform, - pathOffset: Uniform, - pathSegment: Uniform, - spineOffset: Uniform, - Uniform, - flow: Uniform, -} -export function initSplineTexture( size?: number ): DataTexture; - -export function updateSplineTexture( texture: DataTexture, splineCurve: Curve, offset?: number ); - -export function getUniforms( splineTexture: DataTexture ): SplineUniform; - -export function modifyShader( material: Material, uniforms: SplineUniform, numberOfCurves?: number ); - -export class Flow { - - constructor( mesh: Mesh, numberOfCurves?: number ); - curveArray: number[]; - curveLengthArray: number[]; - object3D: Mesh; - splineTexure: DataTexture; - uniforms: SplineUniform; - updateCurve( index: number, curve: Curve ); - moveAlongCurve( amount: number ); - -} - -export class InstancedFlow extends Flow { - - constructor( count: Number, curveCount: Number, geometry: Geometry, material: Material ); - object3D: InstancedMesh; - offsets: number[]; - whichCurve: number[]; - - moveIndividualAlongCurve( index: number, offset: number ); - setCurve( index: number, curveNo: number ) - -} diff --git a/examples/jsm/modifiers/EdgeSplitModifier.d.ts b/examples/jsm/modifiers/EdgeSplitModifier.d.ts deleted file mode 100644 index 0eace7b728ae21..00000000000000 --- a/examples/jsm/modifiers/EdgeSplitModifier.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { BufferGeometry, Geometry } from '../../../src/Three'; - -export class EdgeSplitModifier { - - constructor(); - - - /** - * @param geometry The geometry to modify by splitting edges. - * This geometry can be any of any type: Geometry or BufferGeometry, indexed or - * not... - * - * @param cutOffPoint The cutoff angle in radians. If the angle between two face normals is higher - * than this value, a split will be made. - * - * @param [tryKeepNormals = true] Set to true to keep the normal values for vertices that won't be split. - * To use this feature, you also need to pass an indexed geometry with a 'normal' - * BufferAttribute. - */ - modify( geometry: Geometry, cutOffPoint: number, tryKeepNormals: boolean ): BufferGeometry; - -} diff --git a/examples/jsm/modifiers/SimplifyModifier.d.ts b/examples/jsm/modifiers/SimplifyModifier.d.ts deleted file mode 100644 index 2d4188bfd4a295..00000000000000 --- a/examples/jsm/modifiers/SimplifyModifier.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { - BufferGeometry, - Geometry -} from '../../../src/Three'; - -export class SimplifyModifier { - - constructor(); - modify( geometry: BufferGeometry | Geometry, count: number ): BufferGeometry; - -} diff --git a/examples/jsm/modifiers/TessellateModifier.d.ts b/examples/jsm/modifiers/TessellateModifier.d.ts deleted file mode 100644 index 88717877bfbb62..00000000000000 --- a/examples/jsm/modifiers/TessellateModifier.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - BufferGeometry -} from '../../../src/Three'; - -export class TessellateModifier { - - constructor( maxEdgeLength?: number, maxIterations?: number ); - maxEdgeLength: number; - maxIterations: number; - - modify( geometry: BufferGeometry ): BufferGeometry; - -} diff --git a/examples/jsm/nodes/Nodes.d.ts b/examples/jsm/nodes/Nodes.d.ts deleted file mode 100644 index f43df650b0e222..00000000000000 --- a/examples/jsm/nodes/Nodes.d.ts +++ /dev/null @@ -1,106 +0,0 @@ -// core - -export * from './core/Node'; -export * from './core/TempNode'; -export * from './core/InputNode'; -export * from './core/ConstNode'; -export * from './core/VarNode'; -export * from './core/StructNode'; -export * from './core/AttributeNode'; -export * from './core/FunctionNode'; -export * from './core/ExpressionNode'; -export * from './core/FunctionCallNode'; -export * from './core/NodeLib'; -export * from './core/NodeUtils'; -export * from './core/NodeFrame'; -export * from './core/NodeUniform'; -export * from './core/NodeBuilder'; - -// inputs - -export * from './inputs/BoolNode'; -export * from './inputs/IntNode'; -export * from './inputs/FloatNode'; -export * from './inputs/Vector2Node'; -export * from './inputs/Vector3Node'; -export * from './inputs/Vector4Node'; -export * from './inputs/ColorNode'; -export * from './inputs/Matrix3Node'; -export * from './inputs/Matrix4Node'; -export * from './inputs/TextureNode'; -export * from './inputs/CubeTextureNode'; -export * from './inputs/ScreenNode'; -export * from './inputs/ReflectorNode'; -export * from './inputs/PropertyNode'; -export * from './inputs/RTTNode'; - -// accessors - -export * from './accessors/UVNode'; -export * from './accessors/ColorsNode'; -export * from './accessors/PositionNode'; -export * from './accessors/NormalNode'; -export * from './accessors/CameraNode'; -export * from './accessors/LightNode'; -export * from './accessors/ReflectNode'; -export * from './accessors/ScreenUVNode'; -export * from './accessors/ResolutionNode'; - -// math - -export * from './math/MathNode'; -export * from './math/OperatorNode'; -export * from './math/CondNode'; - -// procedural - -export * from './procedural/NoiseNode'; -export * from './procedural/CheckerNode'; - -// misc - -export * from './misc/TextureCubeUVNode'; -export * from './misc/TextureCubeNode'; -export * from './misc/NormalMapNode'; -export * from './misc/BumpMapNode'; - -// utils - -export * from './utils/BypassNode'; -export * from './utils/JoinNode'; -export * from './utils/SwitchNode'; -export * from './utils/TimerNode'; -export * from './utils/VelocityNode'; -export * from './utils/UVTransformNode'; -export * from './utils/MaxMIPLevelNode'; -export * from './utils/SpecularMIPLevelNode'; -export * from './utils/ColorSpaceNode'; - -// effects - -export * from './effects/BlurNode'; -export * from './effects/ColorAdjustmentNode'; -export * from './effects/LuminanceNode'; - -// material nodes - -export * from './materials/nodes/RawNode'; -export * from './materials/nodes/BasicNode'; -export * from './materials/nodes/SpriteNode'; -export * from './materials/nodes/PhongNode'; -export * from './materials/nodes/StandardNode'; -export * from './materials/nodes/MeshStandardNode'; - -// materials - -export * from './materials/NodeMaterial'; -export * from './materials/BasicNodeMaterial'; -export * from './materials/SpriteNodeMaterial'; -export * from './materials/PhongNodeMaterial'; -export * from './materials/StandardNodeMaterial'; -export * from './materials/MeshStandardNodeMaterial'; - -// postprocessing - -export * from './postprocessing/NodePostProcessing'; -// export * from './postprocessing/NodePass'; diff --git a/examples/jsm/nodes/accessors/CameraNode.d.ts b/examples/jsm/nodes/accessors/CameraNode.d.ts deleted file mode 100644 index 8848762dc9bb5e..00000000000000 --- a/examples/jsm/nodes/accessors/CameraNode.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Camera } from '../../../../src/Three'; - -import { NodeFrame } from '../core/NodeFrame'; -import { TempNode } from '../core/TempNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { FloatNode } from '../inputs/FloatNode'; - -export class CameraNode extends TempNode { - - constructor( scope?: string, camera?: Camera ); - - scope: string; - near: FloatNode | undefined; - far: FloatNode | undefined; - camera: Camera | undefined; - updateFrame: boolean | undefined; - nodeType: string; - - setCamera( camera: Camera ): void; - setScope( scope: string ): void; - onUpdateFrame( frame: NodeFrame ): void; - copy( source: CameraNode ): this; - - static Nodes: { - depthColor: FunctionNode; - }; - static POSITION: string; - static DEPTH: string; - static TO_VERTEX: string; - -} diff --git a/examples/jsm/nodes/accessors/ColorsNode.d.ts b/examples/jsm/nodes/accessors/ColorsNode.d.ts deleted file mode 100644 index a0e8e9d358d030..00000000000000 --- a/examples/jsm/nodes/accessors/ColorsNode.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class ColorsNode extends TempNode { - - constructor( index?: number ); - - index: number; - nodeType: string; - - copy( source: ColorsNode ): this; - -} diff --git a/examples/jsm/nodes/accessors/LightNode.d.ts b/examples/jsm/nodes/accessors/LightNode.d.ts deleted file mode 100644 index f8c39226971dfb..00000000000000 --- a/examples/jsm/nodes/accessors/LightNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class LightNode extends TempNode { - - constructor( scope?: string ); - - scope: string; - nodeType: string; - - copy( source: LightNode ): this; - - static TOTAL: string; - -} diff --git a/examples/jsm/nodes/accessors/NormalNode.d.ts b/examples/jsm/nodes/accessors/NormalNode.d.ts deleted file mode 100644 index b4a06536274a0f..00000000000000 --- a/examples/jsm/nodes/accessors/NormalNode.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class NormalNode extends TempNode { - - constructor( scope?: string ); - - scope: string; - nodeType: string; - - copy( source: NormalNode ): this; - - static LOCAL: string; - static WORLD: string; - -} diff --git a/examples/jsm/nodes/accessors/PositionNode.d.ts b/examples/jsm/nodes/accessors/PositionNode.d.ts deleted file mode 100644 index 0eb7e9121a5a1d..00000000000000 --- a/examples/jsm/nodes/accessors/PositionNode.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class PositionNode extends TempNode { - - constructor( scope?: string ); - - scope: string; - nodeType: string; - - copy( source: PositionNode ): this; - - static LOCAL: string; - static WORLD: string; - static VIEW: string; - static PROJECTION: string; - -} diff --git a/examples/jsm/nodes/accessors/ReflectNode.d.ts b/examples/jsm/nodes/accessors/ReflectNode.d.ts deleted file mode 100644 index 9a5addc98af12d..00000000000000 --- a/examples/jsm/nodes/accessors/ReflectNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class ReflectNode extends TempNode { - - constructor( scope?: string ); - - scope: string; - nodeType: string; - - static CUBE: string; - static SPHERE: string; - static VECTOR: string; - -} diff --git a/examples/jsm/nodes/accessors/ResolutionNode.d.ts b/examples/jsm/nodes/accessors/ResolutionNode.d.ts deleted file mode 100644 index 47225f9662b7dc..00000000000000 --- a/examples/jsm/nodes/accessors/ResolutionNode.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Vector2 } from '../../../../src/Three'; - -import { NodeFrame } from '../core/NodeFrame'; -import { Vector2Node } from '../inputs/Vector2Node'; - -export class ResolutionNode extends Vector2Node { - - constructor(); - - size: Vector2; - nodeType: string; - - updateFrame( frame: NodeFrame ): void; - copy( source: ResolutionNode ): this; - -} diff --git a/examples/jsm/nodes/accessors/ScreenUVNode.d.ts b/examples/jsm/nodes/accessors/ScreenUVNode.d.ts deleted file mode 100644 index b9704907f7f556..00000000000000 --- a/examples/jsm/nodes/accessors/ScreenUVNode.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { ResolutionNode } from './ResolutionNode'; - -export class ScreenUVNode extends TempNode { - - constructor( resolution?: ResolutionNode ); - - resolution: ResolutionNode; - nodeType: string; - - copy( source: ScreenUVNode ): this; - -} diff --git a/examples/jsm/nodes/accessors/UVNode.d.ts b/examples/jsm/nodes/accessors/UVNode.d.ts deleted file mode 100644 index 54c2c5a2f2dee6..00000000000000 --- a/examples/jsm/nodes/accessors/UVNode.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class UVNode extends TempNode { - - constructor( index?: number ); - - index: number; - nodeType: string; - - copy( source: UVNode ): this; - -} diff --git a/examples/jsm/nodes/core/AttributeNode.d.ts b/examples/jsm/nodes/core/AttributeNode.d.ts deleted file mode 100644 index 394dfd3314df3b..00000000000000 --- a/examples/jsm/nodes/core/AttributeNode.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TempNode } from './TempNode'; -import { NodeBuilder } from './NodeBuilder'; - -export class AttributeNode extends TempNode { - - constructor( name: string, type?: string ); - - name: string; - nodeType: string; - - getAttributeType( builder: NodeBuilder ): string; - getType( builder: NodeBuilder ): string; - copy( source: AttributeNode ): this; - -} diff --git a/examples/jsm/nodes/core/ConstNode.d.ts b/examples/jsm/nodes/core/ConstNode.d.ts deleted file mode 100644 index 2d79f4143ef3b2..00000000000000 --- a/examples/jsm/nodes/core/ConstNode.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { TempNode } from './TempNode'; -import { NodeBuilder } from './NodeBuilder'; - -export class ConstNode extends TempNode { - - constructor( src: string, useDefine?: boolean ); - - src: string; - useDefine: boolean; - nodeType: string; - - getType( builder: NodeBuilder ): string; - parse( src: string, useDefine?: boolean ): void; - build( builder: NodeBuilder, output: string ): string; - copy( source: ConstNode ): this; - - static PI: string; - static PI2: string; - static RECIPROCAL_PI: string; - static RECIPROCAL_PI2: string; - static LOG2: string; - static EPSILON: string; - -} diff --git a/examples/jsm/nodes/core/ExpressionNode.d.ts b/examples/jsm/nodes/core/ExpressionNode.d.ts deleted file mode 100644 index f7679617da0a8e..00000000000000 --- a/examples/jsm/nodes/core/ExpressionNode.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { FunctionNode } from './FunctionNode'; - -export class ExpressionNode extends FunctionNode { - - constructor( src: string, type?: string, keywords?: object, extensions?: object, includes?: object[] ); - -} diff --git a/examples/jsm/nodes/core/FunctionCallNode.d.ts b/examples/jsm/nodes/core/FunctionCallNode.d.ts deleted file mode 100644 index c078843b34a23a..00000000000000 --- a/examples/jsm/nodes/core/FunctionCallNode.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { Node } from './Node'; -import { FunctionNode } from './FunctionNode'; -import { TempNode } from './TempNode'; - -export class FunctionCallNode extends TempNode { - - constructor( func: FunctionNode, inputs?: Node[] ); - - nodeType: string; - - value: FunctionNode; - inputs: Node[]; - - setFunction( func: FunctionNode, inputs?: Node[] ): void; - getFunction(): FunctionNode; - getType(): string; - copy( source: FunctionCallNode ): this; - -} diff --git a/examples/jsm/nodes/core/FunctionNode.d.ts b/examples/jsm/nodes/core/FunctionNode.d.ts deleted file mode 100644 index 198e93b73eefdd..00000000000000 --- a/examples/jsm/nodes/core/FunctionNode.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { TempNode } from './TempNode'; -import { NodeBuilder } from './NodeBuilder'; - -export interface FunctionNodeInput { - name: string; - type: string; - qualifier: string; -} - -export class FunctionNode extends TempNode { - - constructor( src: string, includes?: object[], extensions?: object, keywords?: object, type?: string ); - - isMethod: boolean; - nodeType: string; - useKeywords: boolean; - - inputs: FunctionNodeInput[] | undefined; - includes: object[] | undefined; - extensions: object | undefined; - keywords: object | undefined; - - getShared( builder: NodeBuilder, output: string ): boolean; - getType( builder: NodeBuilder ): string; - getInputByName( name: string ): FunctionNodeInput | undefined; - getIncludeByName( name: string ): object | undefined; - parse( src: string, includes?: object[], extensions?: object, keywords?: object ): void; - copy( source: FunctionNode ): this; - -} diff --git a/examples/jsm/nodes/core/InputNode.d.ts b/examples/jsm/nodes/core/InputNode.d.ts deleted file mode 100644 index 1d462a0efa3866..00000000000000 --- a/examples/jsm/nodes/core/InputNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { TempNode, TempNodeParams } from './TempNode'; -import { NodeBuilder } from './NodeBuilder'; - -export class InputNode extends TempNode { - - constructor( type: string, params?: TempNodeParams ); - - readonly: boolean; - - setReadonly( value: boolean ): this; - getReadonly( builder: NodeBuilder ): boolean; - copy( source: InputNode ): this; - -} diff --git a/examples/jsm/nodes/core/Node.d.ts b/examples/jsm/nodes/core/Node.d.ts deleted file mode 100644 index e83f300b89f462..00000000000000 --- a/examples/jsm/nodes/core/Node.d.ts +++ /dev/null @@ -1,36 +0,0 @@ -import { NodeBuilder } from './NodeBuilder'; - -export interface Flow { - result: string; - code: string; - extra: object; -} - -export class Node { - - constructor( type?: string ); - - uuid: string; - name: string; - type: string | undefined; - userData: object; - readonly isNode: true; - frameId: number | undefined; - hashProperties: string[] | undefined; - - analyze( builder: NodeBuilder, settings?: object ): void; - analyzeAndFlow( builder: NodeBuilder, output: string, settings?: object ): Flow; - flow( builder: NodeBuilder, output: string, settings?: object ): Flow; - build( builder: NodeBuilder, output: string, uuid?: string ): string; - generate( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string ): string; - appendDepsNode( builder: NodeBuilder, data: object, output: string ): void; - setName( name: string ): this; - getName( builder: NodeBuilder ): string; - getType( builder: NodeBuilder, output?: string ): string; - getJSONNode( meta?: object | string ): object | undefined; - getHash(): string; - copy( source: Node ): this; - createJSONNode( meta?: object | string ): object; - toJSON( meta?: object | string ): object; - -} diff --git a/examples/jsm/nodes/core/NodeBuilder.d.ts b/examples/jsm/nodes/core/NodeBuilder.d.ts deleted file mode 100644 index 43326c6fc2e56a..00000000000000 --- a/examples/jsm/nodes/core/NodeBuilder.d.ts +++ /dev/null @@ -1,150 +0,0 @@ -import { - Material, - Texture, - TextureEncoding, - WebGLRenderer -} from '../../../../src/Three'; - -import { Node } from './Node'; -import { NodeUniform } from './NodeUniform'; - -export class NodeBuilder { - - constructor(); - - slots: string[]; - caches: string[]; - contexts: object[]; - - keywords: object; - nodeData: object; - - requires: { - uv: boolean[]; - color: boolean[]; - lights: boolean; - fog: boolean; - transparent: boolean; - irradiance: boolean; - }; - - includes: { - consts: object[]; - functions: object[]; - structs: object[]; - }; - - attributes: object; - prefixCode: string; - - parsCode: { - vertex: string; - fragment: string; - }; - - code: { - vertex: string; - fragment: string; - }; - - nodeCode: { - vertex: string; - fragment: string; - }; - - resultCode: { - vertex: string; - fragment: string; - }; - - finalCode: { - vertex: string; - fragment: string; - }; - - inputs: { - uniforms: { - list: object[]; - vertex: object[]; - fragment: object[]; - }; - vars: { - varying: object[]; - vertex: object[]; - fragment: object[]; - } - }; - - defines: object; - uniforms: object; - extensions: object; - updaters: object[]; - nodes: object[]; - - analyzing: boolean; - - build( vertex: Node, fragment: Node ): this; - buildShader( shader: string, node: Node ): void; - setMaterial( material: Material, renderer: WebGLRenderer ): this; - addFlow( slot: string, cache?: string, context?: object ): this; - removeFlow(): this; - addCache( name: string ): this; - removeCache(): this; - addContext( context: object ): this; - removeContext(): this; - addSlot( name: string ): this; - removeSlot(): this; - addVertexCode( code: string ): void; - addFragmentCode( code: string ): void; - addCode( code: string, shader?: string ): void; - addVertexNodeCode( code: string ): void; - addFragmentNodeCode( code: string ): void; - addNodeCode( code: string, shader?: string ): void; - clearNodeCode( shader: string ): string; - clearVertexNodeCode(): string; - clearFragmentNodeCode(): string; - addVertexFinalCode( code: string ): void; - addFragmentFinalCode( code: string ): void; - addFinalCode( code: string, shader?: string ): void; - addVertexParsCode( code: string ): void; - addFragmentParsCode( code: string ): void; - addParsCode( code: string, shader?: string ): void; - addVaryCode( code: string ): void; - isCache( name: string ): boolean; - isSlot( name: string ): boolean; - define( name: string, value: any ): void; - isDefined( name: string ): boolean; - getVar( uuid: string, type: string, ns: string, shader?: string, prefix?: string, label?: string ): object; - getVar( uuid: string, type: string, ns: string, label: string ): object; - getAttribute( name: string, type: string ): any; - getCode( shader: string ): string; - getVarListCode( vars: object[], prefix?: string ): string; - getVars( shader: string ): object[]; - getNodeData( node: Node ): object; - createUniform( shader: string, type: string, node: Node, ns?: string, needsUpdate?: boolean, label?: string ): NodeUniform; - createVertexUniform( type: string, node: Node, ns?: string, needsUpdate?: boolean, label?: string ): NodeUniform; - createFragmentUniform( type: string, node: Node, ns?: string, needsUpdate?: boolean, label?: string ): NodeUniform; - include( node: Node, parent?: boolean, source?: string ): void; - colorToVectorProperties( color: string ): string; - colorToVector( color: string ): string; - getIncludes( type: string, shader: string ): object[]; - getIncludesCode( type: string, shader: string ): string; - getConstructorFromLength( len: number ): string; - isTypeMatrix( format: string ): boolean; - getTypeLength( type: string ): number; - getTypeFromLength( len: number ): string; - findNode(): Node; - resolve(): void; - format( code: string, from: string, to: string ): string; - getTypeByFormat( format: string ): string; - getFormatByType( type: string ): string; - getUuid( uuid: string, useCache?: boolean ): string; - getElementByIndex( index: number ): string; - getIndexByElement( elm: string ): number; - isShader( shader: string ): boolean; - setShader( shader: string ): this; - mergeDefines( defines: object ): object; - mergeUniform( uniforms: object ): object; - getTextureEncodingFromMap( map: Texture ): TextureEncoding; - -} diff --git a/examples/jsm/nodes/core/NodeFrame.d.ts b/examples/jsm/nodes/core/NodeFrame.d.ts deleted file mode 100644 index f56d4eaaaedf89..00000000000000 --- a/examples/jsm/nodes/core/NodeFrame.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - Texture, - WebGLRenderer -} from '../../../../src/Three'; - -import { Node } from './Node'; - -export class NodeFrame { - - constructor( time: number ); - time: number; - id: number; - delta: number | undefined; - renderer: WebGLRenderer | undefined; - renderTexture: Texture | undefined; - - update( delta: number ): this; - setRenderer( renderer: WebGLRenderer ): this; - setRenderTexture( renderTexture: Texture ): this; - updateNode( node: Node ): this; - -} diff --git a/examples/jsm/nodes/core/NodeLib.d.ts b/examples/jsm/nodes/core/NodeLib.d.ts deleted file mode 100644 index 2956cea978d7d9..00000000000000 --- a/examples/jsm/nodes/core/NodeLib.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Node } from './Node'; -import { NodeBuilder } from './NodeBuilder'; - -export interface NodeLibKeyword { - callback: ( builder: NodeBuilder ) => void; - cache?: object; -} - -export namespace NodeLib { - - export const nodes: object; - export const keywords: object; - - export function add( node: Node ): void; - export function addKeyword( name: string, callback: ( builder: NodeBuilder ) => void, cache?: object ): void; - export function remove( node: Node ): void; - export function removeKeyword( name: string ): void; - export function get( name: string ): Node; - export function getKeyword( name: string, builder: NodeBuilder ): any; - export function getKeywordData( name: string ): NodeLibKeyword; - export function contains( name: string ): boolean; - export function containsKeyword( name: string ): boolean; - -} diff --git a/examples/jsm/nodes/core/NodeUniform.d.ts b/examples/jsm/nodes/core/NodeUniform.d.ts deleted file mode 100644 index 78b59a3d635a01..00000000000000 --- a/examples/jsm/nodes/core/NodeUniform.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { Node } from './Node'; - -export interface NodeUniformParams { - name?: string; - type?: string; - node?: Node; - needsUpdate?: boolean; -} - -export class NodeUniform { - - constructor( params?: NodeUniformParams ); - name: string | undefined; - type: string | undefined; - node: Node | undefined; - needsUpdate: boolean | undefined; - value: any; - -} diff --git a/examples/jsm/nodes/core/NodeUtils.d.ts b/examples/jsm/nodes/core/NodeUtils.d.ts deleted file mode 100644 index f70d96f24c10aa..00000000000000 --- a/examples/jsm/nodes/core/NodeUtils.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Node } from './Node'; - -export namespace NodeUtils { - - export const elements: string[]; - - export function addShortcuts( proto: Node, proxy: string, list: any[] ): void; - -} diff --git a/examples/jsm/nodes/core/StructNode.d.ts b/examples/jsm/nodes/core/StructNode.d.ts deleted file mode 100644 index f306dfae8863de..00000000000000 --- a/examples/jsm/nodes/core/StructNode.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { TempNode } from './TempNode'; -import { NodeBuilder } from './NodeBuilder'; - -export interface StructNodeInput { - type: string; - name: string; -} - -export class StructNode extends TempNode { - - constructor( src?: string ); - - inputs: StructNodeInput[]; - src: string; - nodeType: string; - - getType( builder: NodeBuilder ): string; - getInputByName( name: string ): StructNodeInput; - parse( src: string ): void; - -} diff --git a/examples/jsm/nodes/core/TempNode.d.ts b/examples/jsm/nodes/core/TempNode.d.ts deleted file mode 100644 index a45b93ef4ac602..00000000000000 --- a/examples/jsm/nodes/core/TempNode.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { Node } from './Node'; -import { NodeBuilder } from './NodeBuilder'; - -export interface TempNodeParams { - shared?: boolean; - unique?: boolean; -} - -export class TempNode extends Node { - - constructor( type: string, params?: TempNodeParams ); - - shared: boolean; - unique: boolean; - label: string | undefined; - - build( builder: NodeBuilder, output: string, uuid?: string, ns?: string ): string; - getShared( builder: NodeBuilder, output: string ): boolean; - getUnique( builder: NodeBuilder, output: string ): boolean; - setLabel( name: string ): this; - getLabel( builder: NodeBuilder ): string; - getUuid( unique: boolean ): string; - getTemp( builder: NodeBuilder, uuid: string ): string | undefined; - -} diff --git a/examples/jsm/nodes/core/VarNode.d.ts b/examples/jsm/nodes/core/VarNode.d.ts deleted file mode 100644 index c30cfed041c520..00000000000000 --- a/examples/jsm/nodes/core/VarNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Node } from './Node'; -import { NodeBuilder } from './NodeBuilder'; - -export class VarNode extends Node { - - constructor( type: string, value?: any ); - - value: any; - nodeType: string; - - getType( builder: NodeBuilder ): string; - copy( source: VarNode ): this; - -} diff --git a/examples/jsm/nodes/effects/BlurNode.d.ts b/examples/jsm/nodes/effects/BlurNode.d.ts deleted file mode 100644 index 2ff57f166421b1..00000000000000 --- a/examples/jsm/nodes/effects/BlurNode.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Vector2 } from '../../../../src/Three'; - -import { TempNode } from '../core/TempNode'; -import { NodeFrame } from '../core/NodeFrame'; -import { UVNode } from '../accessors/UVNode'; -import { Vector2Node } from '../inputs/Vector2Node'; -import { FloatNode } from '../inputs/FloatNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { TextureNode } from '../inputs/TextureNode'; - -export class BlurNode extends TempNode { - - constructor( value: TextureNode, uv?: UVNode, radius?: number, size?: Vector2 ); - - value: TextureNode; - uv: UVNode; - radius: Vector2Node; - size: Vector2; - blurX: boolean; - blurY: boolean; - horizontal: FloatNode; - vertical: FloatNode; - nodeType: string; - - updateFrame( frame: NodeFrame ): void; - copy( source: BlurNode ): this; - - static Nodes: { - blurX: FunctionNode; - blurY: FunctionNode; - } - -} diff --git a/examples/jsm/nodes/effects/ColorAdjustmentNode.d.ts b/examples/jsm/nodes/effects/ColorAdjustmentNode.d.ts deleted file mode 100644 index d08a4972964567..00000000000000 --- a/examples/jsm/nodes/effects/ColorAdjustmentNode.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FloatNode } from '../inputs/FloatNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { Node } from '../core/Node'; - -export class ColorAdjustmentNode extends TempNode { - - constructor( rgb: Node, adjustment?: FloatNode, method?: string ); - - rgb: Node; - adjustment: FloatNode | undefined; - method: string; - nodeType: string; - - copy( source: ColorAdjustmentNode ): this; - - static Nodes: { - hue: FunctionNode; - saturation: FunctionNode; - vibrance: FunctionNode; - } - - static SATURATION: string; - static HUE: string; - static VIBRANCE: string; - static BRIGHTNESS: string; - static CONTRAST: string; - -} diff --git a/examples/jsm/nodes/effects/LuminanceNode.d.ts b/examples/jsm/nodes/effects/LuminanceNode.d.ts deleted file mode 100644 index 19260fe97774d9..00000000000000 --- a/examples/jsm/nodes/effects/LuminanceNode.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { ConstNode } from '../core/ConstNode'; -import { Node } from '../core/Node'; - -export class LuminanceNode extends TempNode { - - constructor( rgb: Node ); - - rgb: Node; - nodeType: string; - - copy( source: LuminanceNode ): this; - - static Nodes: { - LUMA: ConstNode; - luminance: FunctionNode; - } - -} diff --git a/examples/jsm/nodes/inputs/BoolNode.d.ts b/examples/jsm/nodes/inputs/BoolNode.d.ts deleted file mode 100644 index a7a46a9251dfc5..00000000000000 --- a/examples/jsm/nodes/inputs/BoolNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class BoolNode extends InputNode { - - constructor( value?: boolean ); - - value: boolean; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: BoolNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/ColorNode.d.ts b/examples/jsm/nodes/inputs/ColorNode.d.ts deleted file mode 100644 index ba613602d0659f..00000000000000 --- a/examples/jsm/nodes/inputs/ColorNode.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Color } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class ColorNode extends InputNode { - - constructor( color: Color | number | string, g?: number, b?: number ); - - value: Color; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: ColorNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/CubeTextureNode.d.ts b/examples/jsm/nodes/inputs/CubeTextureNode.d.ts deleted file mode 100644 index ee70c255220add..00000000000000 --- a/examples/jsm/nodes/inputs/CubeTextureNode.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { CubeTexture } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { Node } from '../core/Node'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class CubeTextureNode extends InputNode { - - constructor( value: CubeTexture, uv?: Node, bias?: Node ); - - value: CubeTexture; - uv: Node | undefined; - bias: Node | undefined; - nodeType: string; - - getTexture( builder: NodeBuilder, output: string ): string; - copy( source: CubeTextureNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/FloatNode.d.ts b/examples/jsm/nodes/inputs/FloatNode.d.ts deleted file mode 100644 index 614019bc189c52..00000000000000 --- a/examples/jsm/nodes/inputs/FloatNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class FloatNode extends InputNode { - - constructor( value?: number ); - - value: number; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: FloatNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/IntNode.d.ts b/examples/jsm/nodes/inputs/IntNode.d.ts deleted file mode 100644 index 03f073783bc323..00000000000000 --- a/examples/jsm/nodes/inputs/IntNode.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class IntNode extends InputNode { - - constructor( value?: number ); - - value: number; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: IntNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/Matrix3Node.d.ts b/examples/jsm/nodes/inputs/Matrix3Node.d.ts deleted file mode 100644 index 2c0c1dcc6b8643..00000000000000 --- a/examples/jsm/nodes/inputs/Matrix3Node.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { Matrix3 } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class Matrix3Node extends InputNode { - - constructor( matrix?: Matrix3 ); - - value: Matrix3; - nodeType: string; - elements: number[]; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: Matrix3Node ): this; - -} diff --git a/examples/jsm/nodes/inputs/Matrix4Node.d.ts b/examples/jsm/nodes/inputs/Matrix4Node.d.ts deleted file mode 100644 index cb846558e4d61a..00000000000000 --- a/examples/jsm/nodes/inputs/Matrix4Node.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { Matrix4 } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class Matrix4Node extends InputNode { - - constructor( matrix?: Matrix4 ); - - value: Matrix4; - nodeType: string; - elements: number[]; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: Matrix4Node ): this; - -} diff --git a/examples/jsm/nodes/inputs/PropertyNode.d.ts b/examples/jsm/nodes/inputs/PropertyNode.d.ts deleted file mode 100644 index 967908d2333934..00000000000000 --- a/examples/jsm/nodes/inputs/PropertyNode.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { InputNode } from '../core/InputNode'; - -export class PropertyNode extends InputNode { - - constructor( object: object, property: string, type: string ); - - object: object; - property: string; - nodeType: string; - value: any; - -} diff --git a/examples/jsm/nodes/inputs/RTTNode.d.ts b/examples/jsm/nodes/inputs/RTTNode.d.ts deleted file mode 100644 index fc5e5ec0753e03..00000000000000 --- a/examples/jsm/nodes/inputs/RTTNode.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { - Mesh, - OrthographicCamera, - Scene, - WebGLRenderTarget, - WebGLRenderTargetOptions -} from '../../../../src/Three'; - -import { NodeBuilder } from '../core/NodeBuilder'; -import { NodeFrame } from '../core/NodeFrame'; -import { TextureNode } from './TextureNode'; - -export interface RTTNodeOptions extends WebGLRenderTargetOptions { - clear?: boolean; -} - -export class RTTNode extends TextureNode { - - constructor( width: number, height: number, input: TextureNode, options?: RTTNodeOptions ); - - input: TextureNode; - clear: boolean; - renderTarget: WebGLRenderTarget; - material: object; // NodeMaterial - camera: OrthographicCamera; - scene: Scene; - quad: Mesh; - render: boolean; - - build( builder: NodeBuilder, output: string, uuid?: string ): string; - updateFramesaveTo( frame: NodeFrame ): void; - updateFrame( frame: NodeFrame ): void; - copy( source: RTTNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/ReflectorNode.d.ts b/examples/jsm/nodes/inputs/ReflectorNode.d.ts deleted file mode 100644 index f9f18f405c0342..00000000000000 --- a/examples/jsm/nodes/inputs/ReflectorNode.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { Matrix4Node } from './Matrix4Node'; -import { OperatorNode } from '../math/OperatorNode'; -import { ReflectorRTT } from '../../objects/ReflectorRTT'; -import { TextureNode } from './TextureNode'; -import { PositionNode } from '../accessors/PositionNode'; - -export class ReflectorNode extends TempNode { - - constructor( mirror?: ReflectorRTT ); - - mirror: ReflectorRTT; - textureMatrix: Matrix4Node; - localPosition: PositionNode; - uv: OperatorNode; - uvResult: OperatorNode; - texture: TextureNode; - - nodeType: string; - - copy( source: ReflectorNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/ScreenNode.d.ts b/examples/jsm/nodes/inputs/ScreenNode.d.ts deleted file mode 100644 index 70928e545dfe65..00000000000000 --- a/examples/jsm/nodes/inputs/ScreenNode.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { NodeBuilder } from '../core/NodeBuilder'; -import { TextureNode } from './TextureNode'; -import { UVNode } from '../accessors/UVNode'; - -export class ScreenNode extends TextureNode { - - constructor( uv?: UVNode ); - - nodeType: string; - - getTexture( builder: NodeBuilder, output: string ): string; - -} diff --git a/examples/jsm/nodes/inputs/TextureNode.d.ts b/examples/jsm/nodes/inputs/TextureNode.d.ts deleted file mode 100644 index 0a557c3222f94f..00000000000000 --- a/examples/jsm/nodes/inputs/TextureNode.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - Texture -} from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; -import { Node } from '../core/Node'; -import { UVNode } from '../accessors/UVNode'; - -export class TextureNode extends InputNode { - - constructor( value: Texture, uv?: UVNode, bias?: Node, project?: boolean ); - - value: Texture; - uv: UVNode; - bias: Node; - project: boolean; - nodeType: string; - - getTexture( builder: NodeBuilder, output: string ): string; - copy( source: TextureNode ): this; - -} diff --git a/examples/jsm/nodes/inputs/Vector2Node.d.ts b/examples/jsm/nodes/inputs/Vector2Node.d.ts deleted file mode 100644 index 79d6d6507c26fb..00000000000000 --- a/examples/jsm/nodes/inputs/Vector2Node.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Vector2 } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class Vector2Node extends InputNode { - - constructor( x: Vector2 | number, y?: number ); - - value: Vector2; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: Vector2Node ): this; - -} diff --git a/examples/jsm/nodes/inputs/Vector3Node.d.ts b/examples/jsm/nodes/inputs/Vector3Node.d.ts deleted file mode 100644 index 4877bf4d796dd7..00000000000000 --- a/examples/jsm/nodes/inputs/Vector3Node.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Vector3 } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class Vector3Node extends InputNode { - - constructor( x: Vector3 | number, y?: number, z?: number ); - - value: Vector3; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: Vector3Node ): this; - -} diff --git a/examples/jsm/nodes/inputs/Vector4Node.d.ts b/examples/jsm/nodes/inputs/Vector4Node.d.ts deleted file mode 100644 index 1a505bd3a4c16e..00000000000000 --- a/examples/jsm/nodes/inputs/Vector4Node.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Vector4 } from '../../../../src/Three'; - -import { InputNode } from '../core/InputNode'; -import { NodeBuilder } from '../core/NodeBuilder'; - -export class Vector4Node extends InputNode { - - constructor( x: Vector4 | number, y?: number, z?: number, w?: number ); - - value: Vector4; - nodeType: string; - - generateReadonly( builder: NodeBuilder, output: string, uuid?: string, type?: string, ns?: string, needsUpdate?: boolean ): string; - copy( source: Vector4Node ): this; - -} diff --git a/examples/jsm/nodes/materials/BasicNodeMaterial.d.ts b/examples/jsm/nodes/materials/BasicNodeMaterial.d.ts deleted file mode 100644 index 4c3d6528e807b5..00000000000000 --- a/examples/jsm/nodes/materials/BasicNodeMaterial.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { Node } from '../core/Node'; -import { NodeMaterial } from './NodeMaterial'; - -export class BasicNodeMaterial extends NodeMaterial { - - constructor(); - - color: Node; - alpha: Node; - mask: Node; - position: Node; - -} diff --git a/examples/jsm/nodes/materials/MeshStandardNodeMaterial.d.ts b/examples/jsm/nodes/materials/MeshStandardNodeMaterial.d.ts deleted file mode 100644 index 0d7d2244eef890..00000000000000 --- a/examples/jsm/nodes/materials/MeshStandardNodeMaterial.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { Color } from '../../../../src/math/Color'; -import { Texture } from '../../../../src/textures/Texture'; -import { CubeTexture } from '../../../../src/textures/CubeTexture'; -import { Vector2 } from '../../../../src/math/Vector2'; - -import { Node } from '../core/Node'; -import { NodeMaterial } from './NodeMaterial'; - -export class MeshStandardNodeMaterial extends NodeMaterial { - - constructor(); - - color: Color | Node; - roughness: number | Node; - metalness: number | Node; - map: Texture | Node; - normalMap: Texture | Node; - normalScale: Vector2 | Node; - metalnessMap: Texture | Node; - roughnessMap: Texture | Node; - envMap: CubeTexture | Node; - -} diff --git a/examples/jsm/nodes/materials/NodeMaterial.d.ts b/examples/jsm/nodes/materials/NodeMaterial.d.ts deleted file mode 100644 index e40b442a530924..00000000000000 --- a/examples/jsm/nodes/materials/NodeMaterial.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - ShaderMaterial, - WebGLRenderer -} from '../../../../src/Three'; - -import { Node } from '../core/Node.js'; -import { NodeBuilder } from '../core/NodeBuilder'; -import { NodeFrame } from '../core/NodeFrame'; -import { RawNode } from './nodes/RawNode'; - -export interface NodeMaterialBuildParams { - builder?: NodeBuilder; - renderer?: WebGLRenderer; -} - -export class NodeMaterial extends ShaderMaterial { - - constructor( vertex: Node, fragment: Node ); - - vertex: Node | RawNode; - fragment: Node | RawNode; - - updaters: object[]; - - readonly isNodeMaterial: true; - properties: object; - - updateFrame( frame: NodeFrame ): void; - build( params?: NodeMaterialBuildParams ): this; - getHash(): string; - copy( source: NodeMaterial ): this; - -} diff --git a/examples/jsm/nodes/materials/PhongNodeMaterial.d.ts b/examples/jsm/nodes/materials/PhongNodeMaterial.d.ts deleted file mode 100644 index 927662c445b45f..00000000000000 --- a/examples/jsm/nodes/materials/PhongNodeMaterial.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { Node } from '../core/Node'; -import { NodeMaterial } from './NodeMaterial'; - -export class PhongNodeMaterial extends NodeMaterial { - - constructor(); - - color: Node; - alpha: Node; - specular: Node; - shininess: Node; - normal: Node; - emissive: Node; - ambient: Node; - light: Node; - shadow: Node; - ao: Node; - environment: Node; - environmentAlpha: Node; - mask: Node; - position: Node; - -} diff --git a/examples/jsm/nodes/materials/SpriteNodeMaterial.d.ts b/examples/jsm/nodes/materials/SpriteNodeMaterial.d.ts deleted file mode 100644 index 982444f0ecf8c2..00000000000000 --- a/examples/jsm/nodes/materials/SpriteNodeMaterial.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Node } from '../core/Node'; -import { NodeMaterial } from './NodeMaterial'; - -export class SpriteNodeMaterial extends NodeMaterial { - - constructor(); - - color: Node; - alpha: Node; - mask: Node; - position: Node; - spherical: Node; - -} diff --git a/examples/jsm/nodes/materials/StandardNodeMaterial.d.ts b/examples/jsm/nodes/materials/StandardNodeMaterial.d.ts deleted file mode 100644 index 10e78731d10fd2..00000000000000 --- a/examples/jsm/nodes/materials/StandardNodeMaterial.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { Node } from '../core/Node'; -import { NodeMaterial } from './NodeMaterial'; - -export class StandardNodeMaterial extends NodeMaterial { - - constructor(); - - color: Node; - alpha: Node; - roughness: Node; - metalness: Node; - reflectivity: Node; - clearcoat: Node; - clearcoatRoughness: Node; - clearcoatNormal: Node; - normal: Node; - emissive: Node; - ambient: Node; - light: Node; - shadow: Node; - ao: Node; - environment: Node; - mask: Node; - position: Node; - sheen: Node; - -} diff --git a/examples/jsm/nodes/materials/nodes/BasicNode.d.ts b/examples/jsm/nodes/materials/nodes/BasicNode.d.ts deleted file mode 100644 index 623f919ef4ef56..00000000000000 --- a/examples/jsm/nodes/materials/nodes/BasicNode.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { NodeBuilder } from '../../core/NodeBuilder'; -import { Node } from '../../core/Node'; - -export class BasicNode extends Node { - - constructor(); - - position: Node; - color: Node; - alpha: Node; - mask: Node; - nodeType: string; - - build( builder: NodeBuilder ): string; - copy( source: BasicNode ): this; - -} diff --git a/examples/jsm/nodes/materials/nodes/MeshStandardNode.d.ts b/examples/jsm/nodes/materials/nodes/MeshStandardNode.d.ts deleted file mode 100644 index f2d99fba5ed554..00000000000000 --- a/examples/jsm/nodes/materials/nodes/MeshStandardNode.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { - Color, - Vector2 -} from '../../../../../src/Three'; - -import { NodeBuilder } from '../../core/NodeBuilder'; -import { StandardNode } from './StandardNode'; -import { PropertyNode } from '../../inputs/PropertyNode'; - -export class MeshStandardNode extends StandardNode { - - constructor(); - - properties: { - color: Color; - roughness: number; - metalness: number; - normalScale: Vector2; - } - - inputs: { - color: PropertyNode - roughness: PropertyNode - metalness: PropertyNode - normalScale: PropertyNode - } - - build( builder: NodeBuilder ): string; - -} diff --git a/examples/jsm/nodes/materials/nodes/PhongNode.d.ts b/examples/jsm/nodes/materials/nodes/PhongNode.d.ts deleted file mode 100644 index 85b8f0abc5c91f..00000000000000 --- a/examples/jsm/nodes/materials/nodes/PhongNode.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { NodeBuilder } from '../../core/NodeBuilder'; -import { Node } from '../../core/Node'; - -export class PhongNode extends Node { - - constructor(); - - color: Node; - specular: Node; - shininess: Node; - nodeType: string; - - build( builder: NodeBuilder ): string; - copy( source: PhongNode ): this; - -} diff --git a/examples/jsm/nodes/materials/nodes/RawNode.d.ts b/examples/jsm/nodes/materials/nodes/RawNode.d.ts deleted file mode 100644 index 6892a623e57376..00000000000000 --- a/examples/jsm/nodes/materials/nodes/RawNode.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { Node } from '../../core/Node'; - -export class RawNode extends Node { - - constructor( value: Node ); - - value: Node; - nodeType: string; - - copy( source: RawNode ): this; - -} diff --git a/examples/jsm/nodes/materials/nodes/SpriteNode.d.ts b/examples/jsm/nodes/materials/nodes/SpriteNode.d.ts deleted file mode 100644 index 08d112e5eceb39..00000000000000 --- a/examples/jsm/nodes/materials/nodes/SpriteNode.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { NodeBuilder } from '../../core/NodeBuilder'; -import { Node } from '../../core/Node'; - -export class SpriteNode extends Node { - - constructor(); - - color: Node; - spherical: true; - nodeType: string; - - build( builder: NodeBuilder ): string; - copy( source: SpriteNode ): this; - -} diff --git a/examples/jsm/nodes/materials/nodes/StandardNode.d.ts b/examples/jsm/nodes/materials/nodes/StandardNode.d.ts deleted file mode 100644 index 040d8250888196..00000000000000 --- a/examples/jsm/nodes/materials/nodes/StandardNode.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { NodeBuilder } from '../../core/NodeBuilder'; -import { Node } from '../../core/Node'; - -export class StandardNode extends Node { - - constructor(); - - color: Node; - roughness: Node; - metalness: Node; - nodeType: string; - - build( builder: NodeBuilder ): string; - copy( source: StandardNode ): this; - -} diff --git a/examples/jsm/nodes/math/CondNode.d.ts b/examples/jsm/nodes/math/CondNode.d.ts deleted file mode 100644 index 7ed10a9c9154ca..00000000000000 --- a/examples/jsm/nodes/math/CondNode.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { NodeBuilder } from '../core/NodeBuilder'; -import { Node } from '../core/Node'; - -export class CondNode extends TempNode { - - constructor( a: Node, b: Node, op: string, ifNode?: Node, elseNode?: Node ); - - a: Node; - b: Node; - op: string; - ifNode: Node | undefined; - elseNode: Node | undefined; - nodeType: string; - - getCondType( builder: NodeBuilder ): string; - copy( source: CondNode ): this; - - static EQUAL: string; - static NOT_EQUAL: string; - static GREATER: string; - static GREATER_EQUAL: string; - static LESS: string; - static LESS_EQUAL: string; - static AND: string; - static OR: string; - -} diff --git a/examples/jsm/nodes/math/MathNode.d.ts b/examples/jsm/nodes/math/MathNode.d.ts deleted file mode 100644 index 63cf71011c2ca8..00000000000000 --- a/examples/jsm/nodes/math/MathNode.d.ts +++ /dev/null @@ -1,59 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { NodeBuilder } from '../core/NodeBuilder'; -import { Node } from '../core/Node'; - -export class MathNode extends TempNode { - - constructor( a: Node, bOrMethod: Node | string, cOrMethod?: Node | string, method?: string ); - - a: Node; - b: Node | string | undefined; - c: Node | string | undefined; - method: string; - nodeType: string; - - getNumInputs( builder: NodeBuilder ): number; - getInputType( builder: NodeBuilder ): string; - copy( source: MathNode ): this; - - static RAD: string; - static DEG: string; - static EXP: string; - static EXP2: string; - static LOG: string; - static LOG2: string; - static SQRT: string; - static INV_SQRT: string; - static FLOOR: string; - static CEIL: string; - static NORMALIZE: string; - static SATURATE: string; - static SIN: string; - static COS: string; - static TAN: string; - static ASIN: string; - static ACOS: string; - static ARCTAN: string; - static ABS: string; - static SIGN: string; - static LENGTH: string; - static NEGATE: string; - static INVERT: string; - - static MIN: string; - static MAX: string; - static MOD: string; - static STEP: string; - static REFLECT: string; - static DISTANCE: string; - static DOT: string; - static CROSS: string; - static POW: string; - - static MIX: string; - static CLAMP: string; - static REFRACT: string; - static SMOOTHSTEP: string; - static FACEFORWARD: string; - -} diff --git a/examples/jsm/nodes/math/OperatorNode.d.ts b/examples/jsm/nodes/math/OperatorNode.d.ts deleted file mode 100644 index 9a51eb35f89b84..00000000000000 --- a/examples/jsm/nodes/math/OperatorNode.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { Node } from '../core/Node'; - -export class OperatorNode extends TempNode { - - constructor( a: Node, b: Node, op: string ); - - a: Node; - b: Node; - op: string; - - copy( source: OperatorNode ): this; - - static ADD: string; - static SUB: string; - static MUL: string; - static DIV: string; - -} diff --git a/examples/jsm/nodes/misc/BumpMapNode.d.ts b/examples/jsm/nodes/misc/BumpMapNode.d.ts deleted file mode 100644 index fa3749ed8bfaa4..00000000000000 --- a/examples/jsm/nodes/misc/BumpMapNode.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FloatNode } from '../inputs/FloatNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { TextureNode } from '../inputs/TextureNode'; - -export class BumpMapNode extends TempNode { - - constructor( value: TextureNode, scale?: FloatNode ); - - value: TextureNode; - scale: FloatNode; - toNormalMap: boolean; - nodeType: string; - - copy( source: BumpMapNode ): this; - - static Nodes: { - dHdxy_fwd: FunctionNode; - perturbNormalArb: FunctionNode; - bumpToNormal: FunctionNode; - } - -} diff --git a/examples/jsm/nodes/misc/NormalMapNode.d.ts b/examples/jsm/nodes/misc/NormalMapNode.d.ts deleted file mode 100644 index 156d51e80f1c1c..00000000000000 --- a/examples/jsm/nodes/misc/NormalMapNode.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { TextureNode } from '../inputs/TextureNode'; -import { Vector2Node } from '../inputs/Vector2Node'; - -export class NormalMapNode extends TempNode { - - constructor( value: TextureNode, scale?: Vector2Node ); - - value: TextureNode; - scale: Vector2Node; - toNormalMap: boolean; - nodeType: string; - - copy( source: NormalMapNode ): this; - - static Nodes: { - perturbNormal2Arb: FunctionNode; - } - -} diff --git a/examples/jsm/nodes/misc/TextureCubeNode.d.ts b/examples/jsm/nodes/misc/TextureCubeNode.d.ts deleted file mode 100644 index 22b9e9f65f4658..00000000000000 --- a/examples/jsm/nodes/misc/TextureCubeNode.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { NodeBuilder } from '../core/NodeBuilder'; -import { TextureNode } from '../inputs/TextureNode'; -import { FloatNode } from '../inputs/FloatNode'; -import { TextureCubeUVNode } from './TextureCubeUVNode'; - -export class TextureCubeNode extends TempNode { - - constructor( value: TextureNode, textureSize?: FloatNode ); - - value: TextureNode; - textureSize: FloatNode; - radianceCache: { - uv: TextureCubeUVNode - }; - irradianceCache: { - uv: TextureCubeUVNode - }; - nodeType: string; - - generateTextureCubeUV( builder: NodeBuilder, output: string ): string; - -} diff --git a/examples/jsm/nodes/misc/TextureCubeUVNode.d.ts b/examples/jsm/nodes/misc/TextureCubeUVNode.d.ts deleted file mode 100644 index 3ff654c23c5245..00000000000000 --- a/examples/jsm/nodes/misc/TextureCubeUVNode.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FloatNode } from '../inputs/FloatNode'; -import { StructNode } from '../core/StructNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { Node } from '../core/Node'; - -export class TextureCubeUVNode extends TempNode { - - constructor( uv: Node, textureSize: FloatNode ); - - uv: Node; - textureSize: FloatNode; - nodeType: string; - - static Nodes: { - TextureCubeUVData: StructNode; - textureCubeUV: FunctionNode; - } - -} diff --git a/examples/jsm/nodes/postprocessing/NodePass.d.ts b/examples/jsm/nodes/postprocessing/NodePass.d.ts deleted file mode 100644 index f4929048e54351..00000000000000 --- a/examples/jsm/nodes/postprocessing/NodePass.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { ShaderPass } from '../../postprocessing/ShaderPass'; -import { ScreenNode } from '../inputs/ScreenNode'; - -export class NodePass extends ShaderPass { - - constructor(); - - name: string; - uuid: string; - userData: object; - input: ScreenNode; - needsUpdate: boolean; - - copy( source: NodePass ): this; - toJSON( meta?: object | string ): object; - -} diff --git a/examples/jsm/nodes/postprocessing/NodePostProcessing.d.ts b/examples/jsm/nodes/postprocessing/NodePostProcessing.d.ts deleted file mode 100644 index 02fa7ac663e7dd..00000000000000 --- a/examples/jsm/nodes/postprocessing/NodePostProcessing.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { - Camera, - Mesh, - OrthographicCamera, - Scene, - WebGLRenderer, - WebGLRenderTarget, -} from '../../../../src/Three'; - -import { ScreenNode } from '../inputs/ScreenNode'; -import { NodeMaterial } from '../materials/NodeMaterial'; -import { NodeFrame } from '../core/NodeFrame'; - -export class NodePostProcessing { - - constructor( renderer: WebGLRenderer, renderTarget?: WebGLRenderTarget ); - - renderer: WebGLRenderer; - renderTarget: WebGLRenderTarget; - - output: ScreenNode; - material: NodeMaterial - - camera: OrthographicCamera; - scene: Scene; - - quad: Mesh; - needsUpdate: boolean; - - render( scene: Scene, camera: Camera, frame: NodeFrame ): void; - setSize( width: number, height: number ): void; - copy( source: NodePostProcessing ): this; - toJSON( meta?: object | string ): object; - -} diff --git a/examples/jsm/nodes/procedural/CheckerNode.d.ts b/examples/jsm/nodes/procedural/CheckerNode.d.ts deleted file mode 100644 index 68fe1ec2dd52b6..00000000000000 --- a/examples/jsm/nodes/procedural/CheckerNode.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { UVNode } from '../accessors/UVNode'; -import { UVTransformNode } from '../utils/UVTransformNode'; - -export class CheckerNode extends TempNode { - - constructor( uv?: UVNode | UVTransformNode ); - - uv: UVNode | UVTransformNode; - nodeType: string; - - copy( source: CheckerNode ): this; - - static Nodes: { - checker: FunctionNode; - }; - -} diff --git a/examples/jsm/nodes/procedural/NoiseNode.d.ts b/examples/jsm/nodes/procedural/NoiseNode.d.ts deleted file mode 100644 index 97c992d2ea51ec..00000000000000 --- a/examples/jsm/nodes/procedural/NoiseNode.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { FunctionNode } from '../core/FunctionNode'; -import { UVNode } from '../accessors/UVNode'; -import { UVTransformNode } from '../utils/UVTransformNode'; - -export class NoiseNode extends TempNode { - - constructor( uv?: UVNode | UVTransformNode ); - - uv: UVNode | UVTransformNode; - nodeType: string; - - copy( source: NoiseNode ): this; - - static Nodes: { - snoise: FunctionNode; - }; - -} diff --git a/examples/jsm/nodes/utils/BypassNode.d.ts b/examples/jsm/nodes/utils/BypassNode.d.ts deleted file mode 100644 index 3f91e02658f98d..00000000000000 --- a/examples/jsm/nodes/utils/BypassNode.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { Node } from '../core/Node'; - -export class BypassNode extends Node { - - constructor( code: Node, value?: Node ); - - code: Node; - value: Node | undefined; - nodeType: string; - - copy( source: BypassNode ): this; - -} diff --git a/examples/jsm/nodes/utils/ColorSpaceNode.d.ts b/examples/jsm/nodes/utils/ColorSpaceNode.d.ts deleted file mode 100644 index f971008c07171f..00000000000000 --- a/examples/jsm/nodes/utils/ColorSpaceNode.d.ts +++ /dev/null @@ -1,57 +0,0 @@ -import { Node } from '../core/Node'; -import { TempNode } from '../core/TempNode'; -import { FunctionNode } from '../core/FunctionNode'; - -export class ColorSpaceNode extends TempNode { - - constructor( input: Node, method?: string ); - - input: Node; - method: string | undefined; - nodeType: string; - - fromEncoding( encoding: number ): void; - fromDecoding( encoding: number ): void; - copy( source: ColorSpaceNode ): this; - - static Nodes: { - LinearToLinear: FunctionNode; - GammaToLinear: FunctionNode; - LinearToGamma: FunctionNode; - sRGBToLinear: FunctionNode; - LinearTosRGB: FunctionNode; - RGBEToLinear: FunctionNode; - LinearToRGBE: FunctionNode; - RGBMToLinear: FunctionNode; - LinearToRGBM: FunctionNode; - RGBDToLinear: FunctionNode; - LinearToRGBD: FunctionNode; - cLogLuvM: FunctionNode; - LinearToLogLuv: FunctionNode; - cLogLuvInverseM: FunctionNode; - LogLuvToLinear: FunctionNode; - }; - - static LINEAR_TO_LINEAR: string; - - static GAMMA_TO_LINEAR: string; - static LINEAR_TO_GAMMA: string; - - static SRGB_TO_LINEAR: string; - static LINEAR_TO_SRGB: string; - - static RGBE_TO_LINEAR: string; - static LINEAR_TO_RGBE: string; - - static RGBM_TO_LINEAR: string; - static LINEAR_TO_RGBM: string; - - static RGBD_TO_LINEAR: string; - static LINEAR_TO_RGBD: string; - - static LINEAR_TO_LOG_LUV: string; - static LOG_LUV_TO_LINEAR: string; - - static getEncodingComponents( encoding: number ): any[]; - -} diff --git a/examples/jsm/nodes/utils/JoinNode.d.ts b/examples/jsm/nodes/utils/JoinNode.d.ts deleted file mode 100644 index 168ad4743faa8a..00000000000000 --- a/examples/jsm/nodes/utils/JoinNode.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class JoinNode extends TempNode { - - constructor( x: Node, y: Node, z?: Node, w?: Node ); - - x: Node; - y: Node; - z: Node | undefined; - w: Node | undefined; - nodeType: string; - - getNumElements(): number; - copy( source: JoinNode ): this; - -} diff --git a/examples/jsm/nodes/utils/MaxMIPLevelNode.d.ts b/examples/jsm/nodes/utils/MaxMIPLevelNode.d.ts deleted file mode 100644 index 9dddd1eb2f8394..00000000000000 --- a/examples/jsm/nodes/utils/MaxMIPLevelNode.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { FloatNode } from '../inputs/FloatNode'; -import { Node } from '../core/Node'; - -export class MaxMIPLevelNode extends FloatNode { - - constructor( texture: Node ); - - texture: Node; - maxMIPLevel: number; - nodeType: string; - value: number; - -} diff --git a/examples/jsm/nodes/utils/SpecularMIPLevelNode.d.ts b/examples/jsm/nodes/utils/SpecularMIPLevelNode.d.ts deleted file mode 100644 index 792a98b4ad7d11..00000000000000 --- a/examples/jsm/nodes/utils/SpecularMIPLevelNode.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { TempNode } from '../core/TempNode'; -import { MaxMIPLevelNode } from '../utils/MaxMIPLevelNode'; -import { FunctionNode } from '../core/FunctionNode'; - -export class SpecularMIPLevelNode extends TempNode { - - constructor( texture: Node ); - - texture: Node; - maxMIPLevel: MaxMIPLevelNode; - nodeType: string; - - copy( source: SpecularMIPLevelNode ): this; - - static Nodes: { - getSpecularMIPLevel: FunctionNode; - }; - -} diff --git a/examples/jsm/nodes/utils/SubSlot.d.ts b/examples/jsm/nodes/utils/SubSlot.d.ts deleted file mode 100644 index 28bdb7923da9e5..00000000000000 --- a/examples/jsm/nodes/utils/SubSlot.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { TempNode } from '../core/TempNode'; - -export class SubSlots extends TempNode { - - constructor( slots?: object ); - - slots: Node[]; - - copy( source: SubSlots ): this; - -} diff --git a/examples/jsm/nodes/utils/SwitchNode.d.ts b/examples/jsm/nodes/utils/SwitchNode.d.ts deleted file mode 100644 index 2a833e3fa8a6a9..00000000000000 --- a/examples/jsm/nodes/utils/SwitchNode.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { Node } from '../core/Node'; - -export class SwitchNode extends Node { - - constructor( node: Node, components?: string ); - - node: Node; - components: string; - nodeType: string; - - copy( source: SwitchNode ): this; - -} diff --git a/examples/jsm/nodes/utils/TimerNode.d.ts b/examples/jsm/nodes/utils/TimerNode.d.ts deleted file mode 100644 index 4399ba91b8ab15..00000000000000 --- a/examples/jsm/nodes/utils/TimerNode.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { NodeFrame } from '../core/NodeFrame'; -import { FloatNode } from '../inputs/FloatNode'; - -export class TimerNode extends FloatNode { - - constructor( scale?: number, scope?: string, timeScale?: boolean ); - - scale: number; - scope: string; - timeScale: boolean; - nodeType: string; - - getUnique(): boolean; - updateFrame( frame: NodeFrame ): void; - copy( source: TimerNode ): this; - - static GLOBAL: string; - static LOCAL: string; - static DELTA: string; - -} diff --git a/examples/jsm/nodes/utils/UVTransformNode.d.ts b/examples/jsm/nodes/utils/UVTransformNode.d.ts deleted file mode 100644 index 2e56622c486004..00000000000000 --- a/examples/jsm/nodes/utils/UVTransformNode.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { ExpressionNode } from '../core/ExpressionNode'; -import { Matrix3Node } from '../inputs/Matrix3Node'; -import { UVNode } from '../accessors/UVNode'; - -export class UVTransformNode extends ExpressionNode { - - constructor( uv?: UVNode, position?: Matrix3Node ); - - uv: UVNode; - position: Matrix3Node; - - nodeType: string; - - setUvTransform( tx: number, ty: number, sx: number, sy: number, rotation: number, cx?: number, cy?: number ): void; - copy( source: UVTransformNode ): this; - -} diff --git a/examples/jsm/nodes/utils/VelocityNode.d.ts b/examples/jsm/nodes/utils/VelocityNode.d.ts deleted file mode 100644 index b37c3cb9942d73..00000000000000 --- a/examples/jsm/nodes/utils/VelocityNode.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - Object3D, - Vector3 -} from '../../../../src/Three'; - -import { NodeFrame } from '../core/NodeFrame'; -import { Vector3Node } from '../inputs/Vector3Node'; - -export interface VelocityNodeParams { - damping: number; - spring: number; - type: string; -} - -export class VelocityNode extends Vector3Node { - - constructor( target: Object3D, params?: VelocityNodeParams ); - - velocity: Vector3; - moment: Vector3 | undefined; - speed: Vector3 | undefined; - springVelocity: Vector3 | undefined; - lastVelocity: Vector3 | undefined; - - nodeType: string; - - setParams( params: VelocityNodeParams ): void; - setTarget( target: Object3D ): void; - updateFrameVelocity( frame: NodeFrame ): void; - updateFrame( frame: NodeFrame ): void; - copy( source: VelocityNode ): this; - -} diff --git a/examples/jsm/objects/Lensflare.d.ts b/examples/jsm/objects/Lensflare.d.ts deleted file mode 100644 index b29e2435f0f31a..00000000000000 --- a/examples/jsm/objects/Lensflare.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - Mesh, - Texture, - Color -} from '../../../src/Three'; - -export class LensflareElement { - - constructor( texture: Texture, size?: number, distance?: number, color?: Color ); - texture: Texture; - size: number; - distance: number; - color: Color; - -} - -export class Lensflare extends Mesh { - - constructor(); - readonly isLensflare: true; - - addElement( element: LensflareElement ): void; - dispose(): void; - -} diff --git a/examples/jsm/objects/LightningStorm.d.ts b/examples/jsm/objects/LightningStorm.d.ts deleted file mode 100644 index 3d7b3066e3ee67..00000000000000 --- a/examples/jsm/objects/LightningStorm.d.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { - Material, - Vector3 -} from '../../../src/Three'; - -import { LightningStrike, RayParameters } from '../geometries/LightningStrike'; - -export interface StormParams { - size?: number; - minHeight?: number; - maxHeight?: number; - maxSlope?: number; - - maxLightnings?: number; - - lightningMinPeriod?: number; - lightningMaxPeriod?: number; - lightningMinDuration?: number; - lightningMaxDuration?: number; - - lightningParameters?: RayParameters; - lightningMaterial?: Material; - - isEternal?: boolean; - - onRayPosition?: ( source: Vector3, dest: Vector3 ) => void; - onLightningDown?: ( lightning: LightningStrike ) => void; -} - -export class LightningStorm { - - constructor( stormParams?: StormParams ); - update( time: number ): void; - copy( source: LightningStorm ): LightningStorm; - clone(): LightningStorm; - -} diff --git a/examples/jsm/objects/MarchingCubes.d.ts b/examples/jsm/objects/MarchingCubes.d.ts deleted file mode 100644 index 77f2495a08e20e..00000000000000 --- a/examples/jsm/objects/MarchingCubes.d.ts +++ /dev/null @@ -1,74 +0,0 @@ -import { - BufferGeometry, - Material, - ImmediateRenderObject -} from '../../../src/Three'; - -export class MarchingCubes extends ImmediateRenderObject { - - constructor( resolution: number, material: Material, enableUvs?: boolean, enableColors?: boolean ); - - enableUvs: boolean; - enableColors: boolean; - - resolution: number; - - // parameters - - isolation: number; - - // size of field, 32 is pushing it in Javascript :) - - size: number; - size2: number; - size3: number; - halfsize: number; - - // deltas - - delta: number; - yd: number; - zd: number; - - field: Float32Array; - normal_cache: Float32Array; - palette: Float32Array; - - maxCount: number; - count: number; - - hasPositions: boolean; - hasNormals: boolean; - hasColors: boolean; - hasUvs: boolean; - - positionArray: Float32Array; - normalArray: Float32Array; - - uvArray: Float32Array; - colorArray: Float32Array; - - begin(): void; - end(): void; - - addBall( ballx: number, bally: number, ballz: number, strength: number, subtract: number, colors: any ): void; - - addPlaneX( strength: number, subtract: number ): void; - addPlaneY( strength: number, subtract: number ): void; - addPlaneZ( strength: number, subtract: number ): void; - - setCell ( x: number, y: number, z: number, value: number ): void; - getCell ( x: number, y: number, z: number ): number; - - blur( intensity: number ): void; - - reset(): void; - render( renderCallback: any ): void; - generateGeometry(): BufferGeometry; - generateBufferGeometry(): BufferGeometry; - -} - -export const edgeTable: Int32Array[]; -export const triTable: Int32Array[]; - diff --git a/examples/jsm/objects/Reflector.d.ts b/examples/jsm/objects/Reflector.d.ts deleted file mode 100644 index abd18787767d84..00000000000000 --- a/examples/jsm/objects/Reflector.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - Mesh, - BufferGeometry, - Color, - TextureEncoding, - WebGLRenderTarget -} from '../../../src/Three'; - -export interface ReflectorOptions { - color?: Color; - textureWidth?: number; - textureHeight?: number; - clipBias?: number; - shader?: object; - encoding?: TextureEncoding; -} - -export class Reflector extends Mesh { - - constructor( geometry?: BufferGeometry, options?: ReflectorOptions ); - - getRenderTarget(): WebGLRenderTarget; - -} diff --git a/examples/jsm/objects/ReflectorRTT.d.ts b/examples/jsm/objects/ReflectorRTT.d.ts deleted file mode 100644 index e9a1b53f394ed1..00000000000000 --- a/examples/jsm/objects/ReflectorRTT.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { BufferGeometry } from '../../../src/Three'; -import { Reflector, ReflectorOptions } from './Reflector'; - -export class ReflectorRTT extends Reflector { - - constructor( geometry?: BufferGeometry, options?: ReflectorOptions ); - -} diff --git a/examples/jsm/objects/Refractor.d.ts b/examples/jsm/objects/Refractor.d.ts deleted file mode 100644 index 75c4345ec049c8..00000000000000 --- a/examples/jsm/objects/Refractor.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { - Mesh, - BufferGeometry, - Color, - TextureEncoding, - WebGLRenderTarget -} from '../../../src/Three'; - -export interface RefractorOptions { - color?: Color; - textureWidth?: number; - textureHeight?: number; - clipBias?: number; - shader?: object; - encoding?: TextureEncoding; -} - -export class Refractor extends Mesh { - - constructor( geometry?: BufferGeometry, options?: RefractorOptions ); - - getRenderTarget(): WebGLRenderTarget; - -} diff --git a/examples/jsm/objects/ShadowMesh.d.ts b/examples/jsm/objects/ShadowMesh.d.ts deleted file mode 100644 index 0a3834352d2335..00000000000000 --- a/examples/jsm/objects/ShadowMesh.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Mesh, - Plane, - Vector4 -} from '../../../src/Three'; - -export class ShadowMesh extends Mesh { - - constructor(); - - update( plane: Plane, lightPosition4D: Vector4 ): void; - -} diff --git a/examples/jsm/objects/Sky.d.ts b/examples/jsm/objects/Sky.d.ts deleted file mode 100644 index 57778851bc2550..00000000000000 --- a/examples/jsm/objects/Sky.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - BoxGeometry, - Mesh, - ShaderMaterial -} from '../../../src/Three'; - -export class Sky extends Mesh { - - constructor(); - - geometry: BoxGeometry; - material: ShaderMaterial; - - static SkyShader: object; - -} diff --git a/examples/jsm/objects/Water.d.ts b/examples/jsm/objects/Water.d.ts deleted file mode 100644 index 05c6ce8e277ec5..00000000000000 --- a/examples/jsm/objects/Water.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { - BufferGeometry, - Color, - Geometry, - Mesh, - Side, - Texture, - Vector3 -} from '../../../src/Three'; - -export interface WaterOptions { - textureWidth?: number; - textureHeight?: number; - clipBias?: number; - alpha?: number; - time?: number; - waterNormals?: Texture; - sunDirection?: Vector3; - sunColor?: Color | string | number; - waterColor?: Color | string | number; - eye?: Vector3; - distortionScale?: number; - side?: Side; - fog?: boolean; -} - -export class Water extends Mesh { - - constructor( geometry: Geometry | BufferGeometry, options: WaterOptions ); - -} diff --git a/examples/jsm/objects/Water2.d.ts b/examples/jsm/objects/Water2.d.ts deleted file mode 100644 index af0bfe8dabdfcc..00000000000000 --- a/examples/jsm/objects/Water2.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { - BufferGeometry, - Color, - Geometry, - Mesh, - Texture, - TextureEncoding, - Vector2 -} from '../../../src/Three'; - -export interface WaterOptions { - color?: Color | string | number; - textureWidth?: number; - textureHeight?: number; - clipBias?: number; - flowDirection?: Vector2; - flowSpeed?: number; - reflectivity?: number; - scale?: number; - shader?: object; - flowMap?: Texture; - normalMap0?: Texture; - normalMap1?: Texture; - encoding?: TextureEncoding; -} - -export class Water extends Mesh { - - constructor( geometry: Geometry | BufferGeometry, options: WaterOptions ); - -} diff --git a/examples/jsm/physics/AmmoPhysics.d.ts b/examples/jsm/physics/AmmoPhysics.d.ts deleted file mode 100644 index b8ce45980a2352..00000000000000 --- a/examples/jsm/physics/AmmoPhysics.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Mesh, - Vector3 -} from '../../../src/Three'; - -export class AmmoPhysics { - - constructor(); - addMesh( mesh: Mesh, mass: number ): void; - setMeshPosition( mesh: Mesh, position: Vector3, index: number ): void; - -} diff --git a/examples/jsm/postprocessing/AdaptiveToneMappingPass.d.ts b/examples/jsm/postprocessing/AdaptiveToneMappingPass.d.ts deleted file mode 100644 index e6c1f07907a110..00000000000000 --- a/examples/jsm/postprocessing/AdaptiveToneMappingPass.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { - WebGLRenderTarget, - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class AdaptiveToneMappingPass extends Pass { - - constructor( adaptive?: boolean, resolution?: number ); - adaptive: boolean; - resolution: number; - needsInit: number; - luminanceRT: WebGLRenderTarget; - previousLuminanceRT: WebGLRenderTarget; - currentLuminanceRT: WebGLRenderTarget; - copyUniforms: object; - materialCopy: ShaderMaterial; - materialLuminance: ShaderMaterial; - adaptLuminanceShader: object; - materialAdaptiveLum: ShaderMaterial; - materialToneMap: ShaderMaterial; - fsQuad: object; - - reset(): void; - setAdaptive( adaptive: boolean ): void; - setAdaptionRate( rate: number ): void; - setMinLuminance( minLum: number ): void; - setMaxLuminance( maxLum: number ): void; - setAverageLuminance( avgLum: number ): void; - setMiddleGrey( middleGrey: number ): void; - dispose(): void; - -} diff --git a/examples/jsm/postprocessing/AfterimagePass.d.ts b/examples/jsm/postprocessing/AfterimagePass.d.ts deleted file mode 100644 index e7ce2c295eb570..00000000000000 --- a/examples/jsm/postprocessing/AfterimagePass.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - WebGLRenderTarget, - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class AfterimagePass extends Pass { - - constructor( damp?: number ); - shader: object; - uniforms: object; - textureComp: WebGLRenderTarget; - textureOld: WebGLRenderTarget; - shaderMaterial: ShaderMaterial; - compFsQuad: object; - copyFsQuad: object; - -} diff --git a/examples/jsm/postprocessing/BloomPass.d.ts b/examples/jsm/postprocessing/BloomPass.d.ts deleted file mode 100644 index be7dc39389cd60..00000000000000 --- a/examples/jsm/postprocessing/BloomPass.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - WebGLRenderTarget, - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class BloomPass extends Pass { - - constructor( strength?: number, kernelSize?: number, sigma?: number, resolution?: number ); - renderTargetX: WebGLRenderTarget; - renderTargetY: WebGLRenderTarget; - copyUniforms: object; - materialCopy: ShaderMaterial; - convolutionUniforms: object; - materialConvolution: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/BokehPass.d.ts b/examples/jsm/postprocessing/BokehPass.d.ts deleted file mode 100644 index 31c4341ba29543..00000000000000 --- a/examples/jsm/postprocessing/BokehPass.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { - Scene, - Camera, - ShaderMaterial, - WebGLRenderTarget, - MeshDepthMaterial, - Color -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export interface BokehPassParamters { - focus?: number; - aspect?: number; - aperture?: number; - maxblur?: number; - width?: number; - height?: number; -} - -export class BokehPass extends Pass { - - constructor( scene: Scene, camera: Camera, params: BokehPassParamters ); - scene: Scene; - camera: Camera; - renderTargetColor: WebGLRenderTarget; - renderTargetDepth: WebGLRenderTarget; - materialDepth: MeshDepthMaterial; - materialBokeh: ShaderMaterial; - uniforms: object; - fsQuad: object; - oldClearColor: Color; - -} diff --git a/examples/jsm/postprocessing/ClearPass.d.ts b/examples/jsm/postprocessing/ClearPass.d.ts deleted file mode 100644 index 2306651d566937..00000000000000 --- a/examples/jsm/postprocessing/ClearPass.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Color -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class ClearPass extends Pass { - - constructor( clearColor?: Color | string | number, clearAlpha?: number ); - clearColor: Color | string | number; - clearAlpha: number; - -} diff --git a/examples/jsm/postprocessing/CubeTexturePass.d.ts b/examples/jsm/postprocessing/CubeTexturePass.d.ts deleted file mode 100644 index c8ba8fc5309335..00000000000000 --- a/examples/jsm/postprocessing/CubeTexturePass.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - PerspectiveCamera, - CubeTexture, - Mesh, - Scene -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class CubeTexturePass extends Pass { - - constructor( camera: PerspectiveCamera, envMap?: CubeTexture, opacity?: number ); - camera: PerspectiveCamera; - cubeShader: object; - cubeMesh: Mesh; - envMap: CubeTexture; - opacity: number; - cubeScene: Scene; - cubeCamera: PerspectiveCamera; - -} diff --git a/examples/jsm/postprocessing/DotScreenPass.d.ts b/examples/jsm/postprocessing/DotScreenPass.d.ts deleted file mode 100644 index 2129cc45944a40..00000000000000 --- a/examples/jsm/postprocessing/DotScreenPass.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Vector2, - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class DotScreenPass extends Pass { - - constructor( center?: Vector2, angle?: number, scale?: number ); - uniforms: object; - material: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/EffectComposer.d.ts b/examples/jsm/postprocessing/EffectComposer.d.ts deleted file mode 100644 index b152f960ddd1a3..00000000000000 --- a/examples/jsm/postprocessing/EffectComposer.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { - Clock, - WebGLRenderer, - WebGLRenderTarget, -} from '../../../src/Three'; - -import { Pass } from './Pass'; -import { ShaderPass } from './ShaderPass'; - -export class EffectComposer { - - constructor( renderer: WebGLRenderer, renderTarget?: WebGLRenderTarget ); - renderer: WebGLRenderer; - renderTarget1: WebGLRenderTarget; - renderTarget2: WebGLRenderTarget; - writeBuffer: WebGLRenderTarget; - readBuffer: WebGLRenderTarget; - passes: Pass[]; - copyPass: ShaderPass; - clock: Clock; - renderToScreen: boolean; - - swapBuffers(): void; - addPass( pass: Pass ): void; - insertPass( pass: Pass, index: number ): void; - removePass( pass: Pass ): void; - isLastEnabledPass( passIndex: number ): boolean; - render( deltaTime?: number ): void; - reset( renderTarget?: WebGLRenderTarget ): void; - setSize( width: number, height: number ): void; - setPixelRatio( pixelRatio: number ): void; - -} diff --git a/examples/jsm/postprocessing/FilmPass.d.ts b/examples/jsm/postprocessing/FilmPass.d.ts deleted file mode 100644 index dec7d3298fe534..00000000000000 --- a/examples/jsm/postprocessing/FilmPass.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class FilmPass extends Pass { - - constructor( noiseIntensity?: number, scanlinesIntensity?: number, scanlinesCount?: number, grayscale?: number ); - uniforms: object; - material: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/GlitchPass.d.ts b/examples/jsm/postprocessing/GlitchPass.d.ts deleted file mode 100644 index 42e8a6e3a54cda..00000000000000 --- a/examples/jsm/postprocessing/GlitchPass.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - ShaderMaterial, - DataTexture -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class GlitchPass extends Pass { - - constructor( dt_size?: number ); - uniforms: object; - material: ShaderMaterial; - fsQuad: object; - goWild: boolean; - curF: number; - randX: number; - - generateTrigger(): void; - generateHeightmap( dt_size: number ): DataTexture; - -} diff --git a/examples/jsm/postprocessing/HalftonePass.d.ts b/examples/jsm/postprocessing/HalftonePass.d.ts deleted file mode 100644 index 4ef0a0708dd819..00000000000000 --- a/examples/jsm/postprocessing/HalftonePass.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { - ShaderMaterial, -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export interface HalftonePassParameters { - shape?: number; - radius?: number; - rotateR?: number; - rotateB?: number; - rotateG?: number; - scatter?: number; - blending?: number; - blendingMode?: number; - greyscale?: boolean; - disable?: boolean; -} - -export class HalftonePass extends Pass { - - constructor( width: number, height: number, params: HalftonePassParameters ); - uniforms: object; - material: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/LUTPass.d.ts b/examples/jsm/postprocessing/LUTPass.d.ts deleted file mode 100644 index 83c97b0e555d1c..00000000000000 --- a/examples/jsm/postprocessing/LUTPass.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { - DataTexture, - DataTexture3D, -} from '../../../src/Three'; -import { ShaderPass } from './ShaderPass'; - -export interface LUTPassParameters { - lut?: DataTexture | DataTexture3D; - intensity?: number; -} - -export class LUTPass extends ShaderPass { - - lut?: DataTexture | DataTexture3D; - intensity?: number; - constructor( params: LUTPassParameters ); - -} diff --git a/examples/jsm/postprocessing/MaskPass.d.ts b/examples/jsm/postprocessing/MaskPass.d.ts deleted file mode 100644 index 65dce1f012eb88..00000000000000 --- a/examples/jsm/postprocessing/MaskPass.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - Scene, - Camera, -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class MaskPass extends Pass { - - constructor( scene: Scene, camera: Camera ); - scene: Scene; - camera: Camera; - inverse: boolean; - -} - -export class ClearMaskPass extends Pass { - - constructor(); - -} diff --git a/examples/jsm/postprocessing/OutlinePass.d.ts b/examples/jsm/postprocessing/OutlinePass.d.ts deleted file mode 100644 index 26560c64f204eb..00000000000000 --- a/examples/jsm/postprocessing/OutlinePass.d.ts +++ /dev/null @@ -1,66 +0,0 @@ -import { - Vector2, - Scene, - Camera, - Object3D, - Color, - Matrix4, - MeshBasicMaterial, - MeshDepthMaterial, - ShaderMaterial, - WebGLRenderTarget, - Texture -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class OutlinePass extends Pass { - - constructor( resolution: Vector2, scene: Scene, camera: Camera, selectedObjects?: Object3D[] ); - renderScene: Scene; - renderCamera: Camera; - selectedObjects: Object3D[]; - visibleEdgeColor: Color; - hiddenEdgeColor: Color; - edgeGlow: number; - usePatternTexture: boolean; - edgeThickness: number; - edgeStrength: number; - downSampleRatio: number; - pulsePeriod: number; - resolution: Vector2; - patternTexture: Texture; - - maskBufferMaterial: MeshBasicMaterial; - renderTargetMaskBuffer: WebGLRenderTarget; - depthMaterial: MeshDepthMaterial; - prepareMaskMaterial: ShaderMaterial; - renderTargetDepthBuffer: WebGLRenderTarget; - renderTargetMaskDownSampleBuffer: WebGLRenderTarget; - renderTargetBlurBuffer1: WebGLRenderTarget; - renderTargetBlurBuffer2: WebGLRenderTarget; - edgeDetectionMaterial: ShaderMaterial; - renderTargetEdgeBuffer1: WebGLRenderTarget; - renderTargetEdgeBuffer2: WebGLRenderTarget; - separableBlurMaterial1: ShaderMaterial; - separableBlurMaterial2: ShaderMaterial; - overlayMaterial: ShaderMaterial; - copyUniforms: object; - materialCopy: ShaderMaterial; - oldClearColor: Color; - oldClearAlpha: number; - fsQuad: object; - tempPulseColor1: Color; - tempPulseColor2: Color; - textureMatrix: Matrix4; - - dispose(): void; - changeVisibilityOfSelectedObjects( bVisible: boolean ): void; - changeVisibilityOfNonSelectedObjects( bVisible: boolean ): void; - updateTextureMatrix(): void; - getPrepareMaskMaterial(): ShaderMaterial; - getEdgeDetectionMaterial(): ShaderMaterial; - getSeperableBlurMaterial(): ShaderMaterial; - getOverlayMaterial(): ShaderMaterial; - -} diff --git a/examples/jsm/postprocessing/Pass.d.ts b/examples/jsm/postprocessing/Pass.d.ts deleted file mode 100644 index a0247cddb3bd4a..00000000000000 --- a/examples/jsm/postprocessing/Pass.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { - Material, - WebGLRenderer, - WebGLRenderTarget -} from '../../../src/Three'; - -export class Pass { - - constructor(); - enabled: boolean; - needsSwap: boolean; - clear: boolean; - renderToScreen: boolean; - - setSize( width: number, height: number ): void; - render( renderer: WebGLRenderer, writeBuffer: WebGLRenderTarget, readBuffer: WebGLRenderTarget, deltaTime: number, maskActive: boolean ): void; - -} - -export namespace Pass { - class FullScreenQuad { - - constructor( material?: Material ); - - render( renderer: WebGLRenderer ): void; - dispose(): void; - - material: Material; - - } -} diff --git a/examples/jsm/postprocessing/RenderPass.d.ts b/examples/jsm/postprocessing/RenderPass.d.ts deleted file mode 100644 index 97223fdf89e003..00000000000000 --- a/examples/jsm/postprocessing/RenderPass.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { - Scene, - Camera, - Material, - Color -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class RenderPass extends Pass { - - constructor( scene: Scene, camera: Camera, overrideMaterial?: Material, clearColor?: Color, clearAlpha?: number ); - scene: Scene; - camera: Camera; - overrideMaterial: Material; - clearColor: Color; - clearAlpha: number; - clearDepth: boolean; - -} diff --git a/examples/jsm/postprocessing/SAOPass.d.ts b/examples/jsm/postprocessing/SAOPass.d.ts deleted file mode 100644 index abd19a363190f0..00000000000000 --- a/examples/jsm/postprocessing/SAOPass.d.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { - Scene, - Camera, - Material, - MeshDepthMaterial, - MeshNormalMaterial, - ShaderMaterial, - Color, - Vector2, - WebGLRenderer, - WebGLRenderTarget -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export enum OUTPUT { - Beauty, - Default, - SAO, - Depth, - Normal -} - -interface SAOPassParams { - output: OUTPUT; - saoBias: number; - saoIntensity: number; - saoScale: number; - saoKernelRadius: number; - saoMinResolution: number; - saoBlur: number; - saoBlurRadius: number; - saoBlurStdDev: number; - saoBlurDepthCutoff: number; -} - -export class SAOPass extends Pass { - - constructor( scene: Scene, camera: Camera, depthTexture?: boolean, useNormals?: boolean, resolution?: Vector2 ); - scene: Scene; - camera: Camera; - supportsDepthTextureExtension: boolean; - supportsNormalTexture: boolean; - originalClearColor: Color; - oldClearColor: Color; - oldClearAlpha: number; - resolution: Vector2; - saoRenderTarget: WebGLRenderTarget; - blurIntermediateRenderTarget: WebGLRenderTarget; - beautyRenderTarget: WebGLRenderTarget; - normalRenderTarget: WebGLRenderTarget; - depthRenderTarget: WebGLRenderTarget; - depthMaterial: MeshDepthMaterial; - normalMaterial: MeshNormalMaterial; - saoMaterial: ShaderMaterial; - vBlurMaterial: ShaderMaterial; - hBlurMaterial: ShaderMaterial; - materialCopy: ShaderMaterial; - depthCopy: ShaderMaterial; - fsQuad: object; - params: SAOPassParams; - - static OUTPUT: OUTPUT; - - renderPass( renderer: WebGLRenderer, passMaterial: Material, renderTarget: WebGLRenderTarget, clearColor?: Color | string | number, clearAlpha?: number ): void; - renderOverride( renderer: WebGLRenderer, overrideMaterial: Material, renderTarget: WebGLRenderTarget, clearColor?: Color | string | number, clearAlpha?: number ): void; - -} diff --git a/examples/jsm/postprocessing/SMAAPass.d.ts b/examples/jsm/postprocessing/SMAAPass.d.ts deleted file mode 100644 index d881e14da6d1c6..00000000000000 --- a/examples/jsm/postprocessing/SMAAPass.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { - ShaderMaterial, - Texture, - WebGLRenderTarget -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class SMAAPass extends Pass { - - constructor( width: number, height: number ); - edgesRT: WebGLRenderTarget; - weightsRT: WebGLRenderTarget; - areaTexture: Texture; - searchTexture: Texture; - uniformsEdges: object; - materialEdges: ShaderMaterial; - uniformsWeights: object; - materialWeights: ShaderMaterial; - uniformsBlend: object; - materialBlend: ShaderMaterial; - fsQuad: object; - - getAreaTexture(): string; - getSearchTexture(): string; - -} diff --git a/examples/jsm/postprocessing/SSAARenderPass.d.ts b/examples/jsm/postprocessing/SSAARenderPass.d.ts deleted file mode 100644 index 080dd5204331ed..00000000000000 --- a/examples/jsm/postprocessing/SSAARenderPass.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - Scene, - Camera, - Color, - ShaderMaterial, - WebGLRenderTarget -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class SSAARenderPass extends Pass { - - constructor( scene: Scene, camera: Camera, clearColor: Color | string | number, clearAlpha: number ); - scene: Scene; - camera: Camera; - sampleLevel: number; - unbiased: boolean; - clearColor: Color | string | number; - clearAlpha: number; - copyUniforms: object; - copyMaterial: ShaderMaterial; - fsQuad: object; - sampleRenderTarget: undefined | WebGLRenderTarget; - -} diff --git a/examples/jsm/postprocessing/SSAOPass.d.ts b/examples/jsm/postprocessing/SSAOPass.d.ts deleted file mode 100644 index ef68b116b3be68..00000000000000 --- a/examples/jsm/postprocessing/SSAOPass.d.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { - Camera, - Color, - DataTexture, - Material, - MeshNormalMaterial, - Scene, - ShaderMaterial, - Vector3, - WebGLRenderer, - WebGLRenderTarget -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export enum OUTPUT { - Default, - SSAO, - Blur, - Beauty, - Depth, - Normal -} - -export class SSAOPass extends Pass { - - constructor( scene: Scene, camera: Camera, width?: number, height?: number ); - scene: Scene; - camera: Camera; - width: number; - height: boolean; - clear: boolean; - kernelRadius: number; - kernelSize: number; - kernel: Vector3[]; - noiseTexture: DataTexture; - output: OUTPUT; - minDistance: number; - maxDistance: number; - beautyRenderTarget: WebGLRenderTarget; - normalRenderTarget: WebGLRenderTarget; - ssaoRenderTarget: WebGLRenderTarget; - blurRenderTarget: WebGLRenderTarget; - ssaoMaterial: ShaderMaterial; - normalMaterial: MeshNormalMaterial; - blurMaterial: ShaderMaterial; - depthRenderMaterial: ShaderMaterial; - copyMaterial: ShaderMaterial; - fsQuad: object; - originalClearColor: Color; - - static OUTPUT: OUTPUT; - - dipose(): void; - generateSampleKernel(): Vector3[]; - generateRandomKernelRotations(): void; - renderPass( renderer: WebGLRenderer, passMaterial: Material, renderTarget: WebGLRenderTarget, clearColor?: Color | string | number, clearAlpha?: number ): void; - renderOverride( renderer: WebGLRenderer, overrideMaterial: Material, renderTarget: WebGLRenderTarget, clearColor?: Color | string | number, clearAlpha?: number ): void; - -} diff --git a/examples/jsm/postprocessing/SavePass.d.ts b/examples/jsm/postprocessing/SavePass.d.ts deleted file mode 100644 index c1501196d7fadc..00000000000000 --- a/examples/jsm/postprocessing/SavePass.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { - ShaderMaterial, - WebGLRenderTarget -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class SavePass extends Pass { - - constructor( renderTarget: WebGLRenderTarget ); - textureID: string; - renderTarget: WebGLRenderTarget; - uniforms: object; - material: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/ShaderPass.d.ts b/examples/jsm/postprocessing/ShaderPass.d.ts deleted file mode 100644 index 3bded7ac595a8b..00000000000000 --- a/examples/jsm/postprocessing/ShaderPass.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class ShaderPass extends Pass { - - constructor( shader: object, textureID?: string ); - textureID: string; - uniforms: { [name: string]: { value: any } }; - material: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/TAARenderPass.d.ts b/examples/jsm/postprocessing/TAARenderPass.d.ts deleted file mode 100644 index afc544909aab3b..00000000000000 --- a/examples/jsm/postprocessing/TAARenderPass.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Scene, - Camera, - Color -} from '../../../src/Three'; - -import { SSAARenderPass } from './SSAARenderPass'; - -export class TAARenderPass extends SSAARenderPass { - - constructor( scene: Scene, camera: Camera, clearColor: Color | string | number, clearAlpha: number ); - accumulate: boolean; - -} diff --git a/examples/jsm/postprocessing/TexturePass.d.ts b/examples/jsm/postprocessing/TexturePass.d.ts deleted file mode 100644 index 9acfe63f6044af..00000000000000 --- a/examples/jsm/postprocessing/TexturePass.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { - Texture, - ShaderMaterial -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class TexturePass extends Pass { - - constructor( map: Texture, opacity?: number ); - map: Texture; - opacity: number; - uniforms: object; - material: ShaderMaterial; - fsQuad: object; - -} diff --git a/examples/jsm/postprocessing/UnrealBloomPass.d.ts b/examples/jsm/postprocessing/UnrealBloomPass.d.ts deleted file mode 100644 index c817e3a2993f92..00000000000000 --- a/examples/jsm/postprocessing/UnrealBloomPass.d.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { - Color, - MeshBasicMaterial, - ShaderMaterial, - Vector2, - Vector3, - WebGLRenderTarget -} from '../../../src/Three'; - -import { Pass } from './Pass'; - -export class UnrealBloomPass extends Pass { - - constructor( resolution: Vector2, strength: number, radius: number, threshold: number ); - resolution: Vector2; - strength: number; - radius: number; - threshold: number; - clearColor: Color; - renderTargetsHorizontal: WebGLRenderTarget[]; - renderTargetsVertical: WebGLRenderTarget[]; - nMips: number; - renderTargetBright: WebGLRenderTarget; - highPassUniforms: object; - materialHighPassFilter: ShaderMaterial; - separableBlurMaterials: ShaderMaterial[]; - compositeMaterial: ShaderMaterial; - bloomTintColors: Vector3[]; - copyUniforms: object; - materialCopy: ShaderMaterial; - oldClearColor: Color; - oldClearAlpha: number; - basic: MeshBasicMaterial; - fsQuad: object; - - dispose(): void; - getSeperableBlurMaterial(): ShaderMaterial; - getCompositeMaterial(): ShaderMaterial; - -} diff --git a/examples/jsm/renderers/CSS2DRenderer.d.ts b/examples/jsm/renderers/CSS2DRenderer.d.ts deleted file mode 100644 index 0203fa35aef724..00000000000000 --- a/examples/jsm/renderers/CSS2DRenderer.d.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { - Object3D, - Scene, - Camera -} from '../../../src/Three'; - -export class CSS2DObject extends Object3D { - - constructor( element: HTMLElement ); - element: HTMLElement; - - onBeforeRender: ( renderer: unknown, scene: Scene, camera: Camera ) => void; - onAfterRender: ( renderer: unknown, scene: Scene, camera: Camera ) => void; - -} - -export class CSS2DRenderer { - - constructor(); - domElement: HTMLElement; - - getSize(): { width: number, height: number }; - setSize( width: number, height: number ): void; - render( scene: Scene, camera: Camera ): void; - -} diff --git a/examples/jsm/renderers/CSS3DRenderer.d.ts b/examples/jsm/renderers/CSS3DRenderer.d.ts deleted file mode 100644 index 3bd069c42795bf..00000000000000 --- a/examples/jsm/renderers/CSS3DRenderer.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { - Object3D, - Scene, - Camera -} from '../../../src/Three'; - -export class CSS3DObject extends Object3D { - - constructor( element: HTMLElement ); - element: HTMLElement; - - onBeforeRender: ( renderer: unknown, scene: Scene, camera: Camera ) => void; - onAfterRender: ( renderer: unknown, scene: Scene, camera: Camera ) => void; - -} - -export class CSS3DSprite extends CSS3DObject { - - constructor( element: HTMLElement ); - -} - -export class CSS3DRenderer { - - constructor(); - domElement: HTMLElement; - - getSize(): { width: number, height: number }; - setSize( width: number, height: number ): void; - render( scene: Scene, camera: Camera ): void; - -} diff --git a/examples/jsm/renderers/Projector.d.ts b/examples/jsm/renderers/Projector.d.ts deleted file mode 100644 index 3262f855daa2cc..00000000000000 --- a/examples/jsm/renderers/Projector.d.ts +++ /dev/null @@ -1,81 +0,0 @@ -import { - Object3D, - Scene, - Camera, - Vector2, - Vector3, - Vector4, - Color, - Material -} from '../../../src/Three'; - -export class RenderableObject { - - id: number; - object: Object3D; - z: number; - renderOrder: number; - -} - -export class RenderableFace { - - id: number; - v1: RenderableVertex; - v2: RenderableVertex; - v3: RenderableVertex; - normalModel: Vector3; - vertexNormalsModel: Vector3[]; - vertexNormalsLength: number; - color: Color; - material: Material; - uvs: Vector2[]; - z: number; - renderOrder: number; - -} - -export class RenderableVertex { - - position: Vector3; - positionWorld: Vector3; - positionScreen: Vector4; - visible: boolean; - - copy( vertex: RenderableVertex ): void; - -} - -export class RenderableLine { - - id: number; - v1: RenderableVertex; - v2: RenderableVertex; - vertexColors: Color[]; - material: Material; - z: number; - renderOrder: number; - -} - -export class RenderableSprite { - - id: number; - object: Object3D; - x: number; - y: number; - z: number; - rotation: number; - scale: Vector2; - material: Material; - renderOrder: number; - -} - -export class Projector { - - constructor(); - - projectScene( scene: Scene, camera: Camera, sortObjects: boolean, sortElements: boolean ): any; - -} diff --git a/examples/jsm/renderers/SVGRenderer.d.ts b/examples/jsm/renderers/SVGRenderer.d.ts deleted file mode 100644 index c32fe24d391338..00000000000000 --- a/examples/jsm/renderers/SVGRenderer.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { - Object3D, - Color, - Scene, - Camera -} from '../../../src/Three'; - -export class SVGObject extends Object3D { - - constructor( node: SVGElement ); - node: SVGElement; - -} - -export class SVGRenderer { - - constructor(); - domElement: SVGElement; - autoClear: boolean; - sortObjects: boolean; - sortElements: boolean; - overdraw: number; - info: {render: {vertices: number, faces: number}}; - - getSize(): { width: number, height: number }; - setQuality( quality: string ): void; - setClearColor( color: Color, alpha: number ): void; - setPixelRatio(): void; - setSize( width: number, height: number ): void; - setPrecision( precision: number ): void; - clear(): void; - render( scene: Scene, camera: Camera ): void; - -} diff --git a/examples/jsm/shaders/AfterimageShader.d.ts b/examples/jsm/shaders/AfterimageShader.d.ts deleted file mode 100644 index 475c9f365d7627..00000000000000 --- a/examples/jsm/shaders/AfterimageShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const AfterimageShader: { - uniforms: { - damp: Uniform; - tOld: Uniform; - tNew: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/BasicShader.d.ts b/examples/jsm/shaders/BasicShader.d.ts deleted file mode 100644 index 32db3a0091d580..00000000000000 --- a/examples/jsm/shaders/BasicShader.d.ts +++ /dev/null @@ -1,5 +0,0 @@ -export const BasicShader: { - uniforms: {}; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/BleachBypassShader.d.ts b/examples/jsm/shaders/BleachBypassShader.d.ts deleted file mode 100644 index 81783346cfbf7e..00000000000000 --- a/examples/jsm/shaders/BleachBypassShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const BleachBypassShader: { - uniforms: { - tDiffuse: Uniform; - opacity: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/BlendShader.d.ts b/examples/jsm/shaders/BlendShader.d.ts deleted file mode 100644 index bdbbe20151bce9..00000000000000 --- a/examples/jsm/shaders/BlendShader.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const BlendShader: { - uniforms: { - tDiffuse1: Uniform; - tDiffuse2: Uniform; - mixRatio: Uniform; - opacity: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/BokehShader.d.ts b/examples/jsm/shaders/BokehShader.d.ts deleted file mode 100644 index c68ca08db0952b..00000000000000 --- a/examples/jsm/shaders/BokehShader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const BokehShader: { - defines: { - DEPTH_PACKING: number; - PERSPECTIVE_CAMERA: number; - } - uniforms: { - tColor: Uniform; - tDepth: Uniform; - focus: Uniform; - aspect: Uniform; - aperture: Uniform; - maxblur: Uniform; - nearClip: Uniform; - farClip: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/BokehShader2.d.ts b/examples/jsm/shaders/BokehShader2.d.ts deleted file mode 100644 index 958180ce194213..00000000000000 --- a/examples/jsm/shaders/BokehShader2.d.ts +++ /dev/null @@ -1,42 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const BokehShader: { - uniforms: { - textureWidth: Uniform; - textureHeight: Uniform; - focalDepth: Uniform; - focalLength: Uniform; - fstop: Uniform; - tColor: Uniform; - tDepth: Uniform; - maxblur: Uniform; - showFocus: Uniform; - manualdof: Uniform; - vignetting: Uniform; - depthblur: Uniform; - threshold: Uniform; - gain: Uniform; - bias: Uniform; - fringe: Uniform; - znear: Uniform; - zfar: Uniform; - noise: Uniform; - dithering: Uniform; - pentagon: Uniform; - shaderFocus: Uniform; - focusCoords: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const BokehDepthShader: { - uniforms: { - mNear: Uniform; - mFar: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/BrightnessContrastShader.d.ts b/examples/jsm/shaders/BrightnessContrastShader.d.ts deleted file mode 100644 index 630bdf21bfcb54..00000000000000 --- a/examples/jsm/shaders/BrightnessContrastShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const BrightnessContrastShader: { - uniforms: { - tDiffuse: Uniform; - brightness: Uniform; - contrast: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/ColorCorrectionShader.d.ts b/examples/jsm/shaders/ColorCorrectionShader.d.ts deleted file mode 100644 index 86aeb07dc6c999..00000000000000 --- a/examples/jsm/shaders/ColorCorrectionShader.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const ColorCorrectionShader: { - uniforms: { - tDiffuse: Uniform; - powRGB: Uniform; - mulRGB: Uniform; - addRGB: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/ColorifyShader.d.ts b/examples/jsm/shaders/ColorifyShader.d.ts deleted file mode 100644 index c2cdec237e7d98..00000000000000 --- a/examples/jsm/shaders/ColorifyShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const ColorifyShader: { - uniforms: { - tDiffuse: Uniform; - color: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/ConvolutionShader.d.ts b/examples/jsm/shaders/ConvolutionShader.d.ts deleted file mode 100644 index 69e9bb5cce018f..00000000000000 --- a/examples/jsm/shaders/ConvolutionShader.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const ConvolutionShader: { - defines: { - KERNEL_SIZE_FLOAT: string; - KERNEL_SIZE_INT: string; - }, - uniforms: { - tDiffuse: Uniform; - uImageIncrement: Uniform; - cKernel: Uniform; - }; - vertexShader: string; - fragmentShader: string; - - buildKernel( sigma: number ): number[]; -}; diff --git a/examples/jsm/shaders/CopyShader.d.ts b/examples/jsm/shaders/CopyShader.d.ts deleted file mode 100644 index 6d6a6e6e3abea4..00000000000000 --- a/examples/jsm/shaders/CopyShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const CopyShader: { - uniforms: { - tDiffuse: Uniform; - opacity: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/DOFMipMapShader.d.ts b/examples/jsm/shaders/DOFMipMapShader.d.ts deleted file mode 100644 index f8e2cd4ccff463..00000000000000 --- a/examples/jsm/shaders/DOFMipMapShader.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const DOFMipMapShader: { - uniforms: { - tColor: Uniform; - tDepth: Uniform; - focus: Uniform; - maxblur: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/DepthLimitedBlurShader.d.ts b/examples/jsm/shaders/DepthLimitedBlurShader.d.ts deleted file mode 100644 index f69acba89aee9f..00000000000000 --- a/examples/jsm/shaders/DepthLimitedBlurShader.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { - Uniform, - Vector2, - Material -} from '../../../src/Three'; - -export const DepthLimitedBlurShader: { - defines: { - KERNEL_RADIUS: number; - DEPTH_PACKING: number; - PERSPECTIVE_CAMERA: number; - }; - uniforms: { - tDiffuse: Uniform; - size: Uniform; - sampleUvOffsets: Uniform; - sampleWeights: Uniform; - tDepth: Uniform; - cameraNear: Uniform; - cameraFar: Uniform; - depthCutoff: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const BlurShaderUtils: { - createSampleWeights( kernelRadius: number, stdDev: number ): number[]; - createSampleOffsets( kernelRadius: number, uvIncrement: Vector2 ): Vector2[]; - configure( configure: Material, kernelRadius: number, stdDev: number, uvIncrement: Vector2 ): void; -}; diff --git a/examples/jsm/shaders/DigitalGlitch.d.ts b/examples/jsm/shaders/DigitalGlitch.d.ts deleted file mode 100644 index 2d0d6cf6550b79..00000000000000 --- a/examples/jsm/shaders/DigitalGlitch.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const DigitalGlitch: { - uniforms: { - tDiffuse: Uniform; - tDisp: Uniform; - byp: Uniform; - amount: Uniform; - angle: Uniform; - seed: Uniform; - seed_x: Uniform; - seed_y: Uniform; - distortion_x: Uniform; - distortion_y: Uniform; - col_s: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/DotScreenShader.d.ts b/examples/jsm/shaders/DotScreenShader.d.ts deleted file mode 100644 index f863a06d6d0863..00000000000000 --- a/examples/jsm/shaders/DotScreenShader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const DotScreenShader: { - uniforms: { - tDiffuse: Uniform; - tSize: Uniform; - center: Uniform; - angle: Uniform; - scale: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/FXAAShader.d.ts b/examples/jsm/shaders/FXAAShader.d.ts deleted file mode 100644 index b3d61fe7417c03..00000000000000 --- a/examples/jsm/shaders/FXAAShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const FXAAShader: { - uniforms: { - tDiffuse: Uniform; - resolution: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/FilmShader.d.ts b/examples/jsm/shaders/FilmShader.d.ts deleted file mode 100644 index 733e638279fa36..00000000000000 --- a/examples/jsm/shaders/FilmShader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const FilmShader: { - uniforms: { - tDiffuse: Uniform; - time: Uniform; - nIntensity: Uniform; - sIntensity: Uniform; - sCount: Uniform; - grayscale: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/FocusShader.d.ts b/examples/jsm/shaders/FocusShader.d.ts deleted file mode 100644 index 2d72ddae8eaae4..00000000000000 --- a/examples/jsm/shaders/FocusShader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const FocusShader: { - uniforms: { - tDiffuse: Uniform; - screenWidth: Uniform; - screenHeight: Uniform; - sampleDistance: Uniform; - waveFactor: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/FreiChenShader.d.ts b/examples/jsm/shaders/FreiChenShader.d.ts deleted file mode 100644 index 394b0046a268c4..00000000000000 --- a/examples/jsm/shaders/FreiChenShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const FreiChenShader: { - uniforms: { - tDiffuse: Uniform; - aspect: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/FresnelShader.d.ts b/examples/jsm/shaders/FresnelShader.d.ts deleted file mode 100644 index 88447dfcad73bc..00000000000000 --- a/examples/jsm/shaders/FresnelShader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const FresnelShader: { - uniforms: { - mRefractionRatio: Uniform; - mFresnelBias: Uniform; - mFresnelPower: Uniform; - mFresnelScale: Uniform; - tCube: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/GammaCorrectionShader.d.ts b/examples/jsm/shaders/GammaCorrectionShader.d.ts deleted file mode 100644 index 3108bca590f07c..00000000000000 --- a/examples/jsm/shaders/GammaCorrectionShader.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const GammaCorrectionShader: { - uniforms: { - tDiffuse: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/GodRaysShader.d.ts b/examples/jsm/shaders/GodRaysShader.d.ts deleted file mode 100644 index f5adf64783ec7b..00000000000000 --- a/examples/jsm/shaders/GodRaysShader.d.ts +++ /dev/null @@ -1,42 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const GodRaysDepthMaskShader: { - uniforms: { - tInput: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const GodRaysGenerateShader: { - uniforms: { - tInput: Uniform; - fStepSize: Uniform; - vSunPositionScreenSpace: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const GodRaysCombineShader: { - uniforms: { - tColors: Uniform; - tGodRays: Uniform; - fGodRayIntensity: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const GodRaysFakeSunShader: { - uniforms: { - vSunPositionScreenSpace: Uniform; - fAspect: Uniform; - sunColor: Uniform; - bgColor: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/HalftoneShader.d.ts b/examples/jsm/shaders/HalftoneShader.d.ts deleted file mode 100644 index f951612e164a0a..00000000000000 --- a/examples/jsm/shaders/HalftoneShader.d.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const HalftoneShader: { - uniforms: { - tDiffuse: Uniform; - shape: Uniform; - radius: Uniform; - rotateR: Uniform; - rotateG: Uniform; - rotateB: Uniform; - scatter: Uniform; - width: Uniform; - height: Uniform; - blending: Uniform; - blendingMode: Uniform; - greyscale: Uniform; - disable: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/HorizontalBlurShader.d.ts b/examples/jsm/shaders/HorizontalBlurShader.d.ts deleted file mode 100644 index 0b253779c7518d..00000000000000 --- a/examples/jsm/shaders/HorizontalBlurShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const HorizontalBlurShader: { - uniforms: { - tDiffuse: Uniform; - h: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/HorizontalTiltShiftShader.d.ts b/examples/jsm/shaders/HorizontalTiltShiftShader.d.ts deleted file mode 100644 index e22ce403536113..00000000000000 --- a/examples/jsm/shaders/HorizontalTiltShiftShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const HorizontalTiltShiftShader: { - uniforms: { - tDiffuse: Uniform; - h: Uniform; - r: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/HueSaturationShader.d.ts b/examples/jsm/shaders/HueSaturationShader.d.ts deleted file mode 100644 index 7fbe0e69f4439f..00000000000000 --- a/examples/jsm/shaders/HueSaturationShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const HueSaturationShader: { - uniforms: { - tDiffuse: Uniform; - hue: Uniform; - saturation: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/KaleidoShader.d.ts b/examples/jsm/shaders/KaleidoShader.d.ts deleted file mode 100644 index 44502e5d61b185..00000000000000 --- a/examples/jsm/shaders/KaleidoShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const KaleidoShader: { - uniforms: { - tDiffuse: Uniform; - sides: Uniform; - angle: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/LuminosityHighPassShader.d.ts b/examples/jsm/shaders/LuminosityHighPassShader.d.ts deleted file mode 100644 index 0d1667325c6045..00000000000000 --- a/examples/jsm/shaders/LuminosityHighPassShader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const LuminosityHighPassShader: { - shaderID: string; - uniforms: { - tDiffuse: Uniform; - luminosityThreshold: Uniform; - smoothWidth: Uniform; - defaultColor: Uniform; - defaultOpacity: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/LuminosityShader.d.ts b/examples/jsm/shaders/LuminosityShader.d.ts deleted file mode 100644 index 5f9b16c9fc9313..00000000000000 --- a/examples/jsm/shaders/LuminosityShader.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const LuminosityShader: { - uniforms: { - tDiffuse: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/MirrorShader.d.ts b/examples/jsm/shaders/MirrorShader.d.ts deleted file mode 100644 index 243045527c75a2..00000000000000 --- a/examples/jsm/shaders/MirrorShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const MirrorShader: { - uniforms: { - tDiffuse: Uniform; - side: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/NormalMapShader.d.ts b/examples/jsm/shaders/NormalMapShader.d.ts deleted file mode 100644 index 398d735e51c31c..00000000000000 --- a/examples/jsm/shaders/NormalMapShader.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const NormalMapShader: { - uniforms: { - heightMap: Uniform; - resolution: Uniform; - scale: Uniform; - height: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/OceanShaders.d.ts b/examples/jsm/shaders/OceanShaders.d.ts deleted file mode 100644 index 1e94a02c3b269e..00000000000000 --- a/examples/jsm/shaders/OceanShaders.d.ts +++ /dev/null @@ -1,73 +0,0 @@ -import { - Uniform, -} from '../../../src/Three'; - -export const OceanShaders: { - - ocean_sim_vertex: { - vertexShader: string; - } - ocean_subtransform: { - uniforms: { - u_input: Uniform, - u_transformSize: Uniform, - u_subtransformSize: Uniform, - }, - fragmentShader: string; - } - ocean_initial_spectrum: { - uniforms: { - u_wind: Uniform, - u_resolution: Uniform, - u_size: Uniform, - }, - vertexShader: string; - fragmentShader: string; - } - ocean_phase: { - uniforms: { - u_phases: Uniform, - u_deltaTime: Uniform, - u_resolution: Uniform, - u_size: Uniform, - }, - vertexShader: string; - fragmentShader: string; - } - ocean_spectrum: { - uniforms: { - u_size: Uniform, - u_resolution: Uniform, - u_choppiness: Uniform, - u_phases: Uniform, - u_initialSpectrum: Uniform, - }, - fragmentShader: string; - } - ocean_normals: { - uniforms: { - u_displacementMap: Uniform, - u_resolution: Uniform, - u_size: Uniform, - }, - fragmentShader: string; - } - ocean_main: { - uniforms: { - u_displacementMap: Uniform, - u_normalMap: Uniform, - u_geometrySize: Uniform, - u_size: Uniform, - u_projectionMatrix: Uniform, - u_viewMatrix: Uniform, - u_cameraPosition: Uniform, - u_skyColor: Uniform, - u_oceanColor: Uniform, - u_sunDirection: Uniform, - u_exposure: Uniform, - }, - vertexShader: string; - fragmentShader: string; - } - -}; diff --git a/examples/jsm/shaders/ParallaxShader.d.ts b/examples/jsm/shaders/ParallaxShader.d.ts deleted file mode 100644 index cad87e8be4fe1a..00000000000000 --- a/examples/jsm/shaders/ParallaxShader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const ParallaxShader: { - modes: { - none: string; - basic: string; - steep: string; - occlusion: string; - relief: string; - }; - uniforms: { - bumpMap: Uniform; - map: Uniform; - parallaxScale: Uniform; - parallaxMinLayers: Uniform; - parallaxMaxLayers: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/PixelShader.d.ts b/examples/jsm/shaders/PixelShader.d.ts deleted file mode 100644 index 4374577fc2e5e8..00000000000000 --- a/examples/jsm/shaders/PixelShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const PixelShader: { - uniforms: { - tDiffuse: Uniform; - resolution: Uniform; - pixelSize: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/RGBShiftShader.d.ts b/examples/jsm/shaders/RGBShiftShader.d.ts deleted file mode 100644 index 7da0b1bb4e4339..00000000000000 --- a/examples/jsm/shaders/RGBShiftShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const RGBShiftShader: { - uniforms: { - tDiffuse: Uniform; - amount: Uniform; - angle: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/SAOShader.d.ts b/examples/jsm/shaders/SAOShader.d.ts deleted file mode 100644 index bdeb287a13d891..00000000000000 --- a/examples/jsm/shaders/SAOShader.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const SAOShader: { - defines: { - NUM_SAMPLES: number; - NUM_RINGS: number; - NORMAL_TEXTURE: number; - DIFFUSE_TEXTURE: number; - DEPTH_PACKING: number; - PERSPECTIVE_CAMERA: number; - }; - uniforms: { - tDepth: Uniform; - tDiffuse: Uniform; - tNormal: Uniform; - size: Uniform; - cameraNear: Uniform; - cameraFar: Uniform; - cameraProjectionMatrix: Uniform; - cameraInverseProjectionMatrix: Uniform; - scale: Uniform; - intensity: Uniform; - bias: Uniform; - minResolution: Uniform; - kernelRadius: Uniform; - randomSeed: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/SMAAShader.d.ts b/examples/jsm/shaders/SMAAShader.d.ts deleted file mode 100644 index 969637124708d4..00000000000000 --- a/examples/jsm/shaders/SMAAShader.d.ts +++ /dev/null @@ -1,42 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const SMAAEdgesShader: { - defines: { - SMAA_THRESHOLD: string; - }, - uniforms: { - tDiffuse: Uniform; - resolution: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const SMAAWeightsShader: { - defines: { - SMAA_MAX_SEARCH_STEPS: string; - SMAA_AREATEX_MAX_DISTANCE: string; - SMAA_AREATEX_PIXEL_SIZE: string; - SMAA_AREATEX_SUBTEX_SIZE: string; - }, - uniforms: { - tDiffuse: Uniform; - tArea: Uniform; - tSearch: Uniform; - resolution: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const SMAABlendShader: { - uniforms: { - tDiffuse: Uniform; - tColor: Uniform; - resolution: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/SSAOShader.d.ts b/examples/jsm/shaders/SSAOShader.d.ts deleted file mode 100644 index 817d8f9821e5fd..00000000000000 --- a/examples/jsm/shaders/SSAOShader.d.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const SSAOShader: { - defines: { - PERSPECTIVE_CAMERA: number; - KERNEL_SIZE: number; - }; - uniforms: { - tDiffuse: Uniform; - tNormal: Uniform; - tDepth: Uniform; - tNoise: Uniform; - kernel: Uniform; - cameraNear: Uniform; - cameraFar: Uniform; - resolution: Uniform; - cameraProjectionMatrix: Uniform; - cameraInverseProjectionMatrix: Uniform; - kernelRadius: Uniform; - minDistance: Uniform; - maxDistance: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const SSAODepthShader: { - defines: { - PERSPECTIVE_CAMERA: number; - }; - uniforms: { - tDepth: Uniform; - cameraNear: Uniform; - cameraFar: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const SSAOBlurShader: { - uniforms: { - tDiffuse: Uniform; - resolution: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/SepiaShader.d.ts b/examples/jsm/shaders/SepiaShader.d.ts deleted file mode 100644 index 23ed3598e4be0f..00000000000000 --- a/examples/jsm/shaders/SepiaShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const SepiaShader: { - uniforms: { - tDiffuse: Uniform; - amount: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/SobelOperatorShader.d.ts b/examples/jsm/shaders/SobelOperatorShader.d.ts deleted file mode 100644 index 7a20e8f2d14012..00000000000000 --- a/examples/jsm/shaders/SobelOperatorShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const SobelOperatorShader: { - uniforms: { - tDiffuse: Uniform; - resolution: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/SubsurfaceScatteringShader.d.ts b/examples/jsm/shaders/SubsurfaceScatteringShader.d.ts deleted file mode 100644 index 9aa06bb288b7f1..00000000000000 --- a/examples/jsm/shaders/SubsurfaceScatteringShader.d.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const SubsurfaceScatteringShader: { - uniforms: { - alphaMap: Uniform; - ambientLightColor: Uniform; - color: Uniform; - diffuse: Uniform; - directionalLights: Uniform; - directionalShadowMap: Uniform; - directionalShadowMatrix: Uniform; - emissive: Uniform; - hemisphereLights: Uniform; - lightProbe: Uniform; - map: Uniform; - opacity: Uniform; - pointLights: Uniform; - pointShadowMap: Uniform; - pointShadowMatrix: Uniform; - rectAreaLights: Uniform; - shininess: Uniform; - specular: Uniform; - spotLights: Uniform; - spotShadowMap: Uniform; - spotShadowMatrix: Uniform; - thicknessAmbient: Uniform; - thicknessAttenuation: Uniform; - thicknessColor: Uniform; - thicknessDistortion: Uniform; - thicknessMap: Uniform; - thicknessPower: Uniform; - thicknessScale: Uniform; - uvTransform: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/TechnicolorShader.d.ts b/examples/jsm/shaders/TechnicolorShader.d.ts deleted file mode 100644 index 2b3cc5b0e26845..00000000000000 --- a/examples/jsm/shaders/TechnicolorShader.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const TechnicolorShader: { - uniforms: { - tDiffuse: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/ToneMapShader.d.ts b/examples/jsm/shaders/ToneMapShader.d.ts deleted file mode 100644 index b8785923202d4b..00000000000000 --- a/examples/jsm/shaders/ToneMapShader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const ToneMapShader: { - uniforms: { - tDiffuse: Uniform; - averageLuminance: Uniform; - luminanceMap: Uniform; - maxLuminance: Uniform; - minLuminance: Uniform; - middleGrey: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/ToonShader.d.ts b/examples/jsm/shaders/ToonShader.d.ts deleted file mode 100644 index c190f37b8f1818..00000000000000 --- a/examples/jsm/shaders/ToonShader.d.ts +++ /dev/null @@ -1,56 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const ToonShader1: { - uniforms: { - uDirLightPos: Uniform; - uDirLightColor: Uniform; - uAmbientLightColor: Uniform; - uBaseColor: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const ToonShader2: { - uniforms: { - uDirLightPos: Uniform; - uDirLightColor: Uniform; - uAmbientLightColor: Uniform; - uBaseColor: Uniform; - uLineColor1: Uniform; - uLineColor2: Uniform; - uLineColor3: Uniform; - uLineColor4: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const ToonShaderHatching: { - uniforms: { - uDirLightPos: Uniform; - uDirLightColor: Uniform; - uAmbientLightColor: Uniform; - uBaseColor: Uniform; - uLineColor1: Uniform; - uLineColor2: Uniform; - uLineColor3: Uniform; - uLineColor4: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; - -export const ToonShaderDotted: { - uniforms: { - uDirLightPos: Uniform; - uDirLightColor: Uniform; - uAmbientLightColor: Uniform; - uBaseColor: Uniform; - uLineColor1: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/TriangleBlurShader.d.ts b/examples/jsm/shaders/TriangleBlurShader.d.ts deleted file mode 100644 index 02fb1efdac5f1e..00000000000000 --- a/examples/jsm/shaders/TriangleBlurShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const TriangleBlurShader: { - uniforms: { - texture: Uniform; - delta: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/UnpackDepthRGBAShader.d.ts b/examples/jsm/shaders/UnpackDepthRGBAShader.d.ts deleted file mode 100644 index cf38201fac6618..00000000000000 --- a/examples/jsm/shaders/UnpackDepthRGBAShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const UnpackDepthRGBAShader: { - uniforms: { - tDiffuse: Uniform; - opacity: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/VerticalBlurShader.d.ts b/examples/jsm/shaders/VerticalBlurShader.d.ts deleted file mode 100644 index a6d3a55d93097f..00000000000000 --- a/examples/jsm/shaders/VerticalBlurShader.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const VerticalBlurShader: { - uniforms: { - tDiffuse: Uniform; - v: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/VerticalTiltShiftShader.d.ts b/examples/jsm/shaders/VerticalTiltShiftShader.d.ts deleted file mode 100644 index ffb8cc62a888a2..00000000000000 --- a/examples/jsm/shaders/VerticalTiltShiftShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const VerticalTiltShiftShader: { - uniforms: { - tDiffuse: Uniform; - v: Uniform; - r: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/VignetteShader.d.ts b/examples/jsm/shaders/VignetteShader.d.ts deleted file mode 100644 index 1319966a32a743..00000000000000 --- a/examples/jsm/shaders/VignetteShader.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const VignetteShader: { - uniforms: { - tDiffuse: Uniform; - offset: Uniform; - darkness: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/VolumeShader.d.ts b/examples/jsm/shaders/VolumeShader.d.ts deleted file mode 100644 index b60ee0caefd545..00000000000000 --- a/examples/jsm/shaders/VolumeShader.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const VolumeRenderShader1: { - uniforms: { - u_size: Uniform; - u_renderstyle: Uniform; - u_renderthreshold: Uniform; - u_clim: Uniform; - u_data: Uniform; - u_cmdata: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/shaders/WaterRefractionShader.d.ts b/examples/jsm/shaders/WaterRefractionShader.d.ts deleted file mode 100644 index c26b60fd87a2e9..00000000000000 --- a/examples/jsm/shaders/WaterRefractionShader.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { - Uniform -} from '../../../src/Three'; - -export const WaterRefractionShader: { - uniforms: { - color: Uniform; - time: Uniform; - tDiffuse: Uniform; - tDudv: Uniform; - textureMatrix: Uniform; - }; - vertexShader: string; - fragmentShader: string; -}; diff --git a/examples/jsm/utils/BufferGeometryUtils.d.ts b/examples/jsm/utils/BufferGeometryUtils.d.ts deleted file mode 100644 index 09d7b332a2835e..00000000000000 --- a/examples/jsm/utils/BufferGeometryUtils.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { BufferAttribute, BufferGeometry, InterleavedBufferAttribute, TrianglesDrawModes, Mesh, Line, Points } from '../../../src/Three'; - -export namespace BufferGeometryUtils { - export function mergeBufferGeometries( geometries: BufferGeometry[], useGroups?: boolean ): BufferGeometry; - export function mergeBufferAttributes( attributes: BufferAttribute[] ): BufferAttribute; - export function interleaveAttributes( attributes: BufferAttribute[] ): InterleavedBufferAttribute; - export function estimateBytesUsed( geometry: BufferGeometry ): number; - export function mergeVertices( geometry: BufferGeometry, tolerance?: number ): BufferGeometry; - export function toTrianglesDrawMode( geometry: BufferGeometry, drawMode: TrianglesDrawModes ): BufferGeometry; - export function computeMorphedAttributes( object: Mesh | Line | Points ): Object; -} diff --git a/examples/jsm/utils/GeometryCompressionUtils.d.ts b/examples/jsm/utils/GeometryCompressionUtils.d.ts deleted file mode 100644 index 92323b95567514..00000000000000 --- a/examples/jsm/utils/GeometryCompressionUtils.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Mesh } from '../../../src/Three'; - -export namespace GeometryCompressionUtils { - - export function compressNormals( mesh: Mesh, encodeMethod: String ): void; - export function compressPositions( mesh: Mesh ): void; - export function compressUvs( mesh: Mesh ): void; - -} diff --git a/examples/jsm/utils/GeometryUtils.d.ts b/examples/jsm/utils/GeometryUtils.d.ts deleted file mode 100644 index 0881bc2ab54042..00000000000000 --- a/examples/jsm/utils/GeometryUtils.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { - Vector3 -} from '../../../src/Three'; - -export namespace GeometryUtils { - export function hilbert2D( center?: Vector3, size?: number, iterations?: number, v0?: number, v1?: number, v2?: number, v3?: number ): Vector3[]; - export function hilbert3D( center?: Vector3, size?: number, iterations?: number, v0?: number, v1?: number, v2?: number, v3?: number, v4?: number, v5?: number, v6?: number, v7?: number ): Vector3[]; - export function gosper( size?: number ): number[]; -} diff --git a/examples/jsm/utils/RoughnessMipmapper.d.ts b/examples/jsm/utils/RoughnessMipmapper.d.ts deleted file mode 100644 index 6ff65922b8cb96..00000000000000 --- a/examples/jsm/utils/RoughnessMipmapper.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - WebGLRenderer, - MeshStandardMaterial -} from '../../../src/Three'; - -export class RoughnessMipmapper { - - constructor( renderer:WebGLRenderer ); - generateMipmaps( material:MeshStandardMaterial ): void; - dispose(): void; - -} diff --git a/examples/jsm/utils/SceneUtils.d.ts b/examples/jsm/utils/SceneUtils.d.ts deleted file mode 100644 index e7714878fe5e08..00000000000000 --- a/examples/jsm/utils/SceneUtils.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Geometry, Group, InstancedMesh, Material, Object3D, Scene } from '../../../src/Three'; - -export namespace SceneUtils { - export function createMeshesFromInstancedMesh( instancedMesh: InstancedMesh ): Group; - export function createMultiMaterialObject( geometry: Geometry, materials: Material[] ): Group; - /** - * @deprecated Use scene.attach( child ) instead. - */ - export function detach( child: Object3D, parent: Object3D, scene: Scene ): void; - /** - * @deprecated Use parent.attach( child ) instead. - */ - export function attach( child: Object3D, scene: Scene, parent: Object3D ): void; -} diff --git a/examples/jsm/utils/ShadowMapViewer.d.ts b/examples/jsm/utils/ShadowMapViewer.d.ts deleted file mode 100644 index 0e78c60064ce38..00000000000000 --- a/examples/jsm/utils/ShadowMapViewer.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { Light } from '../../../src/Three'; - -export class ShadowMapViewer { - - constructor( light: Light ) - -} - - - diff --git a/examples/jsm/utils/SkeletonUtils.d.ts b/examples/jsm/utils/SkeletonUtils.d.ts deleted file mode 100644 index 0f84be92aa9a86..00000000000000 --- a/examples/jsm/utils/SkeletonUtils.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { AnimationClip, Bone, Matrix4, Object3D, Skeleton, SkeletonHelper } from '../../../src/Three'; - -export namespace SkeletonUtils { - export function retarget( target: Object3D | Skeleton, - source: Object3D | Skeleton, - options: {} ): void; - - export function retargetClip( target: Skeleton | Object3D, - source: Skeleton | Object3D, - clip: AnimationClip, - options: {} ): AnimationClip; - - export function getHelperFromSkeleton( skeleton: Skeleton ): SkeletonHelper; - - export function getSkeletonOffsets( target: Object3D | Skeleton, - source: Object3D | Skeleton, - options: {} ): Matrix4[]; - - export function renameBones( skeleton: Skeleton, names: {} ): any; - - export function getBones( skeleton: Skeleton | Bone[] ): Bone[]; - - export function getBoneByName( name: string, skeleton: Skeleton ): Bone; - - export function getNearestBone( bone: Bone, names: {} ): Bone; - - export function findBoneTrackData( name: string, tracks: any[] ): {}; - - export function getEqualsBonesNames( skeleton: Skeleton, targetSkeleton: Skeleton ): string[]; - - export function clone( source: Object3D ): Object3D; -} diff --git a/examples/jsm/utils/UVsDebug.d.ts b/examples/jsm/utils/UVsDebug.d.ts deleted file mode 100644 index 9bf2bdc5a71129..00000000000000 --- a/examples/jsm/utils/UVsDebug.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -import { Geometry } from '../../../src/Three'; - -export function UVsDebug( geometry: Geometry, size: number ): HTMLCanvasElement; diff --git a/examples/jsm/webxr/ARButton.d.ts b/examples/jsm/webxr/ARButton.d.ts deleted file mode 100644 index 03841597a36655..00000000000000 --- a/examples/jsm/webxr/ARButton.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { - WebGLRenderer -} from '../../../src/Three'; - -export namespace ARButton { - export function createButton( renderer: WebGLRenderer, sessionInit?: any ): HTMLElement; -} diff --git a/examples/jsm/webxr/VRButton.d.ts b/examples/jsm/webxr/VRButton.d.ts deleted file mode 100644 index 6ded0e85279c4d..00000000000000 --- a/examples/jsm/webxr/VRButton.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { - WebGLRenderer -} from '../../../src/Three'; - -export namespace VRButton { - export function createButton( renderer: WebGLRenderer ): HTMLElement; -} diff --git a/examples/jsm/webxr/XRControllerModelFactory.d.ts b/examples/jsm/webxr/XRControllerModelFactory.d.ts deleted file mode 100644 index b10c4fed472881..00000000000000 --- a/examples/jsm/webxr/XRControllerModelFactory.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { - Group, - Object3D, - Texture -} from '../../../src/Three'; - -import { GLTFLoader } from '../loaders/GLTFLoader'; - -export class XRControllerModel extends Object3D { - - constructor(); - - motionController: any; - - setEnvironmentMap( envMap: Texture ): XRControllerModel; - -} - -export class XRControllerModelFactory { - - constructor( gltfLoader?: GLTFLoader ); - gltfLoader: GLTFLoader | null; - path: string; - - createControllerModel( controller: Group ): XRControllerModel; - -} diff --git a/examples/jsm/webxr/XRHandModelFactory.d.ts b/examples/jsm/webxr/XRHandModelFactory.d.ts deleted file mode 100644 index e93ef4b2b550c9..00000000000000 --- a/examples/jsm/webxr/XRHandModelFactory.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - Group, - Object3D, -} from '../../../src/Three'; - -export class XRHandModel extends Object3D { - - constructor(); - - motionController: any; - -} - -export class XRHandModelFactory { - - constructor(); - path: string; - - createHandModel( - controller: Group, - profile?: 'spheres' | 'boxes' | 'oculus', - options?: { model?: 'lowpoly', primitive?: 'sphere' | 'box' } - ): XRHandModel; - -} diff --git a/package-lock.json b/package-lock.json index 49371b0622cddb..3e886b17fd49ec 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "three", - "version": "0.125.1", + "version": "0.125.2", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -1464,32 +1464,6 @@ } } }, - "@nodelib/fs.scandir": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.4.tgz", - "integrity": "sha512-33g3pMJk3bg5nXbL/+CY6I2eJDzZAni49PfJnL5fghPTggPvBd/pFNSgJsdAgWptuFu7qq/ERvOYFlhvsLTCKA==", - "dev": true, - "requires": { - "@nodelib/fs.stat": "2.0.4", - "run-parallel": "^1.1.9" - } - }, - "@nodelib/fs.stat": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.4.tgz", - "integrity": "sha512-IYlHJA0clt2+Vg7bccq+TzRdJvv19c2INqBSsoOLp1je7xjtr7J26+WXR72MCdvU9q1qTzIWDfhMf+DRvQJK4Q==", - "dev": true - }, - "@nodelib/fs.walk": { - "version": "1.2.6", - "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.6.tgz", - "integrity": "sha512-8Broas6vTtW4GIXTAHDoE32hnN2M5ykgCpWGbuXHQ15vEMqr23pB76e/GZcYsZCHALv50ktd24qhEyKr6wBtow==", - "dev": true, - "requires": { - "@nodelib/fs.scandir": "2.1.4", - "fastq": "^1.6.0" - } - }, "@rollup/plugin-babel": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/@rollup/plugin-babel/-/plugin-babel-5.2.2.tgz", @@ -1543,12 +1517,6 @@ "integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==", "dev": true }, - "@types/json-schema": { - "version": "7.0.7", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.7.tgz", - "integrity": "sha512-cxWFQVseBm6O9Gbw1IWb8r6OS4OhSt3hPZLkFApLjM8TEXROBuQGLAH2i2gZpcXdLBIrpXuTDhH7Vbm1iXmNGA==", - "dev": true - }, "@types/node": { "version": "14.10.1", "resolved": "https://registry.npmjs.org/@types/node/-/node-14.10.1.tgz", @@ -1564,112 +1532,6 @@ "@types/node": "*" } }, - "@typescript-eslint/eslint-plugin": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-4.14.1.tgz", - "integrity": "sha512-5JriGbYhtqMS1kRcZTQxndz1lKMwwEXKbwZbkUZNnp6MJX0+OVXnG0kOlBZP4LUAxEyzu3cs+EXd/97MJXsGfw==", - "dev": true, - "requires": { - "@typescript-eslint/experimental-utils": "4.14.1", - "@typescript-eslint/scope-manager": "4.14.1", - "debug": "^4.1.1", - "functional-red-black-tree": "^1.0.1", - "lodash": "^4.17.15", - "regexpp": "^3.0.0", - "semver": "^7.3.2", - "tsutils": "^3.17.1" - }, - "dependencies": { - "semver": { - "version": "7.3.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.4.tgz", - "integrity": "sha512-tCfb2WLjqFAtXn4KEdxIhalnRtoKFN7nAwj0B3ZXCbQloV2tq5eDbcTmT68JJD3nRJq24/XgxtQKFIpQdtvmVw==", - "dev": true, - "requires": { - "lru-cache": "^6.0.0" - } - } - } - }, - "@typescript-eslint/experimental-utils": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.14.1.tgz", - "integrity": "sha512-2CuHWOJwvpw0LofbyG5gvYjEyoJeSvVH2PnfUQSn0KQr4v8Dql2pr43ohmx4fdPQ/eVoTSFjTi/bsGEXl/zUUQ==", - "dev": true, - "requires": { - "@types/json-schema": "^7.0.3", - "@typescript-eslint/scope-manager": "4.14.1", - "@typescript-eslint/types": "4.14.1", - "@typescript-eslint/typescript-estree": "4.14.1", - "eslint-scope": "^5.0.0", - "eslint-utils": "^2.0.0" - } - }, - "@typescript-eslint/parser": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.14.1.tgz", - "integrity": "sha512-mL3+gU18g9JPsHZuKMZ8Z0Ss9YP1S5xYZ7n68Z98GnPq02pYNQuRXL85b9GYhl6jpdvUc45Km7hAl71vybjUmw==", - "dev": true, - "requires": { - "@typescript-eslint/scope-manager": "4.14.1", - "@typescript-eslint/types": "4.14.1", - "@typescript-eslint/typescript-estree": "4.14.1", - "debug": "^4.1.1" - } - }, - "@typescript-eslint/scope-manager": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.14.1.tgz", - "integrity": "sha512-F4bjJcSqXqHnC9JGUlnqSa3fC2YH5zTtmACS1Hk+WX/nFB0guuynVK5ev35D4XZbdKjulXBAQMyRr216kmxghw==", - "dev": true, - "requires": { - "@typescript-eslint/types": "4.14.1", - "@typescript-eslint/visitor-keys": "4.14.1" - } - }, - "@typescript-eslint/types": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.14.1.tgz", - "integrity": "sha512-SkhzHdI/AllAgQSxXM89XwS1Tkic7csPdndUuTKabEwRcEfR8uQ/iPA3Dgio1rqsV3jtqZhY0QQni8rLswJM2w==", - "dev": true - }, - "@typescript-eslint/typescript-estree": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.14.1.tgz", - "integrity": "sha512-M8+7MbzKC1PvJIA8kR2sSBnex8bsR5auatLCnVlNTJczmJgqRn8M+sAlQfkEq7M4IY3WmaNJ+LJjPVRrREVSHQ==", - "dev": true, - "requires": { - "@typescript-eslint/types": "4.14.1", - "@typescript-eslint/visitor-keys": "4.14.1", - "debug": "^4.1.1", - "globby": "^11.0.1", - "is-glob": "^4.0.1", - "lodash": "^4.17.15", - "semver": "^7.3.2", - "tsutils": "^3.17.1" - }, - "dependencies": { - "semver": { - "version": "7.3.4", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.4.tgz", - "integrity": "sha512-tCfb2WLjqFAtXn4KEdxIhalnRtoKFN7nAwj0B3ZXCbQloV2tq5eDbcTmT68JJD3nRJq24/XgxtQKFIpQdtvmVw==", - "dev": true, - "requires": { - "lru-cache": "^6.0.0" - } - } - } - }, - "@typescript-eslint/visitor-keys": { - "version": "4.14.1", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.14.1.tgz", - "integrity": "sha512-TAblbDXOI7bd0C/9PE1G+AFo7R5uc+ty1ArDoxmrC1ah61Hn6shURKy7gLdRb1qKJmjHkqu5Oq+e4Kt0jwf1IA==", - "dev": true, - "requires": { - "@typescript-eslint/types": "4.14.1", - "eslint-visitor-keys": "^2.0.0" - } - }, "accepts": { "version": "1.3.7", "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", @@ -1740,12 +1602,6 @@ "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=", "dev": true }, - "array-union": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", - "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", - "dev": true - }, "astral-regex": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", @@ -1835,15 +1691,6 @@ "concat-map": "0.0.1" } }, - "braces": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", - "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", - "dev": true, - "requires": { - "fill-range": "^7.0.1" - } - }, "browserslist": { "version": "4.16.0", "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.16.0.tgz", @@ -2137,15 +1984,6 @@ "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=", "dev": true }, - "dir-glob": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", - "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", - "dev": true, - "requires": { - "path-type": "^4.0.0" - } - }, "doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", @@ -2591,20 +2429,6 @@ "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", "dev": true }, - "fast-glob": { - "version": "3.2.5", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.5.tgz", - "integrity": "sha512-2DtFcgT68wiTTiwZ2hNdJfcHNke9XOfnwmBRWXhmeKM8rF0TGwmC/Qto3S7RoZKp5cilZbxzO5iTNTQsJ+EeDg==", - "dev": true, - "requires": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.0", - "merge2": "^1.3.0", - "micromatch": "^4.0.2", - "picomatch": "^2.2.1" - } - }, "fast-json-stable-stringify": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", @@ -2617,15 +2441,6 @@ "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=", "dev": true }, - "fastq": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.10.0.tgz", - "integrity": "sha512-NL2Qc5L3iQEsyYzweq7qfgy5OtXCmGzGvhElGEd/SoFWEMOEczNh5s5ocaF01HDetxz+p8ecjNPA6cZxxIHmzA==", - "dev": true, - "requires": { - "reusify": "^1.0.4" - } - }, "file-entry-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.0.tgz", @@ -2635,15 +2450,6 @@ "flat-cache": "^3.0.4" } }, - "fill-range": { - "version": "7.0.1", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", - "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", - "dev": true, - "requires": { - "to-regex-range": "^5.0.1" - } - }, "finalhandler": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", @@ -2790,20 +2596,6 @@ "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", "dev": true }, - "globby": { - "version": "11.0.2", - "resolved": "https://registry.npmjs.org/globby/-/globby-11.0.2.tgz", - "integrity": "sha512-2ZThXDvvV8fYFRVIxnrMQBipZQDr7MxKAmQK1vujaj9/7eF0efG7BPUKJ7jP7G5SLF37xKDXvO4S/KKLj/Z0og==", - "dev": true, - "requires": { - "array-union": "^2.1.0", - "dir-glob": "^3.0.1", - "fast-glob": "^3.1.1", - "ignore": "^5.1.4", - "merge2": "^1.3.0", - "slash": "^3.0.0" - } - }, "has": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", @@ -2873,12 +2665,6 @@ "safer-buffer": ">= 2.1.2 < 3" } }, - "ignore": { - "version": "5.1.8", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.1.8.tgz", - "integrity": "sha512-BMpfD7PpiETpBl/A6S498BaIJ6Y/ABT93ETbby2fP00v4EbvPBXWEoaR1UBPKs3iR53pJY7EtZk5KACI57i1Uw==", - "dev": true - }, "import-fresh": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", @@ -2959,12 +2745,6 @@ "integrity": "sha1-Mlj7afeMFNW4FdZkM2tM/7ZEFZE=", "dev": true }, - "is-number": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", - "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", - "dev": true - }, "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", @@ -3101,28 +2881,12 @@ "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", "dev": true }, - "merge2": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", - "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", - "dev": true - }, "methods": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=", "dev": true }, - "micromatch": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.2.tgz", - "integrity": "sha512-y7FpHSbMUMoyPbYUSzO6PaZ6FyRnQOpHuKwbo1G+Knck95XVU4QAiKdGEnj5wwoS7PlOgthX/09u5iFJ+aYf5Q==", - "dev": true, - "requires": { - "braces": "^3.0.1", - "picomatch": "^2.0.5" - } - }, "mime": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", @@ -3336,12 +3100,6 @@ "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=", "dev": true }, - "path-type": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", - "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", - "dev": true - }, "picomatch": { "version": "2.2.2", "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz", @@ -3532,12 +3290,6 @@ "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", "dev": true }, - "reusify": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", - "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", - "dev": true - }, "rimraf": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", @@ -3568,12 +3320,6 @@ "terser": "^5.0.0" } }, - "run-parallel": { - "version": "1.1.10", - "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.1.10.tgz", - "integrity": "sha512-zb/1OuZ6flOlH6tQyMPUrE3x3Ulxjlo9WIVXR4yVYi4H9UXQaeIsPbLn2R3O3vQCnDKkAl2qHiuocKKX4Tz/Sw==", - "dev": true - }, "rxjs": { "version": "6.6.3", "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.6.3.tgz", @@ -3841,12 +3587,6 @@ "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", "dev": true }, - "slash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", - "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", - "dev": true - }, "slice-ansi": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", @@ -4084,15 +3824,6 @@ "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", "dev": true }, - "to-regex-range": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", - "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", - "dev": true, - "requires": { - "is-number": "^7.0.0" - } - }, "toidentifier": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", @@ -4111,15 +3842,6 @@ "integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==", "dev": true }, - "tsutils": { - "version": "3.20.0", - "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-3.20.0.tgz", - "integrity": "sha512-RYbuQuvkhuqVeXweWT3tJLKOEJ/UUw9GjNEZGWdrLLlM+611o1gwLHBpxoFJKKl25fLprp2eVthtKs5JOrNeXg==", - "dev": true, - "requires": { - "tslib": "^1.8.1" - } - }, "type-check": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", @@ -4145,12 +3867,6 @@ "mime-types": "~2.1.24" } }, - "typescript": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.1.3.tgz", - "integrity": "sha512-B3ZIOf1IKeH2ixgHhj6la6xdwR9QrLC5d1VKeCSY4tvkqhF2eqd9O7txNlS0PO3GrBAFIdr3L1ndNwteUbZLYg==", - "dev": true - }, "unicode-canonical-property-names-ecmascript": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz", diff --git a/package.json b/package.json index c79dc6da248878..3dfb60b94deed1 100644 --- a/package.json +++ b/package.json @@ -4,7 +4,6 @@ "description": "JavaScript 3D library", "main": "build/three.js", "module": "build/three.module.js", - "types": "src/Three.d.ts", "repository": { "type": "git", "url": "https://github.com/mrdoob/three.js" @@ -28,23 +27,11 @@ }, "eslintConfig": { "root": true, - "parser": "@typescript-eslint/parser", "extends": "mdcs", "plugins": [ - "html", - "@typescript-eslint" + "html" ], "rules": { - "@typescript-eslint/no-unused-vars": [ - "error" - ], - "@typescript-eslint/indent": [ - "error", - "tab", - { - "SwitchCase": 1 - } - ], "quotes": [ "error", "single" @@ -63,10 +50,10 @@ "test": "npm run test-lint && npm run test-unit", "build": "rollup -c utils/build/rollup.config.js", "dev": "concurrently --names \"ROLLUP,HTTP\" -c \"bgBlue.bold,bgGreen.bold\" \"rollup -c utils/build/rollup.config.js -w -m inline\" \"servez -p 8080\"", - "lint-fix": "eslint src --ext js --ext ts --fix && eslint examples/js examples/jsm --ext js --ext ts --ignore-pattern libs --fix", + "lint-fix": "eslint src --ext js --fix && eslint examples/js examples/jsm --ext js --ignore-pattern libs --fix", "lint-docs": "eslint docs --ext html", - "lint-examples": "eslint examples/js examples/jsm --ext js --ext ts --ignore-pattern libs && tsc -p utils/build/tsconfig-examples.lint.json", - "test-lint": "eslint src --ext js --ext ts && tsc -p utils/build/tsconfig.lint.json", + "lint-examples": "eslint examples/js examples/jsm --ext js --ignore-pattern libs", + "test-lint": "eslint src --ext js", "test-unit": "npm run unit --prefix test", "test-unit-examples": "npm run unit-examples --prefix test", "test-e2e": "node test/e2e/puppeteer.js", @@ -100,8 +87,6 @@ "@babel/preset-env": "^7.12.11", "@rollup/plugin-babel": "^5.2.2", "@rollup/plugin-node-resolve": "^11.1.0", - "@typescript-eslint/eslint-plugin": "^4.14.1", - "@typescript-eslint/parser": "^4.14.1", "concurrently": "^5.3.0", "eslint": "^7.18.0", "eslint-config-mdcs": "^5.0.0", @@ -109,8 +94,7 @@ "regenerator-runtime": "^0.13.7", "rollup": "^2.38.0", "rollup-plugin-terser": "^7.0.2", - "servez": "^1.11.0", - "typescript": "^4.1.3" + "servez": "^1.11.0" }, "jspm": { "files": [ diff --git a/src/Three.Legacy.d.ts b/src/Three.Legacy.d.ts deleted file mode 100644 index cb0ff5c3b541f6..00000000000000 --- a/src/Three.Legacy.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/src/Three.d.ts b/src/Three.d.ts deleted file mode 100644 index 762d911e274498..00000000000000 --- a/src/Three.d.ts +++ /dev/null @@ -1,180 +0,0 @@ -export * from './polyfills'; -export * from './renderers/WebGLMultisampleRenderTarget'; -export * from './renderers/WebGLCubeRenderTarget'; -export * from './renderers/WebGLRenderTarget'; -export * from './renderers/WebGLRenderer'; -export * from './renderers/WebGL1Renderer'; -export * from './renderers/shaders/ShaderLib'; -export * from './renderers/shaders/UniformsLib'; -export * from './renderers/shaders/UniformsUtils'; -export * from './renderers/shaders/ShaderChunk'; -export * from './scenes/FogExp2'; -export * from './scenes/Fog'; -export * from './scenes/Scene'; -export * from './objects/Sprite'; -export * from './objects/LOD'; -export * from './objects/InstancedMesh'; -export * from './objects/SkinnedMesh'; -export * from './objects/Skeleton'; -export * from './objects/Bone'; -export * from './objects/Mesh'; -export * from './objects/LineSegments'; -export * from './objects/LineLoop'; -export * from './objects/Line'; -export * from './objects/Points'; -export * from './objects/Group'; -export * from './textures/VideoTexture'; -export * from './textures/DataTexture'; -export * from './textures/DataTexture2DArray'; -export * from './textures/DataTexture3D'; -export * from './textures/CompressedTexture'; -export * from './textures/CubeTexture'; -export * from './textures/CanvasTexture'; -export * from './textures/DepthTexture'; -export * from './textures/Texture'; -export * from './geometries/Geometries'; -export * from './materials/Materials'; -export * from './loaders/AnimationLoader'; -export * from './loaders/CompressedTextureLoader'; -export * from './loaders/DataTextureLoader'; -export * from './loaders/CubeTextureLoader'; -export * from './loaders/TextureLoader'; -export * from './loaders/ObjectLoader'; -export * from './loaders/MaterialLoader'; -export * from './loaders/BufferGeometryLoader'; -export * from './loaders/LoadingManager'; -export * from './loaders/ImageLoader'; -export * from './loaders/ImageBitmapLoader'; -export * from './loaders/FontLoader'; -export * from './loaders/FileLoader'; -export * from './loaders/Loader'; -export * from './loaders/LoaderUtils'; -export * from './loaders/Cache'; -export * from './loaders/AudioLoader'; -export * from './lights/SpotLightShadow'; -export * from './lights/SpotLight'; -export * from './lights/PointLight'; -export * from './lights/PointLightShadow'; -export * from './lights/RectAreaLight'; -export * from './lights/HemisphereLight'; -export * from './lights/DirectionalLightShadow'; -export * from './lights/DirectionalLight'; -export * from './lights/AmbientLight'; -export * from './lights/LightShadow'; -export * from './lights/Light'; -export * from './lights/AmbientLightProbe'; -export * from './lights/HemisphereLightProbe'; -export * from './lights/LightProbe'; -export * from './cameras/StereoCamera'; -export * from './cameras/PerspectiveCamera'; -export * from './cameras/OrthographicCamera'; -export * from './cameras/CubeCamera'; -export * from './cameras/ArrayCamera'; -export * from './cameras/Camera'; -export * from './audio/AudioListener'; -export * from './audio/PositionalAudio'; -export * from './audio/AudioContext'; -export * from './audio/AudioAnalyser'; -export * from './audio/Audio'; -export * from './animation/tracks/VectorKeyframeTrack'; -export * from './animation/tracks/StringKeyframeTrack'; -export * from './animation/tracks/QuaternionKeyframeTrack'; -export * from './animation/tracks/NumberKeyframeTrack'; -export * from './animation/tracks/ColorKeyframeTrack'; -export * from './animation/tracks/BooleanKeyframeTrack'; -export * from './animation/PropertyMixer'; -export * from './animation/PropertyBinding'; -export * from './animation/KeyframeTrack'; -export * from './animation/AnimationUtils'; -export * from './animation/AnimationObjectGroup'; -export * from './animation/AnimationMixer'; -export * from './animation/AnimationClip'; -export * from './animation/AnimationAction'; -export * from './core/Uniform'; -export * from './core/InstancedBufferGeometry'; -export * from './core/BufferGeometry'; -export * from './core/InterleavedBufferAttribute'; -export * from './core/InstancedInterleavedBuffer'; -export * from './core/InterleavedBuffer'; -export * from './core/InstancedBufferAttribute'; -export * from './core/BufferAttribute'; -export * from './core/Object3D'; -export * from './core/Raycaster'; -export * from './core/Layers'; -export * from './core/EventDispatcher'; -export * from './core/Clock'; -export * from './math/interpolants/QuaternionLinearInterpolant'; -export * from './math/interpolants/LinearInterpolant'; -export * from './math/interpolants/DiscreteInterpolant'; -export * from './math/interpolants/CubicInterpolant'; -export * from './math/Interpolant'; -export * from './math/Triangle'; -export * from './math/MathUtils'; -export * from './math/Spherical'; -export * from './math/Cylindrical'; -export * from './math/Plane'; -export * from './math/Frustum'; -export * from './math/Sphere'; -export * from './math/Ray'; -export * from './math/Matrix4'; -export * from './math/Matrix3'; -export * from './math/Box3'; -export * from './math/Box2'; -export * from './math/Line3'; -export * from './math/Euler'; -export * from './math/Vector4'; -export * from './math/Vector3'; -export * from './math/Vector2'; -export * from './math/Quaternion'; -export * from './math/Color'; -export * from './math/SphericalHarmonics3'; -export * from './extras/objects/ImmediateRenderObject'; -export * from './helpers/SpotLightHelper'; -export * from './helpers/SkeletonHelper'; -export * from './helpers/PointLightHelper'; -export * from './helpers/HemisphereLightHelper'; -export * from './helpers/GridHelper'; -export * from './helpers/PolarGridHelper'; -export * from './helpers/DirectionalLightHelper'; -export * from './helpers/CameraHelper'; -export * from './helpers/BoxHelper'; -export * from './helpers/Box3Helper'; -export * from './helpers/PlaneHelper'; -export * from './helpers/ArrowHelper'; -export * from './helpers/AxesHelper'; -export * from './extras/curves/Curves'; -export * from './extras/core/Shape'; -export * from './extras/core/Path'; -export * from './extras/core/ShapePath'; -export * from './extras/core/Font'; -export * from './extras/core/CurvePath'; -export * from './extras/core/Curve'; -export * from './extras/DataUtils'; -export * from './extras/ImageUtils'; -export * from './extras/ShapeUtils'; -export * from './extras/PMREMGenerator'; -export * from './renderers/webgl/WebGLBufferRenderer'; -export * from './renderers/webgl/WebGLCapabilities'; -export * from './renderers/webgl/WebGLClipping'; -export * from './renderers/webgl/WebGLExtensions'; -export * from './renderers/webgl/WebGLGeometries'; -export * from './renderers/webgl/WebGLIndexedBufferRenderer'; -export * from './renderers/webgl/WebGLInfo'; -export * from './renderers/webgl/WebGLLights'; -export * from './renderers/webgl/WebGLObjects'; -export * from './renderers/webgl/WebGLProgram'; -export * from './renderers/webgl/WebGLPrograms'; -export * from './renderers/webgl/WebGLProperties'; -export * from './renderers/webgl/WebGLRenderLists'; -export * from './renderers/webgl/WebGLShader'; -export * from './renderers/webgl/WebGLShadowMap'; -export * from './renderers/webgl/WebGLState'; -export * from './renderers/webgl/WebGLTextures'; -export * from './renderers/webgl/WebGLUniforms'; -export * from './renderers/webxr/WebXR'; -export * from './renderers/webxr/WebXRController'; -export * from './renderers/webxr/WebXRManager'; -export * from './constants'; -export * from './Three.Legacy'; - -export as namespace THREE; diff --git a/src/animation/AnimationAction.d.ts b/src/animation/AnimationAction.d.ts deleted file mode 100644 index 5593e4fb560cc0..00000000000000 --- a/src/animation/AnimationAction.d.ts +++ /dev/null @@ -1,103 +0,0 @@ -import { AnimationMixer } from './AnimationMixer'; -import { AnimationClip } from './AnimationClip'; -import { AnimationActionLoopStyles, AnimationBlendMode } from '../constants'; -import { Object3D } from '../core/Object3D'; -// Animation //////////////////////////////////////////////////////////////////////////////////////// - -export class AnimationAction { - - constructor( mixer: AnimationMixer, clip: AnimationClip, localRoot?: Object3D, blendMode?: AnimationBlendMode ); - - blendMode: AnimationBlendMode; - - /** - * @default THREE.LoopRepeat - */ - loop: AnimationActionLoopStyles; - - /** - * @default 0 - */ - time: number; - - /** - * @default 1 - */ - timeScale: number; - - /** - * @default 1 - */ - weight: number; - - /** - * @default Infinity - */ - repetitions: number; - - /** - * @default false - */ - paused: boolean; - - /** - * @default true - */ - enabled: boolean; - - /** - * @default false - */ - clampWhenFinished: boolean; - - /** - * @default true - */ - zeroSlopeAtStart: boolean; - - /** - * @default true - */ - zeroSlopeAtEnd: boolean; - - play(): AnimationAction; - stop(): AnimationAction; - reset(): AnimationAction; - isRunning(): boolean; - isScheduled(): boolean; - startAt( time: number ): AnimationAction; - setLoop( - mode: AnimationActionLoopStyles, - repetitions: number - ): AnimationAction; - setEffectiveWeight( weight: number ): AnimationAction; - getEffectiveWeight(): number; - fadeIn( duration: number ): AnimationAction; - fadeOut( duration: number ): AnimationAction; - crossFadeFrom( - fadeOutAction: AnimationAction, - duration: number, - warp: boolean - ): AnimationAction; - crossFadeTo( - fadeInAction: AnimationAction, - duration: number, - warp: boolean - ): AnimationAction; - stopFading(): AnimationAction; - setEffectiveTimeScale( timeScale: number ): AnimationAction; - getEffectiveTimeScale(): number; - setDuration( duration: number ): AnimationAction; - syncWith( action: AnimationAction ): AnimationAction; - halt( duration: number ): AnimationAction; - warp( - statTimeScale: number, - endTimeScale: number, - duration: number - ): AnimationAction; - stopWarping(): AnimationAction; - getMixer(): AnimationMixer; - getClip(): AnimationClip; - getRoot(): Object3D; - -} diff --git a/src/animation/AnimationClip.d.ts b/src/animation/AnimationClip.d.ts deleted file mode 100644 index 13344c23dd6edc..00000000000000 --- a/src/animation/AnimationClip.d.ts +++ /dev/null @@ -1,56 +0,0 @@ -import { KeyframeTrack } from './KeyframeTrack'; -import { Vector3 } from './../math/Vector3'; -import { Bone } from './../objects/Bone'; -import { AnimationBlendMode } from '../constants'; - -interface MorphTarget { - name: string; - vertices: Vector3[]; -} - -export class AnimationClip { - - constructor( name?: string, duration?: number, tracks?: KeyframeTrack[], blendMode?: AnimationBlendMode ); - - name: string; - tracks: KeyframeTrack[]; - - /** - * @default THREE.NormalAnimationBlendMode - */ - blendMode: AnimationBlendMode; - - /** - * @default -1 - */ - duration: number; - uuid: string; - results: any[]; - - resetDuration(): AnimationClip; - trim(): AnimationClip; - validate(): boolean; - optimize(): AnimationClip; - clone(): AnimationClip; - toJSON( clip: AnimationClip ): any; - - static CreateFromMorphTargetSequence( - name: string, - morphTargetSequence: MorphTarget[], - fps: number, - noLoop: boolean - ): AnimationClip; - static findByName( clipArray: AnimationClip[], name: string ): AnimationClip; - static CreateClipsFromMorphTargetSequences( - morphTargets: MorphTarget[], - fps: number, - noLoop: boolean - ): AnimationClip[]; - static parse( json: any ): AnimationClip; - static parseAnimation( - animation: any, - bones: Bone[] - ): AnimationClip; - static toJSON( clip: AnimationClip ): any; - -} diff --git a/src/animation/AnimationMixer.d.ts b/src/animation/AnimationMixer.d.ts deleted file mode 100644 index 76537850d6626e..00000000000000 --- a/src/animation/AnimationMixer.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { AnimationClip } from './AnimationClip'; -import { AnimationAction } from './AnimationAction'; -import { AnimationBlendMode } from '../constants'; -import { EventDispatcher } from './../core/EventDispatcher'; -import { Object3D } from '../core/Object3D'; -import { AnimationObjectGroup } from './AnimationObjectGroup'; - -export class AnimationMixer extends EventDispatcher { - - constructor( root: Object3D | AnimationObjectGroup ); - - /** - * @default 0 - */ - time: number; - - /** - * @default 1.0 - */ - timeScale: number; - - clipAction( clip: AnimationClip, root?: Object3D | AnimationObjectGroup, blendMode?: AnimationBlendMode ): AnimationAction; - existingAction( clip: AnimationClip, root?: Object3D | AnimationObjectGroup ): AnimationAction | null; - stopAllAction(): AnimationMixer; - update( deltaTime: number ): AnimationMixer; - setTime( timeInSeconds: number ): AnimationMixer; - getRoot(): Object3D | AnimationObjectGroup; - uncacheClip( clip: AnimationClip ): void; - uncacheRoot( root: Object3D | AnimationObjectGroup ): void; - uncacheAction( clip: AnimationClip, root?: Object3D | AnimationObjectGroup ): void; - -} diff --git a/src/animation/AnimationObjectGroup.d.ts b/src/animation/AnimationObjectGroup.d.ts deleted file mode 100644 index 6d5f99e496c9dc..00000000000000 --- a/src/animation/AnimationObjectGroup.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -export class AnimationObjectGroup { - - constructor( ...args: any[] ); - - uuid: string; - stats: { - bindingsPerObject: number; - objects: { - total: number; - inUse: number; - }; - }; - readonly isAnimationObjectGroup: true; - - add( ...args: any[] ): void; - remove( ...args: any[] ): void; - uncache( ...args: any[] ): void; - -} diff --git a/src/animation/AnimationUtils.d.ts b/src/animation/AnimationUtils.d.ts deleted file mode 100644 index 715ddd3ebe3392..00000000000000 --- a/src/animation/AnimationUtils.d.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { AnimationClip } from './AnimationClip'; - -export namespace AnimationUtils { - export function arraySlice( array: any, from: number, to: number ): any; - export function convertArray( array: any, type: any, forceClone: boolean ): any; - export function isTypedArray( object: any ): boolean; - export function getKeyFrameOrder( times: number[] ): number[]; - export function sortedArray( - values: any[], - stride: number, - order: number[] - ): any[]; - export function flattenJSON( - jsonKeys: string[], - times: any[], - values: any[], - valuePropertyName: string - ): void; - - /** - * @param sourceClip - * @param name - * @param startFrame - * @param endFrame - * @param [fps=30] - */ - export function subclip( - sourceClip: AnimationClip, - name: string, - startFrame: number, - endFrame: number, - fps?: number - ): AnimationClip; - - /** - * @param targetClip - * @param [referenceFrame=0] - * @param [referenceClip=targetClip] - * @param [fps=30] - */ - export function makeClipAdditive( - targetClip: AnimationClip, - referenceFrame?: number, - referenceClip?: AnimationClip, - fps?: number - ): AnimationClip; -} diff --git a/src/animation/KeyframeTrack.d.ts b/src/animation/KeyframeTrack.d.ts deleted file mode 100644 index 94db121117a9f8..00000000000000 --- a/src/animation/KeyframeTrack.d.ts +++ /dev/null @@ -1,52 +0,0 @@ -import { DiscreteInterpolant } from './../math/interpolants/DiscreteInterpolant'; -import { LinearInterpolant } from './../math/interpolants/LinearInterpolant'; -import { CubicInterpolant } from './../math/interpolants/CubicInterpolant'; -import { InterpolationModes } from '../constants'; - -export class KeyframeTrack { - - /** - * @param name - * @param times - * @param values - * @param [interpolation=THREE.InterpolateLinear] - */ - constructor( - name: string, - times: ArrayLike, - values: ArrayLike, - interpolation?: InterpolationModes - ); - - name: string; - times: Float32Array; - values: Float32Array; - - ValueTypeName: string; - TimeBufferType: Float32Array; - ValueBufferType: Float32Array; - - /** - * @default THREE.InterpolateLinear - */ - DefaultInterpolation: InterpolationModes; - - InterpolantFactoryMethodDiscrete( result: any ): DiscreteInterpolant; - InterpolantFactoryMethodLinear( result: any ): LinearInterpolant; - InterpolantFactoryMethodSmooth( result: any ): CubicInterpolant; - - setInterpolation( interpolation: InterpolationModes ): KeyframeTrack; - getInterpolation(): InterpolationModes; - - getValueSize(): number; - - shift( timeOffset: number ): KeyframeTrack; - scale( timeScale: number ): KeyframeTrack; - trim( startTime: number, endTime: number ): KeyframeTrack; - validate(): boolean; - optimize(): KeyframeTrack; - clone(): KeyframeTrack; - - static toJSON( track: KeyframeTrack ): any; - -} diff --git a/src/animation/PropertyBinding.d.ts b/src/animation/PropertyBinding.d.ts deleted file mode 100644 index 4c4995e28de478..00000000000000 --- a/src/animation/PropertyBinding.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -export interface ParseTrackNameResults { - nodeName: string; - objectName: string; - objectIndex: string; - propertyName: string; - propertyIndex: string; -} - -export class PropertyBinding { - - constructor( rootNode: any, path: string, parsedPath?: any ); - - path: string; - parsedPath: any; - node: any; - rootNode: any; - - getValue( targetArray: any, offset: number ): any; - setValue( sourceArray: any, offset: number ): void; - bind(): void; - unbind(): void; - - BindingType: { [bindingType: string]: number }; - Versioning: { [versioning: string]: number }; - - GetterByBindingType: Function[]; - SetterByBindingTypeAndVersioning: Array; - - static create( - root: any, - path: any, - parsedPath?: any - ): PropertyBinding | PropertyBinding.Composite; - static sanitizeNodeName( name: string ): string; - static parseTrackName( trackName: string ): ParseTrackNameResults; - static findNode( root: any, nodeName: string ): any; - -} - -export namespace PropertyBinding { - export class Composite { - - constructor( targetGroup: any, path: any, parsedPath?: any ); - - getValue( array: any, offset: number ): any; - setValue( array: any, offset: number ): void; - bind(): void; - unbind(): void; - - } -} diff --git a/src/animation/PropertyMixer.d.ts b/src/animation/PropertyMixer.d.ts deleted file mode 100644 index 0d51f43580a117..00000000000000 --- a/src/animation/PropertyMixer.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -export class PropertyMixer { - - constructor( binding: any, typeName: string, valueSize: number ); - - binding: any; - valueSize: number; - buffer: any; - cumulativeWeight: number; - cumulativeWeightAdditive: number; - useCount: number; - referenceCount: number; - - accumulate( accuIndex: number, weight: number ): void; - accumulateAdditive( weight: number ): void; - apply( accuIndex: number ): void; - saveOriginalState(): void; - restoreOriginalState(): void; - -} diff --git a/src/animation/tracks/BooleanKeyframeTrack.d.ts b/src/animation/tracks/BooleanKeyframeTrack.d.ts deleted file mode 100644 index c4f91066d4b63c..00000000000000 --- a/src/animation/tracks/BooleanKeyframeTrack.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { KeyframeTrack } from './../KeyframeTrack'; - -export class BooleanKeyframeTrack extends KeyframeTrack { - - constructor( name: string, times: any[], values: any[] ); - - /** - * @default 'bool' - */ - ValueTypeName: string; - -} diff --git a/src/animation/tracks/ColorKeyframeTrack.d.ts b/src/animation/tracks/ColorKeyframeTrack.d.ts deleted file mode 100644 index 69383fba012d0c..00000000000000 --- a/src/animation/tracks/ColorKeyframeTrack.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { KeyframeTrack } from './../KeyframeTrack'; -import { InterpolationModes } from '../../constants'; - -export class ColorKeyframeTrack extends KeyframeTrack { - - constructor( - name: string, - times: any[], - values: any[], - interpolation?: InterpolationModes - ); - - /** - * @default 'color' - */ - ValueTypeName: string; - -} diff --git a/src/animation/tracks/NumberKeyframeTrack.d.ts b/src/animation/tracks/NumberKeyframeTrack.d.ts deleted file mode 100644 index 27d641ba3f6349..00000000000000 --- a/src/animation/tracks/NumberKeyframeTrack.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { KeyframeTrack } from './../KeyframeTrack'; -import { InterpolationModes } from '../../constants'; - -export class NumberKeyframeTrack extends KeyframeTrack { - - constructor( - name: string, - times: any[], - values: any[], - interpolation?: InterpolationModes - ); - - /** - * @default 'number' - */ - ValueTypeName: string; - -} diff --git a/src/animation/tracks/QuaternionKeyframeTrack.d.ts b/src/animation/tracks/QuaternionKeyframeTrack.d.ts deleted file mode 100644 index 6a1c99bfbb5747..00000000000000 --- a/src/animation/tracks/QuaternionKeyframeTrack.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { KeyframeTrack } from './../KeyframeTrack'; -import { InterpolationModes } from '../../constants'; - -export class QuaternionKeyframeTrack extends KeyframeTrack { - - constructor( - name: string, - times: any[], - values: any[], - interpolation?: InterpolationModes - ); - - /** - * @default 'quaternion' - */ - ValueTypeName: string; - -} diff --git a/src/animation/tracks/StringKeyframeTrack.d.ts b/src/animation/tracks/StringKeyframeTrack.d.ts deleted file mode 100644 index 1d527032c268b2..00000000000000 --- a/src/animation/tracks/StringKeyframeTrack.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { KeyframeTrack } from './../KeyframeTrack'; -import { InterpolationModes } from '../../constants'; - -export class StringKeyframeTrack extends KeyframeTrack { - - constructor( - name: string, - times: any[], - values: any[], - interpolation?: InterpolationModes - ); - - /** - * @default 'string' - */ - ValueTypeName: string; - -} diff --git a/src/animation/tracks/VectorKeyframeTrack.d.ts b/src/animation/tracks/VectorKeyframeTrack.d.ts deleted file mode 100644 index 6fd96550826cec..00000000000000 --- a/src/animation/tracks/VectorKeyframeTrack.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { KeyframeTrack } from './../KeyframeTrack'; -import { InterpolationModes } from '../../constants'; - -export class VectorKeyframeTrack extends KeyframeTrack { - - constructor( - name: string, - times: any[], - values: any[], - interpolation?: InterpolationModes - ); - - /** - * @default 'vector' - */ - ValueTypeName: string; - -} diff --git a/src/audio/Audio.d.ts b/src/audio/Audio.d.ts deleted file mode 100644 index 52fde6bb7b5613..00000000000000 --- a/src/audio/Audio.d.ts +++ /dev/null @@ -1,108 +0,0 @@ -import { Object3D } from './../core/Object3D'; -import { AudioListener } from './AudioListener'; -import { AudioContext } from './AudioContext'; - -// Extras / Audio ///////////////////////////////////////////////////////////////////// - -export class Audio extends Object3D { - - constructor( listener: AudioListener ); - type: 'Audio'; - - listener: AudioListener; - context: AudioContext; - gain: GainNode; - - /** - * @default false - */ - autoplay: boolean; - buffer: null | AudioBuffer; - - /** - * @default 0 - */ - detune: number; - - /** - * @default false - */ - loop: boolean; - - /** - * @default 0 - */ - loopStart: number; - - /** - * @default 0 - */ - loopEnd: number; - - /** - * @default 0 - */ - offset: number; - - /** - * @default undefined - */ - duration: number | undefined; - - /** - * @default 1 - */ - playbackRate: number; - - /** - * @default false - */ - isPlaying: boolean; - - /** - * @default true - */ - hasPlaybackControl: boolean; - - /** - * @default 'empty' - */ - sourceType: string; - source: null | AudioBufferSourceNode; - - /** - * @default [] - */ - filters: any[]; - - getOutput(): NodeType; - setNodeSource( audioNode: AudioBufferSourceNode ): this; - setMediaElementSource( mediaElement: HTMLMediaElement ): this; - setMediaStreamSource( mediaStream: MediaStream ): this; - setBuffer( audioBuffer: AudioBuffer ): this; - play( delay?: number ): this; - onEnded(): void; - pause(): this; - stop(): this; - connect(): this; - disconnect(): this; - setDetune( value: number ): this; - getDetune(): number; - getFilters(): any[]; - setFilters( value: any[] ): this; - getFilter(): any; - setFilter( filter: any ): this; - setPlaybackRate( value: number ): this; - getPlaybackRate(): number; - getLoop(): boolean; - setLoop( value: boolean ): this; - setLoopStart( value: number ): this; - setLoopEnd( value: number ): this; - getVolume(): number; - setVolume( value: number ): this; - /** - * @deprecated Use {@link AudioLoader} instead. - */ - load( file: string ): Audio; - -} diff --git a/src/audio/AudioAnalyser.d.ts b/src/audio/AudioAnalyser.d.ts deleted file mode 100644 index 5c9e3eed62c1de..00000000000000 --- a/src/audio/AudioAnalyser.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { Audio } from './Audio'; - -export class AudioAnalyser { - - /** - * @param audio - * @param [fftSize=2048] - */ - constructor( audio: Audio, fftSize?: number ); - - analyser: AnalyserNode; - data: Uint8Array; - - getFrequencyData(): Uint8Array; - getAverageFrequency(): number; - - /** - * @deprecated Use {@link AudioAnalyser#getFrequencyData .getFrequencyData()} instead. - */ - getData( file: any ): any; - -} diff --git a/src/audio/AudioContext.d.ts b/src/audio/AudioContext.d.ts deleted file mode 100644 index 84a151709c12c8..00000000000000 --- a/src/audio/AudioContext.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/audio/AudioContext.js|src/audio/AudioContext.js} - */ -export namespace AudioContext { - - export function getContext(): AudioContext; - - export function setContext(): void - -} diff --git a/src/audio/AudioListener.d.ts b/src/audio/AudioListener.d.ts deleted file mode 100644 index 77306300ae2c24..00000000000000 --- a/src/audio/AudioListener.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { Object3D } from './../core/Object3D'; -import { AudioContext } from './AudioContext'; - -export class AudioListener extends Object3D { - - constructor(); - - type: 'AudioListener'; - context: AudioContext; - gain: GainNode; - - /** - * @default null - */ - filter: null | any; - - /** - * @default 0 - */ - timeDelta: number; - - getInput(): GainNode; - removeFilter(): this; - setFilter( value: any ): this; - getFilter(): any; - setMasterVolume( value: number ): this; - getMasterVolume(): number; - updateMatrixWorld( force?: boolean ): void; - -} diff --git a/src/audio/PositionalAudio.d.ts b/src/audio/PositionalAudio.d.ts deleted file mode 100644 index 3abf96eff105da..00000000000000 --- a/src/audio/PositionalAudio.d.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { AudioListener } from './AudioListener'; -import { Audio } from './Audio'; - -export class PositionalAudio extends Audio { - - constructor( listener: AudioListener ); - - panner: PannerNode; - - getOutput(): PannerNode; - setRefDistance( value: number ): this; - getRefDistance(): number; - setRolloffFactor( value: number ): this; - getRolloffFactor(): number; - setDistanceModel( value: string ): this; - getDistanceModel(): string; - setMaxDistance( value: number ): this; - getMaxDistance(): number; - setDirectionalCone( - coneInnerAngle: number, - coneOuterAngle: number, - coneOuterGain: number - ): this; - updateMatrixWorld( force?: boolean ): void; - -} diff --git a/src/cameras/ArrayCamera.d.ts b/src/cameras/ArrayCamera.d.ts deleted file mode 100644 index 55c920620c6c99..00000000000000 --- a/src/cameras/ArrayCamera.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { PerspectiveCamera } from './PerspectiveCamera'; - -export class ArrayCamera extends PerspectiveCamera { - - constructor( cameras?: PerspectiveCamera[] ); - - /** - * @default [] - */ - cameras: PerspectiveCamera[]; - readonly isArrayCamera: true; - -} diff --git a/src/cameras/Camera.d.ts b/src/cameras/Camera.d.ts deleted file mode 100644 index 18c3e0527fdb1d..00000000000000 --- a/src/cameras/Camera.d.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { Matrix4 } from './../math/Matrix4'; -import { Vector3 } from './../math/Vector3'; -import { Object3D } from './../core/Object3D'; - -// Cameras //////////////////////////////////////////////////////////////////////////////////////// - -/** - * Abstract base class for cameras. This class should always be inherited when you build a new camera. - */ -export class Camera extends Object3D { - - /** - * This constructor sets following properties to the correct type: matrixWorldInverse, projectionMatrix and projectionMatrixInverse. - */ - constructor(); - - /** - * This is the inverse of matrixWorld. MatrixWorld contains the Matrix which has the world transform of the Camera. - * @default new THREE.Matrix4() - */ - matrixWorldInverse: Matrix4; - - /** - * This is the matrix which contains the projection. - * @default new THREE.Matrix4() - */ - projectionMatrix: Matrix4; - - /** - * This is the inverse of projectionMatrix. - * @default new THREE.Matrix4() - */ - projectionMatrixInverse: Matrix4; - - readonly isCamera: true; - - getWorldDirection( target: Vector3 ): Vector3; - - updateMatrixWorld( force?: boolean ): void; - -} diff --git a/src/cameras/CubeCamera.d.ts b/src/cameras/CubeCamera.d.ts deleted file mode 100644 index f30370c8d97c34..00000000000000 --- a/src/cameras/CubeCamera.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { WebGLCubeRenderTarget } from './../renderers/WebGLCubeRenderTarget'; -import { Scene } from './../scenes/Scene'; -import { WebGLRenderer } from './../renderers/WebGLRenderer'; -import { Object3D } from './../core/Object3D'; - -export class CubeCamera extends Object3D { - - constructor( near: number, far: number, renderTarget: WebGLCubeRenderTarget ); - - type: 'CubeCamera'; - - renderTarget: WebGLCubeRenderTarget; - - update( renderer: WebGLRenderer, scene: Scene ): void; - -} diff --git a/src/cameras/OrthographicCamera.d.ts b/src/cameras/OrthographicCamera.d.ts deleted file mode 100644 index 7256f629e3f5bc..00000000000000 --- a/src/cameras/OrthographicCamera.d.ts +++ /dev/null @@ -1,104 +0,0 @@ -import { Camera } from './Camera'; - -/** - * Camera with orthographic projection - * - * see {@link https://github.com/mrdoob/three.js/blob/master/src/cameras/OrthographicCamera.js|src/cameras/OrthographicCamera.js} - * - * @example - * const camera = new THREE.OrthographicCamera( width / - 2, width / 2, height / 2, height / - 2, 1, 1000 ); - * scene.add( camera ); - */ -export class OrthographicCamera extends Camera { - - /** - * @param left Camera frustum left plane. - * @param right Camera frustum right plane. - * @param top Camera frustum top plane. - * @param bottom Camera frustum bottom plane. - * @param [near=0.1] Camera frustum near plane. - * @param [far=2000] Camera frustum far plane. - */ - constructor( - left: number, - right: number, - top: number, - bottom: number, - near?: number, - far?: number - ); - - type: 'OrthographicCamera'; - - readonly isOrthographicCamera: true; - - /** - * @default 1 - */ - zoom: number; - - /** - * @default null - */ - view: null | { - enabled: boolean; - fullWidth: number; - fullHeight: number; - offsetX: number; - offsetY: number; - width: number; - height: number; - }; - - /** - * Camera frustum left plane. - * @default -1 - */ - left: number; - - /** - * Camera frustum right plane. - * @default 1 - */ - right: number; - - /** - * Camera frustum top plane. - * @default 1 - */ - top: number; - - /** - * Camera frustum bottom plane. - * @default -1 - */ - bottom: number; - - /** - * Camera frustum near plane. - * @default 0.1 - */ - near: number; - - /** - * Camera frustum far plane. - * @default 2000 - */ - far: number; - - /** - * Updates the camera projection matrix. Must be called after change of parameters. - */ - updateProjectionMatrix(): void; - setViewOffset( - fullWidth: number, - fullHeight: number, - offsetX: number, - offsetY: number, - width: number, - height: number - ): void; - clearViewOffset(): void; - toJSON( meta?: any ): any; - -} diff --git a/src/cameras/PerspectiveCamera.d.ts b/src/cameras/PerspectiveCamera.d.ts deleted file mode 100644 index a31b318406bab6..00000000000000 --- a/src/cameras/PerspectiveCamera.d.ts +++ /dev/null @@ -1,143 +0,0 @@ -import { Camera } from './Camera'; - -/** - * Camera with perspective projection. - * - * @source https://github.com/mrdoob/three.js/blob/master/src/cameras/PerspectiveCamera.js - */ -export class PerspectiveCamera extends Camera { - - /** - * @param [fov=50] Camera frustum vertical field of view. Default value is 50. - * @param [aspect=1] Camera frustum aspect ratio. Default value is 1. - * @param [near=0.1] Camera frustum near plane. Default value is 0.1. - * @param [far=2000] Camera frustum far plane. Default value is 2000. - */ - constructor( fov?: number, aspect?: number, near?: number, far?: number ); - - type: 'PerspectiveCamera'; - - readonly isPerspectiveCamera: true; - - /** - * @default 1 - */ - zoom: number; - - /** - * Camera frustum vertical field of view, from bottom to top of view, in degrees. - * @default 50 - */ - fov: number; - - /** - * Camera frustum aspect ratio, window width divided by window height. - * @default 1 - */ - aspect: number; - - /** - * Camera frustum near plane. - * @default 0.1 - */ - near: number; - - /** - * Camera frustum far plane. - * @default 2000 - */ - far: number; - - /** - * @default 10 - */ - focus: number; - - /** - * @default null - */ - view: null | { - enabled: boolean; - fullWidth: number; - fullHeight: number; - offsetX: number; - offsetY: number; - width: number; - height: number; - }; - - /** - * @default 35 - */ - filmGauge: number; - - /** - * @default 0 - */ - filmOffset: number; - - setFocalLength( focalLength: number ): void; - getFocalLength(): number; - getEffectiveFOV(): number; - getFilmWidth(): number; - getFilmHeight(): number; - - /** - * Sets an offset in a larger frustum. This is useful for multi-window or multi-monitor/multi-machine setups. - * For example, if you have 3x2 monitors and each monitor is 1920x1080 and the monitors are in grid like this: - * - * +---+---+---+ - * | A | B | C | - * +---+---+---+ - * | D | E | F | - * +---+---+---+ - * - * then for each monitor you would call it like this: - * - * const w = 1920; - * const h = 1080; - * const fullWidth = w * 3; - * const fullHeight = h * 2; - * - * // A - * camera.setViewOffset( fullWidth, fullHeight, w * 0, h * 0, w, h ); - * // B - * camera.setViewOffset( fullWidth, fullHeight, w * 1, h * 0, w, h ); - * // C - * camera.setViewOffset( fullWidth, fullHeight, w * 2, h * 0, w, h ); - * // D - * camera.setViewOffset( fullWidth, fullHeight, w * 0, h * 1, w, h ); - * // E - * camera.setViewOffset( fullWidth, fullHeight, w * 1, h * 1, w, h ); - * // F - * camera.setViewOffset( fullWidth, fullHeight, w * 2, h * 1, w, h ); Note there is no reason monitors have to be the same size or in a grid. - * - * @param fullWidth full width of multiview setup - * @param fullHeight full height of multiview setup - * @param x horizontal offset of subcamera - * @param y vertical offset of subcamera - * @param width width of subcamera - * @param height height of subcamera - */ - setViewOffset( - fullWidth: number, - fullHeight: number, - x: number, - y: number, - width: number, - height: number - ): void; - clearViewOffset(): void; - - /** - * Updates the camera projection matrix. Must be called after change of parameters. - */ - updateProjectionMatrix(): void; - toJSON( meta?: any ): any; - - /** - * @deprecated Use {@link PerspectiveCamera#setFocalLength .setFocalLength()} and {@link PerspectiveCamera#filmGauge .filmGauge} instead. - */ - setLens( focalLength: number, frameHeight?: number ): void; - -} diff --git a/src/cameras/StereoCamera.d.ts b/src/cameras/StereoCamera.d.ts deleted file mode 100644 index 02234427f30f41..00000000000000 --- a/src/cameras/StereoCamera.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { PerspectiveCamera } from './PerspectiveCamera'; -import { Camera } from './Camera'; - -export class StereoCamera extends Camera { - - constructor(); - - type: 'StereoCamera'; - - /** - * @default 1 - */ - aspect: number; - - /** - * @default 0.064 - */ - eyeSep: number; - - cameraL: PerspectiveCamera; - cameraR: PerspectiveCamera; - - update( camera: PerspectiveCamera ): void; - -} diff --git a/src/constants.d.ts b/src/constants.d.ts deleted file mode 100644 index b0c1470f486894..00000000000000 --- a/src/constants.d.ts +++ /dev/null @@ -1,371 +0,0 @@ -export const REVISION: string; - -// https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent.button -export enum MOUSE { - LEFT, - MIDDLE, - RIGHT, - ROTATE, - DOLLY, - PAN, -} - -export enum TOUCH { - ROTATE, - PAN, - DOLLY_PAN, - DOLLY_ROTATE, -} - -// GL STATE CONSTANTS -export enum CullFace {} -export const CullFaceNone: CullFace; -export const CullFaceBack: CullFace; -export const CullFaceFront: CullFace; -export const CullFaceFrontBack: CullFace; - -// Shadowing Type -export enum ShadowMapType {} -export const BasicShadowMap: ShadowMapType; -export const PCFShadowMap: ShadowMapType; -export const PCFSoftShadowMap: ShadowMapType; -export const VSMShadowMap: ShadowMapType; - -// MATERIAL CONSTANTS - -// side -export enum Side {} -export const FrontSide: Side; -export const BackSide: Side; -export const DoubleSide: Side; - -// shading -export enum Shading {} -export const FlatShading: Shading; -export const SmoothShading: Shading; - -// blending modes -export enum Blending {} -export const NoBlending: Blending; -export const NormalBlending: Blending; -export const AdditiveBlending: Blending; -export const SubtractiveBlending: Blending; -export const MultiplyBlending: Blending; -export const CustomBlending: Blending; - -// custom blending equations -// (numbers start from 100 not to clash with other -// mappings to OpenGL constants defined in Texture.js) -export enum BlendingEquation {} -export const AddEquation: BlendingEquation; -export const SubtractEquation: BlendingEquation; -export const ReverseSubtractEquation: BlendingEquation; -export const MinEquation: BlendingEquation; -export const MaxEquation: BlendingEquation; - -// custom blending destination factors -export enum BlendingDstFactor {} -export const ZeroFactor: BlendingDstFactor; -export const OneFactor: BlendingDstFactor; -export const SrcColorFactor: BlendingDstFactor; -export const OneMinusSrcColorFactor: BlendingDstFactor; -export const SrcAlphaFactor: BlendingDstFactor; -export const OneMinusSrcAlphaFactor: BlendingDstFactor; -export const DstAlphaFactor: BlendingDstFactor; -export const OneMinusDstAlphaFactor: BlendingDstFactor; -export const DstColorFactor: BlendingDstFactor; -export const OneMinusDstColorFactor: BlendingDstFactor; - -// custom blending src factors -export enum BlendingSrcFactor {} -export const SrcAlphaSaturateFactor: BlendingSrcFactor; - -// depth modes -export enum DepthModes {} -export const NeverDepth: DepthModes; -export const AlwaysDepth: DepthModes; -export const LessDepth: DepthModes; -export const LessEqualDepth: DepthModes; -export const EqualDepth: DepthModes; -export const GreaterEqualDepth: DepthModes; -export const GreaterDepth: DepthModes; -export const NotEqualDepth: DepthModes; - -// TEXTURE CONSTANTS -// Operations -export enum Combine {} -export const MultiplyOperation: Combine; -export const MixOperation: Combine; -export const AddOperation: Combine; - -// Tone Mapping modes -export enum ToneMapping {} -export const NoToneMapping: ToneMapping; -export const LinearToneMapping: ToneMapping; -export const ReinhardToneMapping: ToneMapping; -export const CineonToneMapping: ToneMapping; -export const ACESFilmicToneMapping: ToneMapping; - -// Mapping modes -export enum Mapping {} -export const UVMapping: Mapping; -export const CubeReflectionMapping: Mapping; -export const CubeRefractionMapping: Mapping; -export const EquirectangularReflectionMapping: Mapping; -export const EquirectangularRefractionMapping: Mapping; -export const CubeUVReflectionMapping: Mapping; -export const CubeUVRefractionMapping: Mapping; - -// Wrapping modes -export enum Wrapping {} -export const RepeatWrapping: Wrapping; -export const ClampToEdgeWrapping: Wrapping; -export const MirroredRepeatWrapping: Wrapping; - -// Filters -export enum TextureFilter {} -export const NearestFilter: TextureFilter; -export const NearestMipmapNearestFilter: TextureFilter; -export const NearestMipMapNearestFilter: TextureFilter; -export const NearestMipmapLinearFilter: TextureFilter; -export const NearestMipMapLinearFilter: TextureFilter; -export const LinearFilter: TextureFilter; -export const LinearMipmapNearestFilter: TextureFilter; -export const LinearMipMapNearestFilter: TextureFilter; -export const LinearMipmapLinearFilter: TextureFilter; -export const LinearMipMapLinearFilter: TextureFilter; - -// Data types -export enum TextureDataType {} -export const UnsignedByteType: TextureDataType; -export const ByteType: TextureDataType; -export const ShortType: TextureDataType; -export const UnsignedShortType: TextureDataType; -export const IntType: TextureDataType; -export const UnsignedIntType: TextureDataType; -export const FloatType: TextureDataType; -export const HalfFloatType: TextureDataType; -export const UnsignedShort4444Type: TextureDataType; -export const UnsignedShort5551Type: TextureDataType; -export const UnsignedShort565Type: TextureDataType; -export const UnsignedInt248Type: TextureDataType; - -// Pixel formats -export enum PixelFormat {} -export const AlphaFormat: PixelFormat; -export const RGBFormat: PixelFormat; -export const RGBAFormat: PixelFormat; -export const LuminanceFormat: PixelFormat; -export const LuminanceAlphaFormat: PixelFormat; -export const RGBEFormat: PixelFormat; -export const DepthFormat: PixelFormat; -export const DepthStencilFormat: PixelFormat; -export const RedFormat: PixelFormat; -export const RedIntegerFormat: PixelFormat; -export const RGFormat: PixelFormat; -export const RGIntegerFormat: PixelFormat; -export const RGBIntegerFormat: PixelFormat; -export const RGBAIntegerFormat: PixelFormat; - -// Internal Pixel Formats -export type PixelFormatGPU = - 'ALPHA' - | 'RGB' - | 'RGBA' - | 'LUMINANCE' - | 'LUMINANCE_ALPHA' - | 'RED_INTEGER' - | 'R8' - | 'R8_SNORM' - | 'R8I' - | 'R8UI' - | 'R16I' - | 'R16UI' - | 'R16F' - | 'R32I' - | 'R32UI' - | 'R32F' - | 'RG8' - | 'RG8_SNORM' - | 'RG8I' - | 'RG8UI' - | 'RG16I' - | 'RG16UI' - | 'RG16F' - | 'RG32I' - | 'RG32UI' - | 'RG32F' - | 'RGB565' - | 'RGB8' - | 'RGB8_SNORM' - | 'RGB8I' - | 'RGB8UI' - | 'RGB16I' - | 'RGB16UI' - | 'RGB16F' - | 'RGB32I' - | 'RGB32UI' - | 'RGB32F' - | 'RGB9_E5' - | 'SRGB8' - | 'R11F_G11F_B10F' - | 'RGBA4' - | 'RGBA8' - | 'RGBA8_SNORM' - | 'RGBA8I' - | 'RGBA8UI' - | 'RGBA16I' - | 'RGBA16UI' - | 'RGBA16F' - | 'RGBA32I' - | 'RGBA32UI' - | 'RGBA32F' - | 'RGB5_A1' - | 'RGB10_A2' - | 'RGB10_A2UI' - | 'SRGB8_ALPHA8' - | 'DEPTH_COMPONENT16' - | 'DEPTH_COMPONENT24' - | 'DEPTH_COMPONENT32F' - | 'DEPTH24_STENCIL8' - | 'DEPTH32F_STENCIL8'; - -// Compressed texture formats -// DDS / ST3C Compressed texture formats -export enum CompressedPixelFormat {} -export const RGB_S3TC_DXT1_Format: CompressedPixelFormat; -export const RGBA_S3TC_DXT1_Format: CompressedPixelFormat; -export const RGBA_S3TC_DXT3_Format: CompressedPixelFormat; -export const RGBA_S3TC_DXT5_Format: CompressedPixelFormat; - -// PVRTC compressed './texture formats -export const RGB_PVRTC_4BPPV1_Format: CompressedPixelFormat; -export const RGB_PVRTC_2BPPV1_Format: CompressedPixelFormat; -export const RGBA_PVRTC_4BPPV1_Format: CompressedPixelFormat; -export const RGBA_PVRTC_2BPPV1_Format: CompressedPixelFormat; - -// ETC compressed texture formats -export const RGB_ETC1_Format: CompressedPixelFormat; -export const RGB_ETC2_Format: CompressedPixelFormat; -export const RGBA_ETC2_EAC_Format: CompressedPixelFormat; - -// ASTC compressed texture formats -export const RGBA_ASTC_4x4_Format: CompressedPixelFormat; -export const RGBA_ASTC_5x4_Format: CompressedPixelFormat; -export const RGBA_ASTC_5x5_Format: CompressedPixelFormat; -export const RGBA_ASTC_6x5_Format: CompressedPixelFormat; -export const RGBA_ASTC_6x6_Format: CompressedPixelFormat; -export const RGBA_ASTC_8x5_Format: CompressedPixelFormat; -export const RGBA_ASTC_8x6_Format: CompressedPixelFormat; -export const RGBA_ASTC_8x8_Format: CompressedPixelFormat; -export const RGBA_ASTC_10x5_Format: CompressedPixelFormat; -export const RGBA_ASTC_10x6_Format: CompressedPixelFormat; -export const RGBA_ASTC_10x8_Format: CompressedPixelFormat; -export const RGBA_ASTC_10x10_Format: CompressedPixelFormat; -export const RGBA_ASTC_12x10_Format: CompressedPixelFormat; -export const RGBA_ASTC_12x12_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_4x4_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_5x4_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_5x5_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_6x5_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_6x6_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_8x5_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_8x6_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_8x8_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_10x5_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_10x6_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_10x8_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_10x10_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_12x10_Format: CompressedPixelFormat; -export const SRGB8_ALPHA8_ASTC_12x12_Format: CompressedPixelFormat; - -// BPTC compressed texture formats -export const RGBA_BPTC_Format: CompressedPixelFormat; - -// Loop styles for AnimationAction -export enum AnimationActionLoopStyles {} -export const LoopOnce: AnimationActionLoopStyles; -export const LoopRepeat: AnimationActionLoopStyles; -export const LoopPingPong: AnimationActionLoopStyles; - -// Interpolation -export enum InterpolationModes {} -export const InterpolateDiscrete: InterpolationModes; -export const InterpolateLinear: InterpolationModes; -export const InterpolateSmooth: InterpolationModes; - -// Interpolant ending modes -export enum InterpolationEndingModes {} -export const ZeroCurvatureEnding: InterpolationEndingModes; -export const ZeroSlopeEnding: InterpolationEndingModes; -export const WrapAroundEnding: InterpolationEndingModes; - -// Animation blending modes -export enum AnimationBlendMode { } -export const NormalAnimationBlendMode: AnimationBlendMode; -export const AdditiveAnimationBlendMode: AnimationBlendMode; - -// Triangle Draw modes -export enum TrianglesDrawModes {} -export const TrianglesDrawMode: TrianglesDrawModes; -export const TriangleStripDrawMode: TrianglesDrawModes; -export const TriangleFanDrawMode: TrianglesDrawModes; - -// Texture Encodings -export enum TextureEncoding {} -export const LinearEncoding: TextureEncoding; -export const sRGBEncoding: TextureEncoding; -export const GammaEncoding: TextureEncoding; -export const RGBEEncoding: TextureEncoding; -export const LogLuvEncoding: TextureEncoding; -export const RGBM7Encoding: TextureEncoding; -export const RGBM16Encoding: TextureEncoding; -export const RGBDEncoding: TextureEncoding; - -// Depth packing strategies -export enum DepthPackingStrategies {} -export const BasicDepthPacking: DepthPackingStrategies; -export const RGBADepthPacking: DepthPackingStrategies; - -// Normal Map types -export enum NormalMapTypes {} -export const TangentSpaceNormalMap: NormalMapTypes; -export const ObjectSpaceNormalMap: NormalMapTypes; - -// Stencil Op types -export enum StencilOp {} -export const ZeroStencilOp: StencilOp; -export const KeepStencilOp: StencilOp; -export const ReplaceStencilOp: StencilOp; -export const IncrementStencilOp: StencilOp; -export const DecrementStencilOp: StencilOp; -export const IncrementWrapStencilOp: StencilOp; -export const DecrementWrapStencilOp: StencilOp; -export const InvertStencilOp: StencilOp; - -// Stencil Func types -export enum StencilFunc {} -export const NeverStencilFunc: StencilFunc; -export const LessStencilFunc: StencilFunc; -export const EqualStencilFunc: StencilFunc; -export const LessEqualStencilFunc: StencilFunc; -export const GreaterStencilFunc: StencilFunc; -export const NotEqualStencilFunc: StencilFunc; -export const GreaterEqualStencilFunc: StencilFunc; -export const AlwaysStencilFunc: StencilFunc; - -// usage types -export enum Usage {} -export const StaticDrawUsage: Usage; -export const DynamicDrawUsage: Usage; -export const StreamDrawUsage: Usage; -export const StaticReadUsage: Usage; -export const DynamicReadUsage: Usage; -export const StreamReadUsage: Usage; -export const StaticCopyUsage: Usage; -export const DynamicCopyUsage: Usage; -export const StreamCopyUsage: Usage; - -export enum GLSLVersion {} -export const GLSL1: GLSLVersion; -export const GLSL3: GLSLVersion; diff --git a/src/core/BufferAttribute.d.ts b/src/core/BufferAttribute.d.ts deleted file mode 100644 index 42617f13e44712..00000000000000 --- a/src/core/BufferAttribute.d.ts +++ /dev/null @@ -1,282 +0,0 @@ -import { Usage } from '../constants'; -import { Matrix3 } from './../math/Matrix3'; -import { Matrix4 } from './../math/Matrix4'; - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/BufferAttribute.js|src/core/BufferAttribute.js} - */ -export class BufferAttribute { - - constructor( array: ArrayLike, itemSize: number, normalized?: boolean ); // array parameter should be TypedArray. - - /** - * @default '' - */ - name: string; - array: ArrayLike; - itemSize: number; - - /** - * @default THREE.StaticDrawUsage - */ - usage: Usage; - - /** - * @default { offset: number; count: number } - */ - updateRange: { offset: number; count: number }; - - /** - * @default 0 - */ - version: number; - - /** - * @default false - */ - normalized: boolean; - - /** - * @default 0 - */ - count: number; - - set needsUpdate( value: boolean ); - - readonly isBufferAttribute: true; - - onUploadCallback: () => void; - onUpload( callback: () => void ): this; - setUsage( usage: Usage ): this; - clone(): BufferAttribute; - copy( source: BufferAttribute ): this; - copyAt( - index1: number, - attribute: BufferAttribute, - index2: number - ): this; - copyArray( array: ArrayLike ): this; - copyColorsArray( - colors: { r: number; g: number; b: number }[] - ): this; - copyVector2sArray( vectors: { x: number; y: number }[] ): this; - copyVector3sArray( - vectors: { x: number; y: number; z: number }[] - ): this; - copyVector4sArray( - vectors: { x: number; y: number; z: number; w: number }[] - ): this; - applyMatrix3( m: Matrix3 ): this; - applyMatrix4( m: Matrix4 ): this; - applyNormalMatrix( m: Matrix3 ): this; - transformDirection( m: Matrix4 ): this; - set( - value: ArrayLike | ArrayBufferView, - offset?: number - ): this; - getX( index: number ): number; - setX( index: number, x: number ): this; - getY( index: number ): number; - setY( index: number, y: number ): this; - getZ( index: number ): number; - setZ( index: number, z: number ): this; - getW( index: number ): number; - setW( index: number, z: number ): this; - setXY( index: number, x: number, y: number ): this; - setXYZ( index: number, x: number, y: number, z: number ): this; - setXYZW( - index: number, - x: number, - y: number, - z: number, - w: number - ): this; - toJSON(): { - itemSize: number, - type: string, - array: number[], - normalized: boolean - }; - -} - -/** - * @deprecated THREE.Int8Attribute has been removed. Use new THREE.Int8BufferAttribute() instead. - */ -export class Int8Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Uint8Attribute has been removed. Use new THREE.Uint8BufferAttribute() instead. - */ -export class Uint8Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Uint8ClampedAttribute has been removed. Use new THREE.Uint8ClampedBufferAttribute() instead. - */ -export class Uint8ClampedAttribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Int16Attribute has been removed. Use new THREE.Int16BufferAttribute() instead. - */ -export class Int16Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Uint16Attribute has been removed. Use new THREE.Uint16BufferAttribute() instead. - */ -export class Uint16Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Int32Attribute has been removed. Use new THREE.Int32BufferAttribute() instead. - */ -export class Int32Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Uint32Attribute has been removed. Use new THREE.Uint32BufferAttribute() instead. - */ -export class Uint32Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Float32Attribute has been removed. Use new THREE.Float32BufferAttribute() instead. - */ -export class Float32Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -/** - * @deprecated THREE.Float64Attribute has been removed. Use new THREE.Float64BufferAttribute() instead. - */ -export class Float64Attribute extends BufferAttribute { - - constructor( array: any, itemSize: number ); - -} - -export class Int8BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Uint8BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Uint8ClampedBufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Int16BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Uint16BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Int32BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Uint32BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Float16BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Float32BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} - -export class Float64BufferAttribute extends BufferAttribute { - - constructor( - array: Iterable | ArrayLike | ArrayBuffer | number, - itemSize: number, - normalized?: boolean - ); - -} diff --git a/src/core/BufferGeometry.d.ts b/src/core/BufferGeometry.d.ts deleted file mode 100644 index 879267deaee471..00000000000000 --- a/src/core/BufferGeometry.d.ts +++ /dev/null @@ -1,198 +0,0 @@ -import { BufferAttribute } from './BufferAttribute'; -import { Box3 } from './../math/Box3'; -import { Sphere } from './../math/Sphere'; -import { Matrix4 } from './../math/Matrix4'; -import { Vector2 } from './../math/Vector2'; -import { Vector3 } from './../math/Vector3'; -import { EventDispatcher } from './EventDispatcher'; -import { InterleavedBufferAttribute } from './InterleavedBufferAttribute'; - -/** - * This is a superefficent class for geometries because it saves all data in buffers. - * It reduces memory costs and cpu cycles. But it is not as easy to work with because of all the necessary buffer calculations. - * It is mainly interesting when working with static objects. - * - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/BufferGeometry.js|src/core/BufferGeometry.js} - */ -export class BufferGeometry extends EventDispatcher { - - /** - * This creates a new BufferGeometry. It also sets several properties to an default value. - */ - constructor(); - - static MaxIndex: number; - - /** - * Unique number of this buffergeometry instance - */ - id: number; - uuid: string; - - /** - * @default '' - */ - name: string; - - /** - * @default 'BufferGeometry' - */ - type: string; - - /** - * @default null - */ - index: BufferAttribute | null; - - /** - * @default {} - */ - attributes: { - [name: string]: BufferAttribute | InterleavedBufferAttribute; - }; - - /** - * @default {} - */ - morphAttributes: { - [name: string]: ( BufferAttribute | InterleavedBufferAttribute )[]; - }; - - /** - * @default false - */ - morphTargetsRelative: boolean; - - /** - * @default [] - */ - groups: { start: number; count: number; materialIndex?: number }[]; - - /** - * @default null - */ - boundingBox: Box3 | null; - - /** - * @default null - */ - boundingSphere: Sphere | null; - - /** - * @default { start: 0, count: Infinity } - */ - drawRange: { start: number; count: number }; - - /** - * @default {} - */ - userData: {[key: string]: any}; - readonly isBufferGeometry: true; - - getIndex(): BufferAttribute | null; - setIndex( index: BufferAttribute | number[] | null ): BufferGeometry; - - setAttribute( name: string, attribute: BufferAttribute | InterleavedBufferAttribute ): BufferGeometry; - getAttribute( name: string ): BufferAttribute | InterleavedBufferAttribute; - deleteAttribute( name: string ): BufferGeometry; - hasAttribute( name: string ): boolean; - - addGroup( start: number, count: number, materialIndex?: number ): void; - clearGroups(): void; - - setDrawRange( start: number, count: number ): void; - - /** - * Bakes matrix transform directly into vertex coordinates. - */ - applyMatrix4( matrix: Matrix4 ): BufferGeometry; - - rotateX( angle: number ): BufferGeometry; - rotateY( angle: number ): BufferGeometry; - rotateZ( angle: number ): BufferGeometry; - translate( x: number, y: number, z: number ): BufferGeometry; - scale( x: number, y: number, z: number ): BufferGeometry; - lookAt( v: Vector3 ): void; - - center(): BufferGeometry; - - setFromPoints( points: Vector3[] | Vector2[] ): BufferGeometry; - - /** - * Computes bounding box of the geometry, updating Geometry.boundingBox attribute. - * Bounding boxes aren't computed by default. They need to be explicitly computed, otherwise they are null. - */ - computeBoundingBox(): void; - - /** - * Computes bounding sphere of the geometry, updating Geometry.boundingSphere attribute. - * Bounding spheres aren't' computed by default. They need to be explicitly computed, otherwise they are null. - */ - computeBoundingSphere(): void; - - /** - * Computes and adds tangent attribute to this geometry. - */ - computeTangents(): void; - - /** - * Computes vertex normals by averaging face normals. - */ - computeVertexNormals(): void; - - merge( geometry: BufferGeometry, offset?: number ): BufferGeometry; - normalizeNormals(): void; - - toNonIndexed(): BufferGeometry; - - toJSON(): any; - clone(): BufferGeometry; - copy( source: BufferGeometry ): this; - - /** - * Disposes the object from memory. - * You need to call this when you want the bufferGeometry removed while the application is running. - */ - dispose(): void; - - /** - * @deprecated Use {@link BufferGeometry#groups .groups} instead. - */ - drawcalls: any; - - /** - * @deprecated Use {@link BufferGeometry#groups .groups} instead. - */ - offsets: any; - - /** - * @deprecated Use {@link BufferGeometry#setIndex .setIndex()} instead. - */ - addIndex( index: any ): void; - - /** - * @deprecated Use {@link BufferGeometry#addGroup .addGroup()} instead. - */ - addDrawCall( start: any, count: any, indexOffset?: any ): void; - - /** - * @deprecated Use {@link BufferGeometry#clearGroups .clearGroups()} instead. - */ - clearDrawCalls(): void; - - /** - * @deprecated Use {@link BufferGeometry#setAttribute .setAttribute()} instead. - */ - addAttribute( - name: string, - attribute: BufferAttribute | InterleavedBufferAttribute - ): BufferGeometry; - - /** - * @deprecated Use {@link BufferGeometry#deleteAttribute .deleteAttribute()} instead. - */ - removeAttribute( name: string ): BufferGeometry; - - addAttribute( name: any, array: any, itemSize: any ): any; - -} diff --git a/src/core/Clock.d.ts b/src/core/Clock.d.ts deleted file mode 100644 index 3d75fa0c1772f7..00000000000000 --- a/src/core/Clock.d.ts +++ /dev/null @@ -1,66 +0,0 @@ -/** - * Object for keeping track of time. - * - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/Clock.js|src/core/Clock.js} - */ -export class Clock { - - /** - * @param [autoStart=true] Automatically start the clock. - */ - constructor( autoStart?: boolean ); - - /** - * If set, starts the clock automatically when the first update is called. - * @default true - */ - autoStart: boolean; - - /** - * When the clock is running, It holds the starttime of the clock. - * This counted from the number of milliseconds elapsed since 1 January 1970 00:00:00 UTC. - * @default 0 - */ - startTime: number; - - /** - * When the clock is running, It holds the previous time from a update. - * This counted from the number of milliseconds elapsed since 1 January 1970 00:00:00 UTC. - * @default 0 - */ - oldTime: number; - - /** - * When the clock is running, It holds the time elapsed between the start of the clock to the previous update. - * This parameter is in seconds of three decimal places. - * @default 0 - */ - elapsedTime: number; - - /** - * This property keeps track whether the clock is running or not. - * @default false - */ - running: boolean; - - /** - * Starts clock. - */ - start(): void; - - /** - * Stops clock. - */ - stop(): void; - - /** - * Get the seconds passed since the clock started. - */ - getElapsedTime(): number; - - /** - * Get the seconds passed since the last call to this method. - */ - getDelta(): number; - -} diff --git a/src/core/EventDispatcher.d.ts b/src/core/EventDispatcher.d.ts deleted file mode 100644 index 6f7d69cf5451fd..00000000000000 --- a/src/core/EventDispatcher.d.ts +++ /dev/null @@ -1,49 +0,0 @@ -/** - * Event object. - */ -export interface Event { - type: string; - target?: any; - [attachment: string]: any; -} - -/** - * JavaScript events for custom objects - * - * @source src/core/EventDispatcher.js - */ -export class EventDispatcher { - - /** - * Creates eventDispatcher object. It needs to be call with '.call' to add the functionality to an object. - */ - constructor(); - - /** - * Adds a listener to an event type. - * @param type The type of event to listen to. - * @param listener The function that gets called when the event is fired. - */ - addEventListener( type: string, listener: ( event: Event ) => void ): void; - - /** - * Checks if listener is added to an event type. - * @param type The type of event to listen to. - * @param listener The function that gets called when the event is fired. - */ - hasEventListener( type: string, listener: ( event: Event ) => void ): boolean; - - /** - * Removes a listener from an event type. - * @param type The type of the listener that gets removed. - * @param listener The listener function that gets removed. - */ - removeEventListener( type: string, listener: ( event: Event ) => void ): void; - - /** - * Fire an event type. - * @param type The type of event that gets fired. - */ - dispatchEvent( event: { type: string; [attachment: string]: any } ): void; - -} diff --git a/src/core/GLBufferAttribute.d.ts b/src/core/GLBufferAttribute.d.ts deleted file mode 100644 index a9fe3ecab02226..00000000000000 --- a/src/core/GLBufferAttribute.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/GLBufferAttribute.js|src/core/GLBufferAttribute.js} - */ - -export class GLBufferAttribute { - - constructor( - buffer: WebGLBuffer, - type: number, - itemSize: number, - elementSize: 1 | 2 | 4, - count: number - ); - - buffer: WebGLBuffer; - type: number; - itemSize: number; - elementSize: 1 | 2 | 4; - count: number; - version: number; - - readonly isGLBufferAttribute: true; - - set needsUpdate( value: boolean ); - - setBuffer( buffer: WebGLBuffer ): this; - setType( type: number, elementSize: 1 | 2 | 4 ): this; - setItemSize( itemSize: number ): this; - setCount( count: number ): this; - -} diff --git a/src/core/InstancedBufferAttribute.d.ts b/src/core/InstancedBufferAttribute.d.ts deleted file mode 100644 index a6410474fcdad2..00000000000000 --- a/src/core/InstancedBufferAttribute.d.ts +++ /dev/null @@ -1,52 +0,0 @@ -import { BufferGeometry } from './BufferGeometry'; -import { BufferAttribute } from './BufferAttribute'; - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/examples/jsm/utils/BufferGeometryUtils.js|examples/jsm/utils/BufferGeometryUtils.js} - */ -export namespace BufferGeometryUtils { - export function mergeBufferGeometries( - geometries: BufferGeometry[] - ): BufferGeometry; - export function computeTangents( geometry: BufferGeometry ): null; - export function mergeBufferAttributes( - attributes: BufferAttribute[] - ): BufferAttribute; -} - -/** - * @deprecated - */ -export namespace GeometryUtils { - /** - * @deprecated Use {@link Geometry#merge geometry.merge( geometry2, matrix, materialIndexOffset )} instead. - */ - export function merge( - geometry1: any, - geometry2: any, - materialIndexOffset?: any - ): any; - /** - * @deprecated Use {@link Geometry#center geometry.center()} instead. - */ - export function center( geometry: any ): any; -} - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/InstancedBufferAttribute.js|src/core/InstancedBufferAttribute.js} - */ -export class InstancedBufferAttribute extends BufferAttribute { - - constructor( - array: ArrayLike, - itemSize: number, - normalized?: boolean, - meshPerAttribute?: number - ); - - /** - * @default 1 - */ - meshPerAttribute: number; - -} diff --git a/src/core/InstancedBufferGeometry.d.ts b/src/core/InstancedBufferGeometry.d.ts deleted file mode 100644 index fb2e534b201793..00000000000000 --- a/src/core/InstancedBufferGeometry.d.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { BufferGeometry } from './BufferGeometry'; - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/InstancedBufferGeometry.js|src/core/InstancedBufferGeometry.js} - */ -export class InstancedBufferGeometry extends BufferGeometry { - - constructor(); - - /** - * @default 'InstancedBufferGeometry - */ - type: string; - - isInstancedBufferGeometry: boolean; - - groups: { start: number; count: number; instances: number }[]; - - /** - * @default Infinity - */ - instanceCount: number; - - addGroup( start: number, count: number, instances: number ): void; - -} diff --git a/src/core/InstancedInterleavedBuffer.d.ts b/src/core/InstancedInterleavedBuffer.d.ts deleted file mode 100644 index 0cbf620ef0a21f..00000000000000 --- a/src/core/InstancedInterleavedBuffer.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { InterleavedBuffer } from './InterleavedBuffer'; - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/InstancedInterleavedBuffer.js|src/core/InstancedInterleavedBuffer.js} - */ -export class InstancedInterleavedBuffer extends InterleavedBuffer { - - constructor( - array: ArrayLike, - stride: number, - meshPerAttribute?: number - ); - - /** - * @default 1 - */ - meshPerAttribute: number; - -} diff --git a/src/core/InterleavedBuffer.d.ts b/src/core/InterleavedBuffer.d.ts deleted file mode 100644 index d6e243dad7645f..00000000000000 --- a/src/core/InterleavedBuffer.d.ts +++ /dev/null @@ -1,54 +0,0 @@ -import { InterleavedBufferAttribute } from './InterleavedBufferAttribute'; -import { Usage } from '../constants'; - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/InterleavedBuffer.js|src/core/InterleavedBuffer.js} - */ -export class InterleavedBuffer { - - constructor( array: ArrayLike, stride: number ); - - array: ArrayLike; - stride: number; - - /** - * @default THREE.StaticDrawUsage - */ - usage: Usage; - - /** - * @default { offset: number; count: number } - */ - updateRange: { offset: number; count: number }; - - /** - * @default 0 - */ - version: number; - - length: number; - - /** - * @default 0 - */ - count: number; - needsUpdate: boolean; - uuid: string; - - setUsage( usage: Usage ): InterleavedBuffer; - clone( data: object ): InterleavedBuffer; - copy( source: InterleavedBuffer ): this; - copyAt( - index1: number, - attribute: InterleavedBufferAttribute, - index2: number - ): InterleavedBuffer; - set( value: ArrayLike, index: number ): InterleavedBuffer; - toJSON( data: object ): { - uuid: string, - buffer: string, - type: string, - stride: number - }; - -} diff --git a/src/core/InterleavedBufferAttribute.d.ts b/src/core/InterleavedBufferAttribute.d.ts deleted file mode 100644 index 32aadf82716053..00000000000000 --- a/src/core/InterleavedBufferAttribute.d.ts +++ /dev/null @@ -1,67 +0,0 @@ -import { BufferAttribute } from './BufferAttribute'; -import { InterleavedBuffer } from './InterleavedBuffer'; -import { Matrix4 } from './../math/Matrix4'; -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/core/InterleavedBufferAttribute.js|src/core/InterleavedBufferAttribute.js} - */ -export class InterleavedBufferAttribute { - - constructor( - interleavedBuffer: InterleavedBuffer, - itemSize: number, - offset: number, - normalized?: boolean - ); - - /** - * @default '' - */ - name: string; - data: InterleavedBuffer; - itemSize: number; - offset: number; - - /** - * @default false - */ - normalized: boolean; - - get count(): number; - get array(): ArrayLike; - set needsUpdate( value: boolean ); - - readonly isInterleavedBufferAttribute: true; - - applyMatrix4( m: Matrix4 ): this; - clone( data?: object ): BufferAttribute; - getX( index: number ): number; - setX( index: number, x: number ): InterleavedBufferAttribute; - getY( index: number ): number; - setY( index: number, y: number ): InterleavedBufferAttribute; - getZ( index: number ): number; - setZ( index: number, z: number ): InterleavedBufferAttribute; - getW( index: number ): number; - setW( index: number, z: number ): InterleavedBufferAttribute; - setXY( index: number, x: number, y: number ): InterleavedBufferAttribute; - setXYZ( - index: number, - x: number, - y: number, - z: number - ): InterleavedBufferAttribute; - setXYZW( - index: number, - x: number, - y: number, - z: number, - w: number - ): InterleavedBufferAttribute; - toJSON( data?: object ): { - isInterleavedBufferAttribute: true, - itemSize: number, - data: string, - offset: number, - normalized: boolean - }; - -} diff --git a/src/core/Layers.d.ts b/src/core/Layers.d.ts deleted file mode 100644 index 45d09dcedadcac..00000000000000 --- a/src/core/Layers.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -export class Layers { - - constructor(); - - /** - * @default 1 | 0 - */ - mask: number; - - set( channel: number ): void; - enable( channel: number ): void; - enableAll(): void; - toggle( channel: number ): void; - disable( channel: number ): void; - disableAll(): void; - test( layers: Layers ): boolean; - -} diff --git a/src/core/Object3D.d.ts b/src/core/Object3D.d.ts deleted file mode 100644 index ac98ca9168ccf3..00000000000000 --- a/src/core/Object3D.d.ts +++ /dev/null @@ -1,390 +0,0 @@ -import { Vector3 } from './../math/Vector3'; -import { Euler } from './../math/Euler'; -import { Quaternion } from './../math/Quaternion'; -import { Matrix4 } from './../math/Matrix4'; -import { Matrix3 } from './../math/Matrix3'; -import { Layers } from './Layers'; -import { WebGLRenderer } from './../renderers/WebGLRenderer'; -import { Scene } from './../scenes/Scene'; -import { Camera } from './../cameras/Camera'; -import { Material } from './../materials/Material'; -import { Group } from './../objects/Group'; -import { Raycaster } from './Raycaster'; -import { EventDispatcher } from './EventDispatcher'; -import { BufferGeometry } from './BufferGeometry'; -import { Intersection } from './Raycaster'; -import { AnimationClip } from '../animation/AnimationClip'; - -/** - * Base class for scene graph objects - */ -export class Object3D extends EventDispatcher { - - constructor(); - - /** - * Unique number of this object instance. - */ - id: number; - - /** - * - */ - uuid: string; - - /** - * Optional name of the object (doesn't need to be unique). - * @default '' - */ - name: string; - - /** - * @default 'Object3D' - */ - type: string; - - /** - * Object's parent in the scene graph. - * @default null - */ - parent: Object3D | null; - - /** - * Array with object's children. - * @default [] - */ - children: Object3D[]; - - /** - * Up direction. - * @default THREE.Object3D.DefaultUp.clone() - */ - up: Vector3; - - /** - * Object's local position. - * @default new THREE.Vector3() - */ - readonly position: Vector3; - - /** - * Object's local rotation (Euler angles), in radians. - * @default new THREE.Euler() - */ - readonly rotation: Euler; - - /** - * Object's local rotation as a Quaternion. - * @default new THREE.Quaternion() - */ - readonly quaternion: Quaternion; - - /** - * Object's local scale. - * @default new THREE.Vector3() - */ - readonly scale: Vector3; - - /** - * @default new THREE.Matrix4() - */ - readonly modelViewMatrix: Matrix4; - - /** - * @default new THREE.Matrix3() - */ - readonly normalMatrix: Matrix3; - - /** - * Local transform. - * @default new THREE.Matrix4() - */ - matrix: Matrix4; - - /** - * The global transform of the object. If the Object3d has no parent, then it's identical to the local transform. - * @default new THREE.Matrix4() - */ - matrixWorld: Matrix4; - - /** - * When this is set, it calculates the matrix of position, (rotation or quaternion) and scale every frame and also recalculates the matrixWorld property. - * @default THREE.Object3D.DefaultMatrixAutoUpdate - */ - matrixAutoUpdate: boolean; - - /** - * When this is set, it calculates the matrixWorld in that frame and resets this property to false. - * @default false - */ - matrixWorldNeedsUpdate: boolean; - - /** - * @default new THREE.Layers() - */ - layers: Layers; - /** - * Object gets rendered if true. - * @default true - */ - visible: boolean; - - /** - * Gets rendered into shadow map. - * @default false - */ - castShadow: boolean; - - /** - * Material gets baked in shadow receiving. - * @default false - */ - receiveShadow: boolean; - - /** - * When this is set, it checks every frame if the object is in the frustum of the camera. Otherwise the object gets drawn every frame even if it isn't visible. - * @default true - */ - frustumCulled: boolean; - - /** - * Overrides the default rendering order of scene graph objects, from lowest to highest renderOrder. Opaque and transparent objects remain sorted independently though. When this property is set for an instance of Group, all descendants objects will be sorted and rendered together. - * @default 0 - */ - renderOrder: number; - - /** - * Array with animation clips. - * @default [] - */ - animations: AnimationClip[]; - - /** - * An object that can be used to store custom data about the Object3d. It should not hold references to functions as these will not be cloned. - * @default {} - */ - userData: { [key: string]: any }; - - /** - * Custom depth material to be used when rendering to the depth map. Can only be used in context of meshes. - * When shadow-casting with a DirectionalLight or SpotLight, if you are (a) modifying vertex positions in - * the vertex shader, (b) using a displacement map, (c) using an alpha map with alphaTest, or (d) using a - * transparent texture with alphaTest, you must specify a customDepthMaterial for proper shadows. - */ - customDepthMaterial: Material; - - /** - * Same as customDepthMaterial, but used with PointLight. - */ - customDistanceMaterial: Material; - - /** - * Used to check whether this or derived classes are Object3Ds. Default is true. - * You should not change this, as it is used internally for optimisation. - */ - readonly isObject3D: true; - - /** - * Calls before rendering object - */ - onBeforeRender: ( - renderer: WebGLRenderer, - scene: Scene, - camera: Camera, - geometry: BufferGeometry, - material: Material, - group: Group - ) => void; - - /** - * Calls after rendering object - */ - onAfterRender: ( - renderer: WebGLRenderer, - scene: Scene, - camera: Camera, - geometry: BufferGeometry, - material: Material, - group: Group - ) => void; - - static DefaultUp: Vector3; - static DefaultMatrixAutoUpdate: boolean; - - /** - * This updates the position, rotation and scale with the matrix. - */ - applyMatrix4( matrix: Matrix4 ): void; - - applyQuaternion( quaternion: Quaternion ): this; - - /** - * - */ - setRotationFromAxisAngle( axis: Vector3, angle: number ): void; - - /** - * - */ - setRotationFromEuler( euler: Euler ): void; - - /** - * - */ - setRotationFromMatrix( m: Matrix4 ): void; - - /** - * - */ - setRotationFromQuaternion( q: Quaternion ): void; - - /** - * Rotate an object along an axis in object space. The axis is assumed to be normalized. - * @param axis A normalized vector in object space. - * @param angle The angle in radians. - */ - rotateOnAxis( axis: Vector3, angle: number ): this; - - /** - * Rotate an object along an axis in world space. The axis is assumed to be normalized. Method Assumes no rotated parent. - * @param axis A normalized vector in object space. - * @param angle The angle in radians. - */ - rotateOnWorldAxis( axis: Vector3, angle: number ): this; - - /** - * - * @param angle - */ - rotateX( angle: number ): this; - - /** - * - * @param angle - */ - rotateY( angle: number ): this; - - /** - * - * @param angle - */ - rotateZ( angle: number ): this; - - /** - * @param axis A normalized vector in object space. - * @param distance The distance to translate. - */ - translateOnAxis( axis: Vector3, distance: number ): this; - - /** - * Translates object along x axis by distance. - * @param distance Distance. - */ - translateX( distance: number ): this; - - /** - * Translates object along y axis by distance. - * @param distance Distance. - */ - translateY( distance: number ): this; - - /** - * Translates object along z axis by distance. - * @param distance Distance. - */ - translateZ( distance: number ): this; - - /** - * Updates the vector from local space to world space. - * @param vector A local vector. - */ - localToWorld( vector: Vector3 ): Vector3; - - /** - * Updates the vector from world space to local space. - * @param vector A world vector. - */ - worldToLocal( vector: Vector3 ): Vector3; - - /** - * Rotates object to face point in space. - * @param vector A world vector to look at. - */ - lookAt( vector: Vector3 | number, y?: number, z?: number ): void; - - /** - * Adds object as child of this object. - */ - add( ...object: Object3D[] ): this; - - /** - * Removes object as child of this object. - */ - remove( ...object: Object3D[] ): this; - - /** - * Removes all child objects. - */ - clear(): this; - - /** - * Adds object as a child of this, while maintaining the object's world transform. - */ - attach( object: Object3D ): this; - - /** - * Searches through the object's children and returns the first with a matching id. - * @param id Unique number of the object instance - */ - getObjectById( id: number ): Object3D | undefined; - - /** - * Searches through the object's children and returns the first with a matching name. - * @param name String to match to the children's Object3d.name property. - */ - getObjectByName( name: string ): Object3D | undefined; - - getObjectByProperty( name: string, value: string ): Object3D | undefined; - - getWorldPosition( target: Vector3 ): Vector3; - getWorldQuaternion( target: Quaternion ): Quaternion; - getWorldScale( target: Vector3 ): Vector3; - getWorldDirection( target: Vector3 ): Vector3; - - raycast( raycaster: Raycaster, intersects: Intersection[] ): void; - - traverse( callback: ( object: Object3D ) => any ): void; - - traverseVisible( callback: ( object: Object3D ) => any ): void; - - traverseAncestors( callback: ( object: Object3D ) => any ): void; - - /** - * Updates local transform. - */ - updateMatrix(): void; - - /** - * Updates global transform of the object and its children. - */ - updateMatrixWorld( force?: boolean ): void; - - updateWorldMatrix( updateParents: boolean, updateChildren: boolean ): void; - - toJSON( meta?: { - geometries: any; - materials: any; - textures: any; - images: any; - } ): any; - - clone( recursive?: boolean ): Object3D; - - /** - * - * @param object - * @param recursive - */ - copy( source: this, recursive?: boolean ): this; - -} diff --git a/src/core/Raycaster.d.ts b/src/core/Raycaster.d.ts deleted file mode 100644 index e651c6e06dc1ba..00000000000000 --- a/src/core/Raycaster.d.ts +++ /dev/null @@ -1,124 +0,0 @@ -import { Vector3 } from './../math/Vector3'; -import { Object3D } from './Object3D'; -import { Vector2 } from './../math/Vector2'; -import { Ray } from './../math/Ray'; -import { Camera } from './../cameras/Camera'; -import { Layers } from './Layers'; - -export interface Face { - a: number; - b: number; - c: number; - normal: Vector3; - materialIndex: number; -} - -export interface Intersection { - distance: number; - distanceToRay?: number; - point: Vector3; - index?: number; - face?: Face | null; - faceIndex?: number; - object: Object3D; - uv?: Vector2; - instanceId?: number; -} - -export interface RaycasterParameters { - Mesh?: any; - Line?: { threshold: number }; - LOD?: any; - Points?: { threshold: number }; - Sprite?: any; -} - -export class Raycaster { - - /** - * This creates a new raycaster object. - * @param origin The origin vector where the ray casts from. - * @param direction The direction vector that gives direction to the ray. Should be normalized. - * @param near All results returned are further away than near. Near can't be negative. Default value is 0. - * @param far All results returned are closer then far. Far can't be lower then near . Default value is Infinity. - */ - constructor( - origin?: Vector3, - direction?: Vector3, - near?: number, - far?: number - ); - - /** The Ray used for the raycasting. */ - ray: Ray; - - /** - * The near factor of the raycaster. This value indicates which objects can be discarded based on the - * distance. This value shouldn't be negative and should be smaller than the far property. - * @default 0 - */ - near: number; - - /** - * The far factor of the raycaster. This value indicates which objects can be discarded based on the - * distance. This value shouldn't be negative and should be larger than the near property. - * @default Infinity - */ - far: number; - - /** - * The camera to use when raycasting against view-dependent objects such as billboarded objects like Sprites. This field - * can be set manually or is set when calling "setFromCamera". - */ - camera: Camera; - - /** - * Used by Raycaster to selectively ignore 3D objects when performing intersection tests. - * @default new THREE.Layers() - */ - layers: Layers; - - /** - * @default { Mesh: {}, Line: { threshold: 1 }, LOD: {}, Points: { threshold: 1 }, Sprite: {} } - */ - params: RaycasterParameters; - - /** - * Updates the ray with a new origin and direction. - * @param origin The origin vector where the ray casts from. - * @param direction The normalized direction vector that gives direction to the ray. - */ - set( origin: Vector3, direction: Vector3 ): void; - - /** - * Updates the ray with a new origin and direction. - * @param coords 2D coordinates of the mouse, in normalized device coordinates (NDC)---X and Y components should be between -1 and 1. - * @param camera camera from which the ray should originate - */ - setFromCamera( coords: { x: number; y: number }, camera: Camera ): void; - - /** - * Checks all intersection between the ray and the object with or without the descendants. Intersections are returned sorted by distance, closest first. - * @param object The object to check for intersection with the ray. - * @param recursive If true, it also checks all descendants. Otherwise it only checks intersecton with the object. Default is false. - * @param optionalTarget (optional) target to set the result. Otherwise a new Array is instantiated. If set, you must clear this array prior to each call (i.e., array.length = 0;). - */ - intersectObject( - object: Object3D, - recursive?: boolean, - optionalTarget?: Intersection[] - ): Intersection[]; - - /** - * Checks all intersection between the ray and the objects with or without the descendants. Intersections are returned sorted by distance, closest first. Intersections are of the same form as those returned by .intersectObject. - * @param objects The objects to check for intersection with the ray. - * @param recursive If true, it also checks all descendants of the objects. Otherwise it only checks intersecton with the objects. Default is false. - * @param optionalTarget (optional) target to set the result. Otherwise a new Array is instantiated. If set, you must clear this array prior to each call (i.e., array.length = 0;). - */ - intersectObjects( - objects: Object3D[], - recursive?: boolean, - optionalTarget?: Intersection[] - ): Intersection[]; - -} diff --git a/src/core/Uniform.d.ts b/src/core/Uniform.d.ts deleted file mode 100644 index b890fd65a57ab0..00000000000000 --- a/src/core/Uniform.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -export class Uniform { - - constructor( value: any ); - /** - * @deprecated - */ - constructor( type: string, value: any ); - /** - * @deprecated - */ - type: string; - value: any; - /** - * @deprecated Use {@link Object3D#onBeforeRender object.onBeforeRender()} instead. - */ - dynamic: boolean; - onUpdateCallback: Function; - - /** - * @deprecated Use {@link Object3D#onBeforeRender object.onBeforeRender()} instead. - */ - onUpdate( callback: Function ): Uniform; - -} diff --git a/src/extras/DataUtils.d.ts b/src/extras/DataUtils.d.ts deleted file mode 100644 index 74236b9df795e6..00000000000000 --- a/src/extras/DataUtils.d.ts +++ /dev/null @@ -1,5 +0,0 @@ -export namespace DataUtils { - - export function toHalfFloat( val: number ): number; - -} diff --git a/src/extras/ImageUtils.d.ts b/src/extras/ImageUtils.d.ts deleted file mode 100644 index ea1bddba2907c9..00000000000000 --- a/src/extras/ImageUtils.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { Mapping } from '../constants'; -import { Texture } from '../textures/Texture'; - -export namespace ImageUtils { - - export function getDataURL( - image: any, - ): string; - - /** - * @deprecated - */ - export let crossOrigin: string; - - /** - * @deprecated Use {@link TextureLoader THREE.TextureLoader()} instead. - */ - export function loadTexture( - url: string, - mapping?: Mapping, - onLoad?: ( texture: Texture ) => void, - onError?: ( message: string ) => void - ): Texture; - - /** - * @deprecated Use {@link CubeTextureLoader THREE.CubeTextureLoader()} instead. - */ - export function loadTextureCube( - array: string[], - mapping?: Mapping, - onLoad?: ( texture: Texture ) => void, - onError?: ( message: string ) => void - ): Texture; -} diff --git a/src/extras/PMREMGenerator.d.ts b/src/extras/PMREMGenerator.d.ts deleted file mode 100644 index a6c69256f64b40..00000000000000 --- a/src/extras/PMREMGenerator.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { WebGLRenderer } from '../renderers/WebGLRenderer'; -import { WebGLRenderTarget } from '../renderers/WebGLRenderTarget'; -import { Texture } from '../textures/Texture'; -import { CubeTexture } from '../textures/CubeTexture'; -import { Scene } from '../scenes/Scene'; - -export class PMREMGenerator { - - constructor( renderer:WebGLRenderer ); - fromScene( scene:Scene, sigma?:number, near?:number, far?:number ): WebGLRenderTarget; - fromEquirectangular( equirectangular:Texture ): WebGLRenderTarget; - fromCubemap( cubemap:CubeTexture ): WebGLRenderTarget; - compileCubemapShader(): void; - compileEquirectangularShader(): void; - dispose(): void; - -} diff --git a/src/extras/ShapeUtils.d.ts b/src/extras/ShapeUtils.d.ts deleted file mode 100644 index c30978782f3c83..00000000000000 --- a/src/extras/ShapeUtils.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -interface Vec2 { - x: number; - y: number; -} - -export namespace ShapeUtils { - export function area( contour: Vec2[] ): number; - export function triangulateShape( contour: Vec2[], holes: Vec2[][] ): number[][]; - export function isClockWise( pts: Vec2[] ): boolean; -} diff --git a/src/extras/core/Curve.d.ts b/src/extras/core/Curve.d.ts deleted file mode 100644 index a84970dcb928b4..00000000000000 --- a/src/extras/core/Curve.d.ts +++ /dev/null @@ -1,99 +0,0 @@ -import { Vector } from './../../math/Vector2'; -import { Vector3 } from './../../math/Vector3'; - -// Extras / Core ///////////////////////////////////////////////////////////////////// - -/** - * An extensible curve object which contains methods for interpolation - * class Curve - */ -export class Curve { - - /** - * @default 'Curve' - */ - type: string; - - /** - * This value determines the amount of divisions when calculating the cumulative segment lengths of a curve via .getLengths. - * To ensure precision when using methods like .getSpacedPoints, it is recommended to increase .arcLengthDivisions if the curve is very large. - * @default 200 - */ - arcLengthDivisions: number; - - /** - * Returns a vector for point t of the curve where t is between 0 and 1 - * getPoint(t: number, optionalTarget?: T): T; - */ - getPoint( t: number, optionalTarget?: T ): T; - - /** - * Returns a vector for point at relative position in curve according to arc length - * getPointAt(u: number, optionalTarget?: T): T; - */ - getPointAt( u: number, optionalTarget?: T ): T; - - /** - * Get sequence of points using getPoint( t ) - * getPoints(divisions?: number): T[]; - */ - getPoints( divisions?: number ): T[]; - - /** - * Get sequence of equi-spaced points using getPointAt( u ) - * getSpacedPoints(divisions?: number): T[]; - */ - getSpacedPoints( divisions?: number ): T[]; - - /** - * Get total curve arc length - */ - getLength(): number; - - /** - * Get list of cumulative segment lengths - */ - getLengths( divisions?: number ): number[]; - - /** - * Update the cumlative segment distance cache - */ - updateArcLengths(): void; - - /** - * Given u ( 0 .. 1 ), get a t to find p. This gives you points which are equi distance - */ - getUtoTmapping( u: number, distance: number ): number; - - /** - * Returns a unit vector tangent at t. If the subclassed curve do not implement its tangent derivation, 2 points a small delta apart will be used to find its gradient which seems to give a reasonable approximation - * getTangent(t: number, optionalTarget?: T): T; - */ - getTangent( t: number, optionalTarget?: T ): T; - - /** - * Returns tangent at equidistance point u on the curve - * getTangentAt(u: number, optionalTarget?: T): T; - */ - getTangentAt( u: number, optionalTarget?: T ): T; - - /** - * Generate Frenet frames of the curve - */ - computeFrenetFrames( segments: number, closed?: boolean ): { - tangents: Vector3[], - normals: Vector3[], - binormals: Vector3[] - }; - - clone(): Curve; - copy( source: Curve ): this; - toJSON(): object; - fromJSON( json: object ): this; - - /** - * @deprecated since r84. - */ - static create( constructorFunc: Function, getPointFunc: Function ): Function; - -} diff --git a/src/extras/core/CurvePath.d.ts b/src/extras/core/CurvePath.d.ts deleted file mode 100644 index 1d408c545e953a..00000000000000 --- a/src/extras/core/CurvePath.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Curve } from './Curve'; -import { Vector } from './../../math/Vector2'; - -export class CurvePath extends Curve { - - constructor(); - - /** - * @default 'CurvePath' - */ - type: string; - - /** - * @default [] - */ - curves: Curve[]; - - /** - * @default false - */ - autoClose: boolean; - - add( curve: Curve ): void; - closePath(): void; - getPoint( t: number ): T; - getCurveLengths(): number[]; - -} diff --git a/src/extras/core/Font.d.ts b/src/extras/core/Font.d.ts deleted file mode 100644 index de30b4a5738938..00000000000000 --- a/src/extras/core/Font.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Shape } from './Shape'; - -export class Font { - - constructor( jsondata: any ); - - /** - * @default 'Font' - */ - type: string; - - data: string; - - generateShapes( text: string, size: number ): Shape[]; - -} diff --git a/src/extras/core/Interpolations.d.ts b/src/extras/core/Interpolations.d.ts deleted file mode 100644 index f0d8970d1bd4b9..00000000000000 --- a/src/extras/core/Interpolations.d.ts +++ /dev/null @@ -1,5 +0,0 @@ -export namespace Interpolations { - export function CatmullRom( t: number, p0: number, p1: number, p2: number, p3: number ): number; - export function QuadraticBezier( t: number, p0: number, p1: number, p2: number ): number; - export function CubicBezier( t: number, p0: number, p1: number, p2: number, p3: number ): number; -} diff --git a/src/extras/core/Path.d.ts b/src/extras/core/Path.d.ts deleted file mode 100644 index 5ad8a23fdd145a..00000000000000 --- a/src/extras/core/Path.d.ts +++ /dev/null @@ -1,75 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { CurvePath } from './CurvePath'; - -/** - * a 2d path representation, comprising of points, lines, and cubes, similar to the html5 2d canvas api. It extends CurvePath. - */ -export class Path extends CurvePath { - - constructor( points?: Vector2[] ); - - /** - * @default 'Path' - */ - type: string; - - /** - * @default new THREE.Vector2() - */ - currentPoint: Vector2; - - /** - * @deprecated Use {@link Path#setFromPoints .setFromPoints()} instead. - */ - fromPoints( vectors: Vector2[] ): this; - setFromPoints( vectors: Vector2[] ): this; - moveTo( x: number, y: number ): this; - lineTo( x: number, y: number ): this; - quadraticCurveTo( aCPx: number, aCPy: number, aX: number, aY: number ): this; - bezierCurveTo( - aCP1x: number, - aCP1y: number, - aCP2x: number, - aCP2y: number, - aX: number, - aY: number - ): this; - splineThru( pts: Vector2[] ): this; - arc( - aX: number, - aY: number, - aRadius: number, - aStartAngle: number, - aEndAngle: number, - aClockwise: boolean - ): this; - absarc( - aX: number, - aY: number, - aRadius: number, - aStartAngle: number, - aEndAngle: number, - aClockwise: boolean - ): this; - ellipse( - aX: number, - aY: number, - xRadius: number, - yRadius: number, - aStartAngle: number, - aEndAngle: number, - aClockwise: boolean, - aRotation: number - ): this; - absellipse( - aX: number, - aY: number, - xRadius: number, - yRadius: number, - aStartAngle: number, - aEndAngle: number, - aClockwise: boolean, - aRotation: number - ): this; - -} diff --git a/src/extras/core/Shape.d.ts b/src/extras/core/Shape.d.ts deleted file mode 100644 index 614cd4976c97cd..00000000000000 --- a/src/extras/core/Shape.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { Path } from './Path'; - -/** - * Defines a 2d shape plane using paths. - */ -export class Shape extends Path { - - constructor( points?: Vector2[] ); - - /** - * @default 'Shape' - */ - type: string; - - /** - * - */ - uuid: string; - - /** - * @default [] - */ - holes: Path[]; - - getPointsHoles( divisions: number ): Vector2[][]; - - extractPoints( divisions: number ): { - shape: Vector2[]; - holes: Vector2[][]; - }; - -} diff --git a/src/extras/core/ShapePath.d.ts b/src/extras/core/ShapePath.d.ts deleted file mode 100644 index 801b1dad548c0b..00000000000000 --- a/src/extras/core/ShapePath.d.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { Shape } from './Shape'; -import { Color } from '../../math/Color'; - -export class ShapePath { - - constructor(); - - /** - * @default 'ShapePath' - */ - type: string; - - /** - * @default new THREE.Color() - */ - color: Color; - - /** - * @default [] - */ - subPaths: any[]; - - /** - * @default null - */ - currentPath: any; - - moveTo( x: number, y: number ): this; - lineTo( x: number, y: number ): this; - quadraticCurveTo( aCPx: number, aCPy: number, aX: number, aY: number ): this; - bezierCurveTo( - aCP1x: number, - aCP1y: number, - aCP2x: number, - aCP2y: number, - aX: number, - aY: number - ): this; - splineThru( pts: Vector2[] ): this; - toShapes( isCCW: boolean, noHoles?: boolean ): Shape[]; - -} diff --git a/src/extras/curves/ArcCurve.d.ts b/src/extras/curves/ArcCurve.d.ts deleted file mode 100644 index f4581542cdd6ff..00000000000000 --- a/src/extras/curves/ArcCurve.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { EllipseCurve } from './EllipseCurve'; -export class ArcCurve extends EllipseCurve { - - constructor( - aX: number, - aY: number, - aRadius: number, - aStartAngle: number, - aEndAngle: number, - aClockwise: boolean - ); - - /** - * @default 'ArcCurve' - */ - type: string; - -} diff --git a/src/extras/curves/CatmullRomCurve3.d.ts b/src/extras/curves/CatmullRomCurve3.d.ts deleted file mode 100644 index 0282bb9fe3f748..00000000000000 --- a/src/extras/curves/CatmullRomCurve3.d.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { Vector3 } from './../../math/Vector3'; -import { Curve } from './../core/Curve'; - -// Extras / Curves ///////////////////////////////////////////////////////////////////// -export namespace CurveUtils { - export function tangentQuadraticBezier( - t: number, - p0: number, - p1: number, - p2: number - ): number; - export function tangentCubicBezier( - t: number, - p0: number, - p1: number, - p2: number, - p3: number - ): number; - export function tangentSpline( - t: number, - p0: number, - p1: number, - p2: number, - p3: number - ): number; - export function interpolate( - p0: number, - p1: number, - p2: number, - p3: number, - t: number - ): number; -} - -export class CatmullRomCurve3 extends Curve { - - /** - * @param [points=[]] - * @param [closed=false] - * @param [curveType='centripetal'] - * @param [tension=0.5] - */ - constructor( - points?: Vector3[], - closed?: boolean, - curveType?: string, - tension?: number - ); - - /** - * @default 'CatmullRomCurve3' - */ - type: string; - - /** - * @default [] - */ - points: Vector3[]; - -} diff --git a/src/extras/curves/CubicBezierCurve.d.ts b/src/extras/curves/CubicBezierCurve.d.ts deleted file mode 100644 index 61ac4d34c2bdb6..00000000000000 --- a/src/extras/curves/CubicBezierCurve.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { Curve } from './../core/Curve'; - -export class CubicBezierCurve extends Curve { - - constructor( v0: Vector2, v1: Vector2, v2: Vector2, v3: Vector2 ); - - /** - * @default 'CubicBezierCurve' - */ - type: string; - - /** - * @default new THREE.Vector2() - */ - v0: Vector2; - - /** - * @default new THREE.Vector2() - */ - v1: Vector2; - - /** - * @default new THREE.Vector2() - */ - v2: Vector2; - - /** - * @default new THREE.Vector2() - */ - v3: Vector2; - -} diff --git a/src/extras/curves/CubicBezierCurve3.d.ts b/src/extras/curves/CubicBezierCurve3.d.ts deleted file mode 100644 index bb7972fae6a944..00000000000000 --- a/src/extras/curves/CubicBezierCurve3.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Vector3 } from './../../math/Vector3'; -import { Curve } from './../core/Curve'; - -export class CubicBezierCurve3 extends Curve { - - constructor( v0: Vector3, v1: Vector3, v2: Vector3, v3: Vector3 ); - - /** - * @default 'CubicBezierCurve3' - */ - type: string; - - /** - * @default new THREE.Vector3() - */ - v0: Vector3; - - /** - * @default new THREE.Vector3() - */ - v1: Vector3; - - /** - * @default new THREE.Vector3() - */ - v2: Vector3; - - /** - * @default new THREE.Vector3() - */ - v3: Vector3; - -} diff --git a/src/extras/curves/Curves.d.ts b/src/extras/curves/Curves.d.ts deleted file mode 100644 index e89592bc676cff..00000000000000 --- a/src/extras/curves/Curves.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -export * from './ArcCurve'; -export * from './CatmullRomCurve3'; -export * from './CubicBezierCurve'; -export * from './CubicBezierCurve3'; -export * from './EllipseCurve'; -export * from './LineCurve'; -export * from './LineCurve3'; -export * from './QuadraticBezierCurve'; -export * from './QuadraticBezierCurve3'; -export * from './SplineCurve'; diff --git a/src/extras/curves/EllipseCurve.d.ts b/src/extras/curves/EllipseCurve.d.ts deleted file mode 100644 index 2a642c41157c21..00000000000000 --- a/src/extras/curves/EllipseCurve.d.ts +++ /dev/null @@ -1,62 +0,0 @@ -import { Curve } from './../core/Curve'; -import { Vector2 } from '../../math/Vector2'; - -export class EllipseCurve extends Curve { - - constructor( - aX: number, - aY: number, - xRadius: number, - yRadius: number, - aStartAngle: number, - aEndAngle: number, - aClockwise: boolean, - aRotation: number - ); - - /** - * @default 'EllipseCurve' - */ - type: string; - - /** - * @default 0 - */ - aX: number; - - /** - * @default 0 - */ - aY: number; - - /** - * @default 1 - */ - xRadius: number; - - /** - * @default 1 - */ - yRadius: number; - - /** - * @default 0 - */ - aStartAngle: number; - - /** - * @default 2 * Math.PI - */ - aEndAngle: number; - - /** - * @default false - */ - aClockwise: boolean; - - /** - * @default 0 - */ - aRotation: number; - -} diff --git a/src/extras/curves/LineCurve.d.ts b/src/extras/curves/LineCurve.d.ts deleted file mode 100644 index b3d278892c1dd1..00000000000000 --- a/src/extras/curves/LineCurve.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { Curve } from './../core/Curve'; - -export class LineCurve extends Curve { - - constructor( v1: Vector2, v2: Vector2 ); - - /** - * @default 'LineCurve' - */ - type: string; - - - /** - * @default new THREE.Vector2() - */ - v1: Vector2; - - /** - * @default new THREE.Vector2() - */ - v2: Vector2; - -} diff --git a/src/extras/curves/LineCurve3.d.ts b/src/extras/curves/LineCurve3.d.ts deleted file mode 100644 index 58a67b57ecaec2..00000000000000 --- a/src/extras/curves/LineCurve3.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Vector3 } from './../../math/Vector3'; -import { Curve } from './../core/Curve'; - -export class LineCurve3 extends Curve { - - constructor( v1: Vector3, v2: Vector3 ); - - /** - * @default 'LineCurve3' - */ - type: string; - - - /** - * @default new THREE.Vector3() - */ - v1: Vector3; - - /** - * @default new THREE.Vector3() - */ - v2: Vector3; - -} diff --git a/src/extras/curves/QuadraticBezierCurve.d.ts b/src/extras/curves/QuadraticBezierCurve.d.ts deleted file mode 100644 index ef4baef6876aa0..00000000000000 --- a/src/extras/curves/QuadraticBezierCurve.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { Curve } from './../core/Curve'; - -export class QuadraticBezierCurve extends Curve { - - constructor( v0: Vector2, v1: Vector2, v2: Vector2 ); - - /** - * @default 'QuadraticBezierCurve' - */ - type: string; - - /** - * @default new THREE.Vector2() - */ - v0: Vector2; - - /** - * @default new THREE.Vector2() - */ - v1: Vector2; - - /** - * @default new THREE.Vector2() - */ - v2: Vector2; - -} diff --git a/src/extras/curves/QuadraticBezierCurve3.d.ts b/src/extras/curves/QuadraticBezierCurve3.d.ts deleted file mode 100644 index 4d1abc7151edee..00000000000000 --- a/src/extras/curves/QuadraticBezierCurve3.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Vector3 } from './../../math/Vector3'; -import { Curve } from './../core/Curve'; - -export class QuadraticBezierCurve3 extends Curve { - - constructor( v0: Vector3, v1: Vector3, v2: Vector3 ); - - /** - * @default 'QuadraticBezierCurve3' - */ - type: string; - - /** - * @default new THREE.Vector3() - */ - v0: Vector3; - - /** - * @default new THREE.Vector3() - */ - v1: Vector3; - - /** - * @default new THREE.Vector3() - */ - v2: Vector3; - -} diff --git a/src/extras/curves/SplineCurve.d.ts b/src/extras/curves/SplineCurve.d.ts deleted file mode 100644 index f980df3469a0c7..00000000000000 --- a/src/extras/curves/SplineCurve.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Vector2 } from './../../math/Vector2'; -import { Curve } from './../core/Curve'; - -export class SplineCurve extends Curve { - - constructor( points?: Vector2[] ); - - /** - * @default 'SplineCurve' - */ - type: string; - - /** - * @default [] - */ - points: Vector2[]; - -} diff --git a/src/extras/objects/ImmediateRenderObject.d.ts b/src/extras/objects/ImmediateRenderObject.d.ts deleted file mode 100644 index b56d89e6b698c8..00000000000000 --- a/src/extras/objects/ImmediateRenderObject.d.ts +++ /dev/null @@ -1,61 +0,0 @@ -import { Object3D } from './../../core/Object3D'; -import { Material } from './../../materials/Material'; - -// Extras / Objects ///////////////////////////////////////////////////////////////////// - -export class ImmediateRenderObject extends Object3D { - - constructor( material: Material ); - - readonly isImmediateRenderObject: true; - - material: Material; - - /** - * @default false - */ - hasPositions: boolean; - - /** - * @default false - */ - hasNormals: boolean; - - /** - * @default false - */ - hasColors: boolean; - - /** - * @default false - */ - hasUvs: boolean; - - /** - * @default null - */ - positionArray: null | Float32Array; - - /** - * @default null - */ - normalArray: null | Float32Array; - - /** - * @default null - */ - colorArray: null | Float32Array; - - /** - * @default null - */ - uvArray: null | Float32Array; - - /** - * @default 0 - */ - count: number; - - render( renderCallback: Function ): void; - -} diff --git a/src/geometries/BoxGeometry.d.ts b/src/geometries/BoxGeometry.d.ts deleted file mode 100644 index cb76a971621a26..00000000000000 --- a/src/geometries/BoxGeometry.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { BufferGeometry } from '../core/BufferGeometry'; - -export class BoxGeometry extends BufferGeometry { - - /** - * @param [width=1] — Width of the sides on the X axis. - * @param [height=1] — Height of the sides on the Y axis. - * @param [depth=1] — Depth of the sides on the Z axis. - * @param [widthSegments=1] — Number of segmented faces along the width of the sides. - * @param [heightSegments=1] — Number of segmented faces along the height of the sides. - * @param [depthSegments=1] — Number of segmented faces along the depth of the sides. - */ - constructor( - width?: number, - height?: number, - depth?: number, - widthSegments?: number, - heightSegments?: number, - depthSegments?: number - ); - - /** - * @default 'BoxGeometry' - */ - type: string; - - parameters: { - width: number; - height: number; - depth: number; - widthSegments: number; - heightSegments: number; - depthSegments: number; - }; - -} - -export { BoxGeometry as BoxBufferGeometry }; diff --git a/src/geometries/CircleGeometry.d.ts b/src/geometries/CircleGeometry.d.ts deleted file mode 100644 index f2701308cded3b..00000000000000 --- a/src/geometries/CircleGeometry.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { BufferGeometry } from '../core/BufferGeometry'; - -export class CircleGeometry extends BufferGeometry { - - /** - * @param [radius=1] - * @param [segments=8] - * @param [thetaStart=0] - * @param [thetaLength=Math.PI * 2] - */ - constructor( - radius?: number, - segments?: number, - thetaStart?: number, - thetaLength?: number - ); - - /** - * @default 'CircleGeometry' - */ - type: string; - - parameters: { - radius: number; - segments: number; - thetaStart: number; - thetaLength: number; - }; - -} - -export { CircleGeometry as CircleBufferGeometry }; diff --git a/src/geometries/ConeGeometry.d.ts b/src/geometries/ConeGeometry.d.ts deleted file mode 100644 index 8eebea5075aa97..00000000000000 --- a/src/geometries/ConeGeometry.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { CylinderGeometry } from './CylinderGeometry'; - -export class ConeGeometry extends CylinderGeometry { - - /** - * @param [radius=1] — Radius of the cone base. - * @param [height=1] — Height of the cone. - * @param [radialSegments=8] — Number of segmented faces around the circumference of the cone. - * @param [heightSegments=1] — Number of rows of faces along the height of the cone. - * @param [openEnded=false] — A Boolean indicating whether the base of the cone is open or capped. - * @param [thetaStart=0] - * @param [thetaLength=Math.PI * 2] - */ - constructor( - radius?: number, - height?: number, - radialSegments?: number, - heightSegments?: number, - openEnded?: boolean, - thetaStart?: number, - thetaLength?: number - ); - - /** - * @default 'ConeGeometry' - */ - type: string; - -} - -export { ConeGeometry as ConeBufferGeometry }; diff --git a/src/geometries/CylinderGeometry.d.ts b/src/geometries/CylinderGeometry.d.ts deleted file mode 100644 index 96ce4c1d23d9b0..00000000000000 --- a/src/geometries/CylinderGeometry.d.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { BufferGeometry } from '../core/BufferGeometry'; - -export class CylinderGeometry extends BufferGeometry { - - /** - * @param [radiusTop=1] — Radius of the cylinder at the top. - * @param [radiusBottom=1] — Radius of the cylinder at the bottom. - * @param [height=1] — Height of the cylinder. - * @param [radialSegments=8] — Number of segmented faces around the circumference of the cylinder. - * @param [heightSegments=1] — Number of rows of faces along the height of the cylinder. - * @param [openEnded=false] - A Boolean indicating whether or not to cap the ends of the cylinder. - * @param [thetaStart=0] - * @param [thetaLength=Math.PI * 2] - */ - constructor( - radiusTop?: number, - radiusBottom?: number, - height?: number, - radialSegments?: number, - heightSegments?: number, - openEnded?: boolean, - thetaStart?: number, - thetaLength?: number - ); - - /** - * @default 'CylinderGeometry' - */ - type: string; - - parameters: { - radiusTop: number; - radiusBottom: number; - height: number; - radialSegments: number; - heightSegments: number; - openEnded: boolean; - thetaStart: number; - thetaLength: number; - }; - -} - -export { CylinderGeometry as CylinderBufferGeometry }; diff --git a/src/geometries/DodecahedronGeometry.d.ts b/src/geometries/DodecahedronGeometry.d.ts deleted file mode 100644 index f15af76b92c1eb..00000000000000 --- a/src/geometries/DodecahedronGeometry.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { PolyhedronGeometry } from './PolyhedronGeometry'; - -export class DodecahedronGeometry extends PolyhedronGeometry { - - /** - * @param [radius=1] - * @param [detail=0] - */ - constructor( radius?: number, detail?: number ); - - /** - * @default 'DodecahedronGeometry' - */ - type: string; - -} - -export { DodecahedronGeometry as DodecahedronBufferGeometry }; diff --git a/src/geometries/EdgesGeometry.d.ts b/src/geometries/EdgesGeometry.d.ts deleted file mode 100644 index 956287a284325a..00000000000000 --- a/src/geometries/EdgesGeometry.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { BufferGeometry } from '../core/BufferGeometry'; - -export class EdgesGeometry extends BufferGeometry { - - /** - * @param geometry - * @param [thresholdAngle=1] - */ - constructor( geometry: BufferGeometry, thresholdAngle?: number ); - - /** - * @default 'EdgesGeometry' - */ - type: string; - - parameters: { - thresholdAngle: number; - }; - -} diff --git a/src/geometries/ExtrudeGeometry.d.ts b/src/geometries/ExtrudeGeometry.d.ts deleted file mode 100644 index 16ba82b3c30654..00000000000000 --- a/src/geometries/ExtrudeGeometry.d.ts +++ /dev/null @@ -1,73 +0,0 @@ -import { Curve } from './../extras/core/Curve'; -import { Vector2 } from './../math/Vector2'; -import { Vector3 } from './../math/Vector3'; -import { Shape } from './../extras/core/Shape'; -import { BufferGeometry } from './../core/BufferGeometry'; - -export interface ExtrudeGeometryOptions { - /** - * @default 12 - */ - curveSegments?: number; - /** - * @default 1 - */ - steps?: number; - /** - * @default 100 - */ - depth?: number; - /** - * @default true - */ - bevelEnabled?: boolean; - /** - * @default 6 - */ - bevelThickness?: number; - bevelSize?: number; - /** - * @default 0 - */ - bevelOffset?: number; - /** - * @default 3 - */ - bevelSegments?: number; - extrudePath?: Curve; - UVGenerator?: UVGenerator; -} - -export interface UVGenerator { - generateTopUV( - geometry: ExtrudeGeometry, - vertices: number[], - indexA: number, - indexB: number, - indexC: number - ): Vector2[]; - generateSideWallUV( - geometry: ExtrudeGeometry, - vertices: number[], - indexA: number, - indexB: number, - indexC: number, - indexD: number - ): Vector2[]; -} - -export class ExtrudeGeometry extends BufferGeometry { - - constructor( shapes: Shape | Shape[], options?: ExtrudeGeometryOptions ); - - /** - * @default 'ExtrudeGeometry' - */ - type: string; - - addShapeList( shapes: Shape[], options?: any ): void; - addShape( shape: Shape, options?: any ): void; - -} - -export { ExtrudeGeometry as ExtrudeBufferGeometry }; diff --git a/src/geometries/Geometries.d.ts b/src/geometries/Geometries.d.ts deleted file mode 100644 index 5fc2b2f627dd8e..00000000000000 --- a/src/geometries/Geometries.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -export * from './BoxGeometry'; -export * from './CircleGeometry'; -export * from './ConeGeometry'; -export * from './CylinderGeometry'; -export * from './DodecahedronGeometry'; -export * from './EdgesGeometry'; -export * from './ExtrudeGeometry'; -export * from './IcosahedronGeometry'; -export * from './LatheGeometry'; -export * from './OctahedronGeometry'; -export * from './ParametricGeometry'; -export * from './PlaneGeometry'; -export * from './PolyhedronGeometry'; -export * from './RingGeometry'; -export * from './ShapeGeometry'; -export * from './SphereGeometry'; -export * from './TetrahedronGeometry'; -export * from './TextGeometry'; -export * from './TorusGeometry'; -export * from './TorusKnotGeometry'; -export * from './TubeGeometry'; -export * from './WireframeGeometry'; diff --git a/src/geometries/IcosahedronGeometry.d.ts b/src/geometries/IcosahedronGeometry.d.ts deleted file mode 100644 index 57072405335f28..00000000000000 --- a/src/geometries/IcosahedronGeometry.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { PolyhedronGeometry } from './PolyhedronGeometry'; - -export class IcosahedronGeometry extends PolyhedronGeometry { - - /** - * @param [radius=1] - * @param [detail=0] - */ - constructor( radius?: number, detail?: number ); - - /** - * @default 'IcosahedronGeometry' - */ - type: string; - -} - -export { IcosahedronGeometry as IcosahedronBufferGeometry }; diff --git a/src/geometries/LatheGeometry.d.ts b/src/geometries/LatheGeometry.d.ts deleted file mode 100644 index 6598369bf004ea..00000000000000 --- a/src/geometries/LatheGeometry.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Vector2 } from './../math/Vector2'; -import { BufferGeometry } from './../core/BufferGeometry'; - -export class LatheGeometry extends BufferGeometry { - - /** - * @param points - * @param [segments=12] - * @param [phiStart=0] - * @param [phiLength=Math.PI * 2] - */ - constructor( - points: Vector2[], - segments?: number, - phiStart?: number, - phiLength?: number - ); - - /** - * @default 'LatheGeometry' - */ - type: string; - - parameters: { - points: Vector2[]; - segments: number; - phiStart: number; - phiLength: number; - }; - -} - -export { LatheGeometry as LatheBufferGeometry }; diff --git a/src/geometries/OctahedronGeometry.d.ts b/src/geometries/OctahedronGeometry.d.ts deleted file mode 100644 index 67ac4b34a06a1d..00000000000000 --- a/src/geometries/OctahedronGeometry.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { PolyhedronGeometry } from './PolyhedronGeometry'; - -export class OctahedronGeometry extends PolyhedronGeometry { - - /** - * @param [radius=1] - * @param [detail=0] - */ - constructor( radius?: number, detail?: number ); - - /** - * @default 'OctahedronGeometry' - */ - type: string; - -} - -export { OctahedronGeometry as OctahedronBufferGeometry }; diff --git a/src/geometries/ParametricGeometry.d.ts b/src/geometries/ParametricGeometry.d.ts deleted file mode 100644 index 34c6d9a88bbe2c..00000000000000 --- a/src/geometries/ParametricGeometry.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { Vector3 } from './../math/Vector3'; -import { BufferGeometry } from './../core/BufferGeometry'; - -export class ParametricGeometry extends BufferGeometry { - - constructor( - func: ( u: number, v: number, dest: Vector3 ) => void, - slices: number, - stacks: number - ); - - /** - * @default 'ParametricGeometry' - */ - type: string; - - parameters: { - func: ( u: number, v: number, dest: Vector3 ) => void; - slices: number; - stacks: number; - }; - -} - -export { ParametricGeometry as ParametricBufferGeometry }; diff --git a/src/geometries/PlaneGeometry.d.ts b/src/geometries/PlaneGeometry.d.ts deleted file mode 100644 index c0070bdc141a61..00000000000000 --- a/src/geometries/PlaneGeometry.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class PlaneGeometry extends BufferGeometry { - - /** - * @param [width=1] — Width of the sides on the X axis. - * @param [height=1] — Height of the sides on the Y axis. - * @param [widthSegments=1] — Number of segmented faces along the width of the sides. - * @param [heightSegments=1] — Number of segmented faces along the height of the sides. - */ - constructor( - width?: number, - height?: number, - widthSegments?: number, - heightSegments?: number - ); - - /** - * @default 'PlaneGeometry' - */ - type: string; - - parameters: { - width: number; - height: number; - widthSegments: number; - heightSegments: number; - }; - -} - -export { PlaneGeometry as PlaneBufferGeometry }; diff --git a/src/geometries/PolyhedronGeometry.d.ts b/src/geometries/PolyhedronGeometry.d.ts deleted file mode 100644 index c6003cb8e83a65..00000000000000 --- a/src/geometries/PolyhedronGeometry.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class PolyhedronGeometry extends BufferGeometry { - - /** - * @param vertices - * @param indices - * @param [radius=1] - * @param [detail=0] - */ - constructor( - vertices: number[], - indices: number[], - radius?: number, - detail?: number - ); - - /** - * @default 'PolyhedronGeometry' - */ - type: string; - - parameters: { - vertices: number[]; - indices: number[]; - radius: number; - detail: number; - }; - -} - -export { PolyhedronGeometry as PolyhedronBufferGeometry }; diff --git a/src/geometries/RingGeometry.d.ts b/src/geometries/RingGeometry.d.ts deleted file mode 100644 index e4fcd978f3fdbf..00000000000000 --- a/src/geometries/RingGeometry.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class RingGeometry extends BufferGeometry { - - /** - * @param [innerRadius=0.5] - * @param [outerRadius=1] - * @param [thetaSegments=8] - * @param [phiSegments=1] - * @param [thetaStart=0] - * @param [thetaLength=Math.PI * 2] - */ - constructor( - innerRadius?: number, - outerRadius?: number, - thetaSegments?: number, - phiSegments?: number, - thetaStart?: number, - thetaLength?: number - ); - - /** - * @default 'RingGeometry' - */ - type: string; - - parameters: { - innerRadius: number; - outerRadius: number; - thetaSegments: number; - phiSegments: number; - thetaStart: number; - thetaLength: number; - }; - -} - -export { RingGeometry as RingBufferGeometry }; diff --git a/src/geometries/ShapeGeometry.d.ts b/src/geometries/ShapeGeometry.d.ts deleted file mode 100644 index 520185a4ec78c3..00000000000000 --- a/src/geometries/ShapeGeometry.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { Shape } from './../extras/core/Shape'; -import { BufferGeometry } from './../core/BufferGeometry'; - -export class ShapeGeometry extends BufferGeometry { - - /** - * @default 'ShapShapeGeometryeBufferGeometry' - */ - type: string; - - constructor( shapes: Shape | Shape[], curveSegments?: number ); - -} - -export { ShapeGeometry as ShapeBufferGeometry }; diff --git a/src/geometries/SphereGeometry.d.ts b/src/geometries/SphereGeometry.d.ts deleted file mode 100644 index b1cb3270188d4a..00000000000000 --- a/src/geometries/SphereGeometry.d.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class SphereGeometry extends BufferGeometry { - - /** - * @param [radius=50] — sphere radius. Default is 50. - * @param [widthSegments=8] — number of horizontal segments. Minimum value is 3, and the default is 8. - * @param [heightSegments=6] — number of vertical segments. Minimum value is 2, and the default is 6. - * @param [phiStart=0] — specify horizontal starting angle. Default is 0. - * @param [phiLength=Math.PI * 2] — specify horizontal sweep angle size. Default is Math.PI * 2. - * @param [thetaStart=0] — specify vertical starting angle. Default is 0. - * @param [thetaLength=Math.PI * 2] — specify vertical sweep angle size. Default is Math.PI. - */ - constructor( - radius?: number, - widthSegments?: number, - heightSegments?: number, - phiStart?: number, - phiLength?: number, - thetaStart?: number, - thetaLength?: number - ); - - /** - * @default 'SphereGeometry' - */ - type: string; - - parameters: { - radius: number; - widthSegments: number; - heightSegments: number; - phiStart: number; - phiLength: number; - thetaStart: number; - thetaLength: number; - }; - -} - -export { SphereGeometry as SphereBufferGeometry }; diff --git a/src/geometries/TetrahedronGeometry.d.ts b/src/geometries/TetrahedronGeometry.d.ts deleted file mode 100644 index 4bbee06fe29649..00000000000000 --- a/src/geometries/TetrahedronGeometry.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { PolyhedronGeometry } from './PolyhedronGeometry'; - -export class TetrahedronGeometry extends PolyhedronGeometry { - - /** - * @param [radius=1] - * @param [detail=0] - */ - constructor( radius?: number, detail?: number ); - - /** - * @default 'TetrahedronGeometry' - */ - type: string; - -} - -export { TetrahedronGeometry as TetrahedronBufferGeometry }; diff --git a/src/geometries/TextGeometry.d.ts b/src/geometries/TextGeometry.d.ts deleted file mode 100644 index aff2388d5e7a62..00000000000000 --- a/src/geometries/TextGeometry.d.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Font } from './../extras/core/Font'; -import { ExtrudeGeometry } from './ExtrudeGeometry'; - -export interface TextGeometryParameters { - font: Font; - size?: number; - height?: number; - curveSegments?: number; - bevelEnabled?: boolean; - bevelThickness?: number; - bevelSize?: number; - bevelOffset?: number; - bevelSegments?: number; -} - -export class TextGeometry extends ExtrudeGeometry { - - /** - * @default 'TextGeometry' - */ - type: string; - - constructor( text: string, parameters: TextGeometryParameters ); - - parameters: { - font: Font; - size: number; - height: number; - curveSegments: number; - bevelEnabled: boolean; - bevelThickness: number; - bevelSize: number; - bevelOffset: number; - bevelSegments: number; - }; - -} - -export { TextGeometry as TextBufferGeometry }; diff --git a/src/geometries/TorusGeometry.d.ts b/src/geometries/TorusGeometry.d.ts deleted file mode 100644 index b1f14b9d8873c2..00000000000000 --- a/src/geometries/TorusGeometry.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class TorusGeometry extends BufferGeometry { - - /** - * @param [radius=1] - * @param [tube=0.4] - * @param [radialSegments=8] - * @param [tubularSegments=6] - * @param [arc=Math.PI * 2] - */ - constructor( - radius?: number, - tube?: number, - radialSegments?: number, - tubularSegments?: number, - arc?: number - ); - - /** - * @default 'TorusGeometry' - */ - type: string; - - parameters: { - radius: number; - tube: number; - radialSegments: number; - tubularSegments: number; - arc: number; - }; - -} - -export { TorusGeometry as TorusBufferGeometry }; diff --git a/src/geometries/TorusKnotGeometry.d.ts b/src/geometries/TorusKnotGeometry.d.ts deleted file mode 100644 index d9638a034efeaa..00000000000000 --- a/src/geometries/TorusKnotGeometry.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class TorusKnotGeometry extends BufferGeometry { - - /** - * @param [radius=1] - * @param [tube=0.4] - * @param [radialSegments=64] - * @param [tubularSegments=8] - * @param [p=2] - * @param [q=3] - */ - constructor( - radius?: number, - tube?: number, - tubularSegments?: number, - radialSegments?: number, - p?: number, - q?: number - ); - - /** - * @default 'TorusKnotGeometry' - */ - type: string; - - parameters: { - radius: number; - tube: number; - tubularSegments: number; - radialSegments: number; - p: number; - q: number; - }; - -} - -export { TorusKnotGeometry as TorusKnotBufferGeometry }; diff --git a/src/geometries/TubeGeometry.d.ts b/src/geometries/TubeGeometry.d.ts deleted file mode 100644 index 14d636a0b1dd82..00000000000000 --- a/src/geometries/TubeGeometry.d.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { Curve } from './../extras/core/Curve'; -import { Vector3 } from './../math/Vector3'; -import { BufferGeometry } from './../core/BufferGeometry'; - -export class TubeGeometry extends BufferGeometry { - - /** - * @param path - * @param [tubularSegments=64] - * @param [radius=1] - * @param [radiusSegments=8] - * @param [closed=false] - */ - constructor( - path: Curve, - tubularSegments?: number, - radius?: number, - radiusSegments?: number, - closed?: boolean - ); - - /** - * @default 'TubeGeometry' - */ - type: string; - - parameters: { - path: Curve; - tubularSegments: number; - radius: number; - radialSegments: number; - closed: boolean; - }; - tangents: Vector3[]; - normals: Vector3[]; - binormals: Vector3[]; - -} - -export { TubeGeometry as TubeBufferGeometry }; diff --git a/src/geometries/WireframeGeometry.d.ts b/src/geometries/WireframeGeometry.d.ts deleted file mode 100644 index 064295cd929816..00000000000000 --- a/src/geometries/WireframeGeometry.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { BufferGeometry } from './../core/BufferGeometry'; - -export class WireframeGeometry extends BufferGeometry { - - constructor( geometry: BufferGeometry ); - - /** - * @default 'WireframeGeometry' - */ - type: string; - -} diff --git a/src/helpers/ArrowHelper.d.ts b/src/helpers/ArrowHelper.d.ts deleted file mode 100644 index 494aafe6a9b245..00000000000000 --- a/src/helpers/ArrowHelper.d.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { Vector3 } from './../math/Vector3'; -import { Line } from './../objects/Line'; -import { Mesh } from './../objects/Mesh'; -import { Color } from './../math/Color'; -import { Object3D } from './../core/Object3D'; - -// Extras / Helpers ///////////////////////////////////////////////////////////////////// - -export class ArrowHelper extends Object3D { - - /** - * @param [dir=new THREE.Vector3( 0, 0, 1 )] - * @param [origin=new THREE.Vector3( 0, 0, 0 )] - * @param [length=1] - * @param [color=0xffff00] - * @param headLength - * @param headWidth - */ - constructor( - dir: Vector3, - origin?: Vector3, - length?: number, - color?: Color | string | number, - headLength?: number, - headWidth?: number - ); - - /** - * @default 'ArrowHelper' - */ - type: string; - - line: Line; - cone: Mesh; - - setDirection( dir: Vector3 ): void; - setLength( length: number, headLength?: number, headWidth?: number ): void; - setColor( color: Color | string | number ): void; - -} diff --git a/src/helpers/AxesHelper.d.ts b/src/helpers/AxesHelper.d.ts deleted file mode 100644 index 1d38ac3514b791..00000000000000 --- a/src/helpers/AxesHelper.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { LineSegments } from './../objects/LineSegments'; - -export class AxesHelper extends LineSegments { - - /** - * @param [size=1] - */ - constructor( size?: number ); - - /** - * @default 'AxesHelper' - */ - type: string; - -} diff --git a/src/helpers/Box3Helper.d.ts b/src/helpers/Box3Helper.d.ts deleted file mode 100644 index be3de578338341..00000000000000 --- a/src/helpers/Box3Helper.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { Box3 } from './../math/Box3'; -import { Color } from './../math/Color'; -import { LineSegments } from './../objects/LineSegments'; - -export class Box3Helper extends LineSegments { - - /** - * @param box - * @param [color=0xffff00] - */ - constructor( box: Box3, color?: Color ); - - /** - * @default 'Box3Helper' - */ - type: string; - - box: Box3; - -} diff --git a/src/helpers/BoxHelper.d.ts b/src/helpers/BoxHelper.d.ts deleted file mode 100644 index 6c5b6d8657aa1f..00000000000000 --- a/src/helpers/BoxHelper.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { Object3D } from './../core/Object3D'; -import { Color } from './../math/Color'; -import { LineSegments } from './../objects/LineSegments'; - -export class BoxHelper extends LineSegments { - - /** - * @param object - * @param [color=0xffff00] - */ - constructor( object: Object3D, color?: Color | string | number ); - - /** - * @default 'BoxHelper' - */ - type: string; - - update( object?: Object3D ): void; - - setFromObject( object: Object3D ): this; - -} diff --git a/src/helpers/CameraHelper.d.ts b/src/helpers/CameraHelper.d.ts deleted file mode 100644 index b6477d5ba21fb6..00000000000000 --- a/src/helpers/CameraHelper.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Camera } from './../cameras/Camera'; -import { LineSegments } from './../objects/LineSegments'; - -export class CameraHelper extends LineSegments { - - constructor( camera: Camera ); - - camera: Camera; - pointMap: { [id: string]: number[] }; - - /** - * @default 'CameraHelper' - */ - type: string; - - update(): void; - -} diff --git a/src/helpers/DirectionalLightHelper.d.ts b/src/helpers/DirectionalLightHelper.d.ts deleted file mode 100644 index 32bd590483d295..00000000000000 --- a/src/helpers/DirectionalLightHelper.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { DirectionalLight } from './../lights/DirectionalLight'; -import { Color } from './../math/Color'; -import { Line } from './../objects/Line'; -import { Matrix4 } from './../math/Matrix4'; -import { Object3D } from './../core/Object3D'; - -export class DirectionalLightHelper extends Object3D { - - /** - * @param light - * @param [size=1] - * @param color - */ - constructor( - light: DirectionalLight, - size?: number, - color?: Color | string | number - ); - - light: DirectionalLight; - lightPlane: Line; - targetLine: Line; - - /** - * @default undefined - */ - color: Color | string | number | undefined; - matrix: Matrix4; - - /** - * @default false - */ - matrixAutoUpdate: boolean; - - dispose(): void; - update(): void; - -} diff --git a/src/helpers/GridHelper.d.ts b/src/helpers/GridHelper.d.ts deleted file mode 100644 index 1b19c098608955..00000000000000 --- a/src/helpers/GridHelper.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { Color } from './../math/Color'; -import { LineSegments } from './../objects/LineSegments'; - -export class GridHelper extends LineSegments { - - /** - * @param [size=10] - * @param [divisions=10] - * @param [color1=0x444444] - * @param [color2=0x888888] - */ - constructor( - size?: number, - divisions?: number, - color1?: Color | string | number, - color2?: Color | string | number - ); - - /** - * @default 'GridHelper' - */ - type: string; - - /** - * @deprecated Colors should be specified in the constructor. - */ - setColors( color1?: Color | string | number, color2?: Color | string | number ): void; - -} diff --git a/src/helpers/HemisphereLightHelper.d.ts b/src/helpers/HemisphereLightHelper.d.ts deleted file mode 100644 index 7d3ae8e2d41d6f..00000000000000 --- a/src/helpers/HemisphereLightHelper.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { HemisphereLight } from './../lights/HemisphereLight'; -import { Color } from './../math/Color'; -import { Matrix4 } from './../math/Matrix4'; -import { MeshBasicMaterial } from './../materials/MeshBasicMaterial'; -import { Object3D } from './../core/Object3D'; - -export class HemisphereLightHelper extends Object3D { - - constructor( - light: HemisphereLight, - size: number, - color?: Color | number | string - ); - - light: HemisphereLight; - matrix: Matrix4; - matrixAutoUpdate: boolean; - material: MeshBasicMaterial; - - color: Color | string | number | undefined; - - dispose(): void; - update(): void; - -} diff --git a/src/helpers/PlaneHelper.d.ts b/src/helpers/PlaneHelper.d.ts deleted file mode 100644 index ab23c920361189..00000000000000 --- a/src/helpers/PlaneHelper.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { Plane } from './../math/Plane'; -import { LineSegments } from './../objects/LineSegments'; - -export class PlaneHelper extends LineSegments { - - /** - * @param plane - * @param [size=1] - * @param [hex=0xffff00] - */ - constructor( plane: Plane, size?: number, hex?: number ); - - /** - * @default 'PlaneHelper' - */ - type: string; - - plane: Plane; - - /** - * @default 1 - */ - size: number; - - updateMatrixWorld( force?: boolean ): void; - -} diff --git a/src/helpers/PointLightHelper.d.ts b/src/helpers/PointLightHelper.d.ts deleted file mode 100644 index ffd041c5bacea8..00000000000000 --- a/src/helpers/PointLightHelper.d.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { PointLight } from './../lights/PointLight'; -import { Color } from './../math/Color'; -import { Matrix4 } from './../math/Matrix4'; -import { Object3D } from './../core/Object3D'; - -export class PointLightHelper extends Object3D { - - constructor( - light: PointLight, - sphereSize?: number, - color?: Color | string | number - ); - - /** - * @default 'PointLightHelper' - */ - type: string; - - light: PointLight; - color: Color | string | number | undefined; - matrix: Matrix4; - - /** - * @default false - */ - matrixAutoUpdate: boolean; - - dispose(): void; - update(): void; - -} diff --git a/src/helpers/PolarGridHelper.d.ts b/src/helpers/PolarGridHelper.d.ts deleted file mode 100644 index b0d3419ad02011..00000000000000 --- a/src/helpers/PolarGridHelper.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { LineSegments } from '../objects/LineSegments'; -import { Color } from '../math/Color'; - -export class PolarGridHelper extends LineSegments { - - /** - * @param [radius=10] - * @param [radials=16] - * @param [circles=8] - * @param [divisions=64] - * @param [color1=0x444444] - * @param [color2=0x888888] - */ - constructor( - radius: number, - radials: number, - circles: number, - divisions: number, - color1: Color | string | number | undefined, - color2: Color | string | number | undefined - ); - - /** - * @default 'PolarGridHelper' - */ - type: string; - -} diff --git a/src/helpers/SkeletonHelper.d.ts b/src/helpers/SkeletonHelper.d.ts deleted file mode 100644 index e0b66221a2e031..00000000000000 --- a/src/helpers/SkeletonHelper.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { Object3D } from './../core/Object3D'; -import { Matrix4 } from './../math/Matrix4'; -import { Bone } from './../objects/Bone'; -import { LineSegments } from './../objects/LineSegments'; - -export class SkeletonHelper extends LineSegments { - - constructor( object: Object3D ); - - /** - * @default 'SkeletonHelper' - */ - type: string; - - bones: Bone[]; - root: Object3D; - - readonly isSkeletonHelper: true; - - matrix: Matrix4; - - /** - * @default false - */ - matrixAutoUpdate: boolean; - - getBoneList( object: Object3D ): Bone[]; - update(): void; - -} diff --git a/src/helpers/SpotLightHelper.d.ts b/src/helpers/SpotLightHelper.d.ts deleted file mode 100644 index 0df16c2dd45275..00000000000000 --- a/src/helpers/SpotLightHelper.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Light } from './../lights/Light'; -import { Color } from './../math/Color'; -import { Matrix4 } from './../math/Matrix4'; -import { Object3D } from './../core/Object3D'; -import { LineSegments } from '../objects/LineSegments'; - -export class SpotLightHelper extends Object3D { - - constructor( light: Light, color?: Color | string | number ); - - light: Light; - matrix: Matrix4; - - /** - * @default false - */ - matrixAutoUpdate: boolean; - color: Color | string | number | undefined; - cone: LineSegments; - - dispose(): void; - update(): void; - -} diff --git a/src/lights/AmbientLight.d.ts b/src/lights/AmbientLight.d.ts deleted file mode 100644 index aecff5887485aa..00000000000000 --- a/src/lights/AmbientLight.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { Color } from './../math/Color'; -import { Light } from './Light'; - -/** - * This light's color gets applied to all the objects in the scene globally. - * - * @source https://github.com/mrdoob/three.js/blob/master/src/lights/AmbientLight.js - */ -export class AmbientLight extends Light { - - /** - * This creates a Ambientlight with a color. - * @param color Numeric value of the RGB component of the color or a Color instance. - * @param [intensity=1] - */ - constructor( color?: Color | string | number, intensity?: number ); - - /** - * @default 'AmbientLight' - */ - type: string; - - readonly isAmbientLight: true; - -} diff --git a/src/lights/AmbientLightProbe.d.ts b/src/lights/AmbientLightProbe.d.ts deleted file mode 100644 index 9b10ca11e0ccb4..00000000000000 --- a/src/lights/AmbientLightProbe.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { Color } from './../math/Color'; -import { LightProbe } from './LightProbe'; - -export class AmbientLightProbe extends LightProbe { - - constructor( color?: Color | string | number, intensity?: number ); - - readonly isAmbientLightProbe: true; - -} diff --git a/src/lights/DirectionalLight.d.ts b/src/lights/DirectionalLight.d.ts deleted file mode 100644 index 8b5cc0878f36e2..00000000000000 --- a/src/lights/DirectionalLight.d.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Color } from './../math/Color'; -import { Object3D } from './../core/Object3D'; -import { DirectionalLightShadow } from './DirectionalLightShadow'; -import { Light } from './Light'; -import { Vector3 } from '../math/Vector3'; - -/** - * see {@link https://github.com/mrdoob/three.js/blob/master/src/lights/DirectionalLight.js|src/lights/DirectionalLight.js} - * - * @example - * // White directional light at half intensity shining from the top. - * const directionalLight = new THREE.DirectionalLight( 0xffffff, 0.5 ); - * directionalLight.position.set( 0, 1, 0 ); - * scene.add( directionalLight ); - */ -export class DirectionalLight extends Light { - - constructor( color?: Color | string | number, intensity?: number ); - - /** - * @default 'DirectionalLight' - */ - type: string; - - /** - * @default THREE.Object3D.DefaultUp - */ - position: Vector3; - - /** - * Target used for shadow camera orientation. - * @default new THREE.Object3D() - */ - target: Object3D; - - /** - * Light's intensity. - * @default 1 - */ - intensity: number; - - /** - * @default new THREE.DirectionalLightShadow() - */ - shadow: DirectionalLightShadow; - readonly isDirectionalLight: true; - -} diff --git a/src/lights/DirectionalLightShadow.d.ts b/src/lights/DirectionalLightShadow.d.ts deleted file mode 100644 index 458483dd94dd65..00000000000000 --- a/src/lights/DirectionalLightShadow.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { OrthographicCamera } from './../cameras/OrthographicCamera'; -import { LightShadow } from './LightShadow'; - -export class DirectionalLightShadow extends LightShadow { - - camera: OrthographicCamera; - readonly isDirectionalLightShadow: true; - -} diff --git a/src/lights/HemisphereLight.d.ts b/src/lights/HemisphereLight.d.ts deleted file mode 100644 index 34c550d5f8217d..00000000000000 --- a/src/lights/HemisphereLight.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { Color } from './../math/Color'; -import { Vector3 } from '../math/Vector3'; -import { Light } from './Light'; - -export class HemisphereLight extends Light { - - /** - * @param skyColor - * @param groundColor - * @param [intensity=1] - */ - constructor( - skyColor?: Color | string | number, - groundColor?: Color | string | number, - intensity?: number - ); - - /** - * @default 'HemisphereLight' - */ - type: string; - - /** - * @default THREE.Object3D.DefaultUp - */ - position: Vector3; - - groundColor: Color; - - readonly isHemisphereLight: true; - -} diff --git a/src/lights/HemisphereLightProbe.d.ts b/src/lights/HemisphereLightProbe.d.ts deleted file mode 100644 index 09696b6e1ffb83..00000000000000 --- a/src/lights/HemisphereLightProbe.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { Color } from './../math/Color'; -import { LightProbe } from './LightProbe'; - -export class HemisphereLightProbe extends LightProbe { - - constructor( skyColor?: Color | string | number, groundColor?: Color | string | number, intensity?: number ); - - readonly isHemisphereLightProbe: true; - -} diff --git a/src/lights/Light.d.ts b/src/lights/Light.d.ts deleted file mode 100644 index cdd80873f95a60..00000000000000 --- a/src/lights/Light.d.ts +++ /dev/null @@ -1,69 +0,0 @@ -import { Color } from './../math/Color'; -import { LightShadow } from './LightShadow'; -import { Object3D } from './../core/Object3D'; - -// Lights ////////////////////////////////////////////////////////////////////////////////// - -/** - * Abstract base class for lights. - */ -export class Light extends Object3D { - - constructor( hex?: number | string, intensity?: number ); - - /** - * @default 'Light' - */ - type: string; - - color: Color; - - /** - * @default 1 - */ - intensity: number; - readonly isLight: true; - - shadow: LightShadow; - /** - * @deprecated Use shadow.camera.fov instead. - */ - shadowCameraFov: any; - /** - * @deprecated Use shadow.camera.left instead. - */ - shadowCameraLeft: any; - /** - * @deprecated Use shadow.camera.right instead. - */ - shadowCameraRight: any; - /** - * @deprecated Use shadow.camera.top instead. - */ - shadowCameraTop: any; - /** - * @deprecated Use shadow.camera.bottom instead. - */ - shadowCameraBottom: any; - /** - * @deprecated Use shadow.camera.near instead. - */ - shadowCameraNear: any; - /** - * @deprecated Use shadow.camera.far instead. - */ - shadowCameraFar: any; - /** - * @deprecated Use shadow.bias instead. - */ - shadowBias: any; - /** - * @deprecated Use shadow.mapSize.width instead. - */ - shadowMapWidth: any; - /** - * @deprecated Use shadow.mapSize.height instead. - */ - shadowMapHeight: any; - -} diff --git a/src/lights/LightProbe.d.ts b/src/lights/LightProbe.d.ts deleted file mode 100644 index 4d8328547da11c..00000000000000 --- a/src/lights/LightProbe.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { SphericalHarmonics3 } from './../math/SphericalHarmonics3'; -import { Light } from './Light'; - -export class LightProbe extends Light { - - constructor( sh?: SphericalHarmonics3, intensity?: number ); - - /** - * @default 'LightProbe' - */ - type: string; - - readonly isLightProbe: true; - - /** - * @default new THREE.SphericalHarmonics3() - */ - sh: SphericalHarmonics3; - - fromJSON( json: object ): LightProbe; - -} diff --git a/src/lights/LightShadow.d.ts b/src/lights/LightShadow.d.ts deleted file mode 100644 index b4101fca60c242..00000000000000 --- a/src/lights/LightShadow.d.ts +++ /dev/null @@ -1,67 +0,0 @@ -import { Camera } from './../cameras/Camera'; -import { Light } from './../lights/Light'; -import { Vector2 } from './../math/Vector2'; -import { Vector4 } from './../math/Vector4'; -import { Matrix4 } from './../math/Matrix4'; -import { RenderTarget } from '../renderers/webgl/WebGLRenderLists'; - -export class LightShadow { - - constructor( camera: Camera ); - - camera: Camera; - - /** - * @default 0 - */ - bias: number; - - /** - * @default 0 - */ - normalBias: number; - - /** - * @default 1 - */ - radius: number; - - /** - * @default new THREE.Vector2( 512, 512 ) - */ - mapSize: Vector2; - - /** - * @default null - */ - map: RenderTarget; - - /** - * @default null - */ - mapPass: RenderTarget; - - /** - * @default new THREE.Matrix4() - */ - matrix: Matrix4; - - /** - * @default true - */ - autoUpdate: boolean; - - /** - * @default false - */ - needsUpdate: boolean; - - copy( source: LightShadow ): this; - clone( recursive?: boolean ): LightShadow; - toJSON(): any; - getFrustum(): number; - updateMatrices( light: Light, viewportIndex?: number ): void; - getViewport( viewportIndex: number ): Vector4; - getFrameExtents(): Vector2; - -} diff --git a/src/lights/PointLight.d.ts b/src/lights/PointLight.d.ts deleted file mode 100644 index a8b7b9c0837182..00000000000000 --- a/src/lights/PointLight.d.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { Color } from './../math/Color'; -import { Light } from './Light'; -import { PointLightShadow } from './PointLightShadow'; - -/** - * @example - * const light = new THREE.PointLight( 0xff0000, 1, 100 ); - * light.position.set( 50, 50, 50 ); - * scene.add( light ); - */ -export class PointLight extends Light { - - constructor( - color?: Color | string | number, - intensity?: number, - distance?: number, - decay?: number - ); - - /** - * @default 'PointLight' - */ - type: string; - - /** - * Light's intensity. - * @default 1 - */ - intensity: number; - - /** - * If non-zero, light will attenuate linearly from maximum intensity at light position down to zero at distance. - * @default 0 - */ - distance: number; - - /** - * @default 1 - */ - decay: number; - - /** - * @default new THREE.PointLightShadow() - */ - shadow: PointLightShadow; - - power: number; - -} diff --git a/src/lights/PointLightShadow.d.ts b/src/lights/PointLightShadow.d.ts deleted file mode 100644 index 8381c1ff3c5a33..00000000000000 --- a/src/lights/PointLightShadow.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { PerspectiveCamera } from './../cameras/PerspectiveCamera'; -import { LightShadow } from './LightShadow'; - -export class PointLightShadow extends LightShadow { - - camera: PerspectiveCamera; - -} diff --git a/src/lights/RectAreaLight.d.ts b/src/lights/RectAreaLight.d.ts deleted file mode 100644 index 7acc561e3cf54d..00000000000000 --- a/src/lights/RectAreaLight.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { Light } from './Light'; -import { Color } from './../math/Color'; - -export class RectAreaLight extends Light { - - constructor( - color?: Color | string | number, - intensity?: number, - width?: number, - height?: number - ); - - /** - * @default 'RectAreaLight' - */ - type: string; - - /** - * @default 10 - */ - width: number; - - /** - * @default 10 - */ - height: number; - - /** - * @default 1 - */ - intensity: number; - - readonly isRectAreaLight: true; - -} diff --git a/src/lights/SpotLight.d.ts b/src/lights/SpotLight.d.ts deleted file mode 100644 index 5a52dbf7da521b..00000000000000 --- a/src/lights/SpotLight.d.ts +++ /dev/null @@ -1,73 +0,0 @@ -import { Color } from './../math/Color'; -import { Vector3 } from '../math/Vector3'; -import { Object3D } from './../core/Object3D'; -import { SpotLightShadow } from './SpotLightShadow'; -import { Light } from './Light'; - -/** - * A point light that can cast shadow in one direction. - */ -export class SpotLight extends Light { - - constructor( - color?: Color | string | number, - intensity?: number, - distance?: number, - angle?: number, - penumbra?: number, - decay?: number - ); - - /** - * @default 'SpotLight' - */ - type: string; - - /** - * @default THREE.Object3D.DefaultUp - */ - position: Vector3; - - /** - * Spotlight focus points at target.position. - * @default new THREE.Object3D() - */ - target: Object3D; - - /** - * Light's intensity. - * @default 1 - */ - intensity: number; - - /** - * If non-zero, light will attenuate linearly from maximum intensity at light position down to zero at distance. - * @default 0 - */ - distance: number; - - /** - * Maximum extent of the spotlight, in radians, from its direction. - * @default Math.PI / 3. - */ - angle: number; - - /** - * @default 1 - */ - decay: number; - - /** - * @default new THREE.SpotLightShadow() - */ - shadow: SpotLightShadow; - power: number; - - /** - * @default 0 - */ - penumbra: number; - - readonly isSpotLight: true; - -} diff --git a/src/lights/SpotLightShadow.d.ts b/src/lights/SpotLightShadow.d.ts deleted file mode 100644 index 0008a9e3303335..00000000000000 --- a/src/lights/SpotLightShadow.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { PerspectiveCamera } from './../cameras/PerspectiveCamera'; -import { LightShadow } from './LightShadow'; - -export class SpotLightShadow extends LightShadow { - - camera: PerspectiveCamera; - readonly isSpotLightShadow: true; - - /** - * @default 1 - */ - focus: number; - -} diff --git a/src/loaders/AnimationLoader.d.ts b/src/loaders/AnimationLoader.d.ts deleted file mode 100644 index 66ed9fe3653863..00000000000000 --- a/src/loaders/AnimationLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { LoadingManager } from './LoadingManager'; -import { Loader } from './Loader'; -import { AnimationClip } from './../animation/AnimationClip'; - -export class AnimationLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( response: AnimationClip[] ) => void, - onProgress?: ( request: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( json: any ): AnimationClip[]; - -} diff --git a/src/loaders/AudioLoader.d.ts b/src/loaders/AudioLoader.d.ts deleted file mode 100644 index 7112ec65ec92dd..00000000000000 --- a/src/loaders/AudioLoader.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; - -export class AudioLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( audioBuffer: AudioBuffer ) => void, - onProgress?: ( request: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): void; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/loaders/BufferGeometryLoader.d.ts b/src/loaders/BufferGeometryLoader.d.ts deleted file mode 100644 index 8618bc121c4196..00000000000000 --- a/src/loaders/BufferGeometryLoader.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { BufferGeometry } from './../core/BufferGeometry'; -import { InstancedBufferGeometry } from '../core/InstancedBufferGeometry'; - -export class BufferGeometryLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( bufferGeometry: InstancedBufferGeometry | BufferGeometry ) => void, - onProgress?: ( request: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( json: any ): InstancedBufferGeometry | BufferGeometry; - -} diff --git a/src/loaders/Cache.d.ts b/src/loaders/Cache.d.ts deleted file mode 100644 index cf188ba5cddd16..00000000000000 --- a/src/loaders/Cache.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -export namespace Cache { - /** - * @default false - */ - export let enabled: boolean; - - /** - * @default {} - */ - export let files: any; - - export function add( key: string, file: any ): void; - export function get( key: string ): any; - export function remove( key: string ): void; - export function clear(): void; -} diff --git a/src/loaders/CompressedTextureLoader.d.ts b/src/loaders/CompressedTextureLoader.d.ts deleted file mode 100644 index ca97727abcd1ea..00000000000000 --- a/src/loaders/CompressedTextureLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { CompressedTexture } from './../textures/CompressedTexture'; - -export class CompressedTextureLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( texture: CompressedTexture ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): CompressedTexture; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/loaders/CubeTextureLoader.d.ts b/src/loaders/CubeTextureLoader.d.ts deleted file mode 100644 index d338de3e9da6a3..00000000000000 --- a/src/loaders/CubeTextureLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { CubeTexture } from './../textures/CubeTexture'; - -export class CubeTextureLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - urls: Array, - onLoad?: ( texture: CubeTexture ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): CubeTexture; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/loaders/DataTextureLoader.d.ts b/src/loaders/DataTextureLoader.d.ts deleted file mode 100644 index 02775050eaa53a..00000000000000 --- a/src/loaders/DataTextureLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { DataTexture } from './../textures/DataTexture'; - -export class DataTextureLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad: ( dataTexture: DataTexture ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): void; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/loaders/FileLoader.d.ts b/src/loaders/FileLoader.d.ts deleted file mode 100644 index 6b45e09b74e779..00000000000000 --- a/src/loaders/FileLoader.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; - -export class FileLoader extends Loader { - - constructor( manager?: LoadingManager ); - - mimeType: undefined | MimeType; - responseType: undefined |string; - - load( - url: string, - onLoad?: ( response: string | ArrayBuffer ) => void, - onProgress?: ( request: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): any; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setMimeType( mimeType: MimeType ): FileLoader; - setResponseType( responseType: string ): FileLoader; - -} diff --git a/src/loaders/FontLoader.d.ts b/src/loaders/FontLoader.d.ts deleted file mode 100644 index be15d66ca14ffa..00000000000000 --- a/src/loaders/FontLoader.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { Font } from './../extras/core/Font'; - -export class FontLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad?: ( responseFont: Font ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( json: any ): Font; - -} diff --git a/src/loaders/ImageBitmapLoader.d.ts b/src/loaders/ImageBitmapLoader.d.ts deleted file mode 100644 index 866e631ab949e3..00000000000000 --- a/src/loaders/ImageBitmapLoader.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; - -export class ImageBitmapLoader extends Loader { - - constructor( manager?: LoadingManager ); - - /** - * @default { premultiplyAlpha: 'none' } - */ - options: undefined | object; - - readonly isImageBitmapLoader: true; - - setOptions( options: object ): ImageBitmapLoader; - load( - url: string, - onLoad?: ( response: ImageBitmap ) => void, - onProgress?: ( request: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): any; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/loaders/ImageLoader.d.ts b/src/loaders/ImageLoader.d.ts deleted file mode 100644 index 2f7c391e6a2611..00000000000000 --- a/src/loaders/ImageLoader.d.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; - -/** - * A loader for loading an image. - * Unlike other loaders, this one emits events instead of using predefined callbacks. So if you're interested in getting notified when things happen, you need to add listeners to the object. - */ -export class ImageLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad?: ( image: HTMLImageElement ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): HTMLImageElement; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/loaders/Loader.d.ts b/src/loaders/Loader.d.ts deleted file mode 100644 index eeac497eb787fe..00000000000000 --- a/src/loaders/Loader.d.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { LoadingManager } from './LoadingManager'; - -/** - * Base class for implementing loaders. - */ -export class Loader { - - constructor( manager?: LoadingManager ); - - /** - * @default 'anonymous' - */ - crossOrigin: string; - - /** - * @default: false - */ - withCredentials: boolean; - - /** - * @default '' - */ - path: string; - - /** - * @default '' - */ - resourcePath: string; - manager: LoadingManager; - - /** - * @default {} - */ - requestHeader: { [header: string]: string }; - - /* - load(): void; - parse(): void; - */ - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - - setCrossOrigin( crossOrigin: string ): this; - setWithCredentials( value: boolean ): this; - setPath( path: string ): this; - setResourcePath( resourcePath: string ): this; - setRequestHeader( requestHeader: { [header: string]: string } ): this; - -} diff --git a/src/loaders/LoaderUtils.d.ts b/src/loaders/LoaderUtils.d.ts deleted file mode 100644 index d6014c1563e023..00000000000000 --- a/src/loaders/LoaderUtils.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { TypedArray } from '../polyfills'; - -export class LoaderUtils { - - static decodeText( array: TypedArray ): string; - static extractUrlBase( url: string ): string; - -} diff --git a/src/loaders/LoadingManager.d.ts b/src/loaders/LoadingManager.d.ts deleted file mode 100644 index d470715cd21998..00000000000000 --- a/src/loaders/LoadingManager.d.ts +++ /dev/null @@ -1,71 +0,0 @@ -import { Loader } from './Loader'; - -export const DefaultLoadingManager: LoadingManager; - -/** - * Handles and keeps track of loaded and pending data. - */ -export class LoadingManager { - - constructor( - onLoad?: () => void, - onProgress?: ( url: string, loaded: number, total: number ) => void, - onError?: ( url: string ) => void - ); - - /** - * Will be called when loading of an item starts. - * @param url The url of the item that started loading. - * @param loaded The number of items already loaded so far. - * @param total The total amount of items to be loaded. - */ - onStart?: ( url: string, loaded: number, total: number ) => void; - - /** - * Will be called when all items finish loading. - * The default is a function with empty body. - */ - onLoad: () => void; - - /** - * Will be called for each loaded item. - * The default is a function with empty body. - * @param url The url of the item just loaded. - * @param loaded The number of items already loaded so far. - * @param total The total amount of items to be loaded. - */ - onProgress: ( url: string, loaded: number, total: number ) => void; - - /** - * Will be called when item loading fails. - * The default is a function with empty body. - * @param url The url of the item that errored. - */ - onError: ( url: string ) => void; - - /** - * If provided, the callback will be passed each resource URL before a request is sent. - * The callback may return the original URL, or a new URL to override loading behavior. - * This behavior can be used to load assets from .ZIP files, drag-and-drop APIs, and Data URIs. - * @param callback URL modifier callback. Called with url argument, and must return resolvedURL. - */ - setURLModifier( callback?: ( url: string ) => string ): this; - - /** - * Given a URL, uses the URL modifier callback (if any) and returns a resolved URL. - * If no URL modifier is set, returns the original URL. - * @param url the url to load - */ - resolveURL( url: string ): string; - - itemStart( url: string ): void; - itemEnd( url: string ): void; - itemError( url: string ): void; - - // handlers - - addHandler( regex: RegExp, loader: Loader ): this; - removeHandler( regex: RegExp ): this; - getHandler( file: string ): Loader | null; - -} diff --git a/src/loaders/MaterialLoader.d.ts b/src/loaders/MaterialLoader.d.ts deleted file mode 100644 index f4b1f92cb05098..00000000000000 --- a/src/loaders/MaterialLoader.d.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { Texture } from './../textures/Texture'; -import { Material } from './../materials/Material'; - -export class MaterialLoader extends Loader { - - constructor( manager?: LoadingManager ); - - /** - * @default {} - */ - textures: { [key: string]: Texture }; - - load( - url: string, - onLoad: ( material: Material ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: Error | ErrorEvent ) => void - ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - setTextures( textures: { [key: string]: Texture } ): this; - parse( json: any ): Material; - -} diff --git a/src/loaders/ObjectLoader.d.ts b/src/loaders/ObjectLoader.d.ts deleted file mode 100644 index c38dd77068f19a..00000000000000 --- a/src/loaders/ObjectLoader.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { Object3D } from './../core/Object3D'; -import { Texture } from './../textures/Texture'; -import { Material } from './../materials/Material'; -import { AnimationClip } from './../animation/AnimationClip'; - -export class ObjectLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad?: ( object: ObjectType ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: Error | ErrorEvent ) => void - ): void; - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - parse( json: any, onLoad?: ( object: Object3D ) => void ): T; - parseGeometries( json: any ): any[]; // Array of BufferGeometry or Geometry or Geometry2. - parseMaterials( json: any, textures: Texture[] ): Material[]; // Array of Classes that inherits from Matrial. - parseAnimations( json: any ): AnimationClip[]; - parseImages( - json: any, - onLoad: () => void - ): { [key: string]: HTMLImageElement }; - parseTextures( json: any, images: any ): Texture[]; - parseObject( - data: any, - geometries: any[], - materials: Material[], - animations: AnimationClip[] - ): T; - -} diff --git a/src/loaders/TextureLoader.d.ts b/src/loaders/TextureLoader.d.ts deleted file mode 100644 index 7e3e357e27ddc4..00000000000000 --- a/src/loaders/TextureLoader.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { Loader } from './Loader'; -import { LoadingManager } from './LoadingManager'; -import { Texture } from './../textures/Texture'; - -/** - * Class for loading a texture. - * Unlike other loaders, this one emits events instead of using predefined callbacks. So if you're interested in getting notified when things happen, you need to add listeners to the object. - */ -export class TextureLoader extends Loader { - - constructor( manager?: LoadingManager ); - - load( - url: string, - onLoad?: ( texture: Texture ) => void, - onProgress?: ( event: ProgressEvent ) => void, - onError?: ( event: ErrorEvent ) => void - ): Texture; - - loadAsync( url: string, onProgress?: ( event: ProgressEvent ) => void ): Promise; - -} diff --git a/src/materials/LineBasicMaterial.d.ts b/src/materials/LineBasicMaterial.d.ts deleted file mode 100644 index a34190de2e4e1c..00000000000000 --- a/src/materials/LineBasicMaterial.d.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Color } from './../math/Color'; -import { MaterialParameters, Material } from './Material'; - -export interface LineBasicMaterialParameters extends MaterialParameters { - color?: Color | string | number; - linewidth?: number; - linecap?: string; - linejoin?: string; - morphTargets?: boolean; -} - -export class LineBasicMaterial extends Material { - - constructor( parameters?: LineBasicMaterialParameters ); - - /** - * @default 'LineBasicMaterial' - */ - type: string; - - /** - * @default 0xffffff - */ - color: Color; - - /** - * @default 1 - */ - linewidth: number; - - /** - * @default 'round' - */ - linecap: string; - - /** - * @default 'round' - */ - linejoin: string; - - /** - * @default false - */ - morphTargets: boolean; - - setValues( parameters: LineBasicMaterialParameters ): void; - -} diff --git a/src/materials/LineDashedMaterial.d.ts b/src/materials/LineDashedMaterial.d.ts deleted file mode 100644 index 4680073f2e16c6..00000000000000 --- a/src/materials/LineDashedMaterial.d.ts +++ /dev/null @@ -1,36 +0,0 @@ -import { LineBasicMaterial, LineBasicMaterialParameters } from './LineBasicMaterial'; - -export interface LineDashedMaterialParameters extends LineBasicMaterialParameters { - scale?: number; - dashSize?: number; - gapSize?: number; -} - -export class LineDashedMaterial extends LineBasicMaterial { - - constructor( parameters?: LineDashedMaterialParameters ); - - /** - * @default 'LineDashedMaterial' - */ - type: string; - - /** - * @default 1 - */ - scale: number; - - /** - * @default 1 - */ - dashSize: number; - - /** - * @default 1 - */ - gapSize: number; - readonly isLineDashedMaterial: true; - - setValues( parameters: LineDashedMaterialParameters ): void; - -} diff --git a/src/materials/Material.d.ts b/src/materials/Material.d.ts deleted file mode 100644 index 21a794e926b2eb..00000000000000 --- a/src/materials/Material.d.ts +++ /dev/null @@ -1,395 +0,0 @@ -import { Plane } from './../math/Plane'; -import { EventDispatcher } from './../core/EventDispatcher'; -import { WebGLRenderer } from './../renderers/WebGLRenderer'; -import { Shader } from './../renderers/shaders/ShaderLib'; -import { - BlendingDstFactor, - BlendingEquation, - Blending, - BlendingSrcFactor, - DepthModes, - Side, - StencilFunc, - StencilOp -} from '../constants'; - -export interface MaterialParameters { - alphaTest?: number; - blendDst?: BlendingDstFactor; - blendDstAlpha?: number; - blendEquation?: BlendingEquation; - blendEquationAlpha?: number; - blending?: Blending; - blendSrc?: BlendingSrcFactor | BlendingDstFactor; - blendSrcAlpha?: number; - clipIntersection?: boolean; - clippingPlanes?: Plane[]; - clipShadows?: boolean; - colorWrite?: boolean; - defines?: any; - depthFunc?: DepthModes; - depthTest?: boolean; - depthWrite?: boolean; - fog?: boolean; - name?: string; - opacity?: number; - polygonOffset?: boolean; - polygonOffsetFactor?: number; - polygonOffsetUnits?: number; - precision?: 'highp' | 'mediump' | 'lowp' | null; - premultipliedAlpha?: boolean; - dithering?: boolean; - flatShading?: boolean; - side?: Side; - shadowSide?: Side; - toneMapped?: boolean; - transparent?: boolean; - vertexColors?: boolean; - visible?: boolean; - stencilWrite?: boolean; - stencilFunc?: StencilFunc; - stencilRef?: number; - stencilWriteMask?: number; - stencilFuncMask?: number; - stencilFail?: StencilOp; - stencilZFail?: StencilOp; - stencilZPass?: StencilOp; - userData?: any; -} - -/** - * Materials describe the appearance of objects. They are defined in a (mostly) renderer-independent way, so you don't have to rewrite materials if you decide to use a different renderer. - */ -export class Material extends EventDispatcher { - - constructor(); - - /** - * Sets the alpha value to be used when running an alpha test. Default is 0. - * @default 0 - */ - alphaTest: number; - - /** - * Blending destination. It's one of the blending mode constants defined in Three.js. Default is {@link OneMinusSrcAlphaFactor}. - * @default THREE.OneMinusSrcAlphaFactor - */ - blendDst: BlendingDstFactor; - - /** - * The tranparency of the .blendDst. Default is null. - * @default null - */ - blendDstAlpha: number | null; - - /** - * Blending equation to use when applying blending. It's one of the constants defined in Three.js. Default is {@link AddEquation}. - * @default THREE.AddEquation - */ - blendEquation: BlendingEquation; - - /** - * The tranparency of the .blendEquation. Default is null. - * @default null - */ - blendEquationAlpha: number | null; - - /** - * Which blending to use when displaying objects with this material. Default is {@link NormalBlending}. - * @default THREE.NormalBlending - */ - blending: Blending; - - /** - * Blending source. It's one of the blending mode constants defined in Three.js. Default is {@link SrcAlphaFactor}. - * @default THREE.SrcAlphaFactor - */ - blendSrc: BlendingSrcFactor | BlendingDstFactor; - - /** - * The tranparency of the .blendSrc. Default is null. - * @default null - */ - blendSrcAlpha: number | null; - - /** - * Changes the behavior of clipping planes so that only their intersection is clipped, rather than their union. Default is false. - * @default false - */ - clipIntersection: boolean; - - /** - * User-defined clipping planes specified as THREE.Plane objects in world space. These planes apply to the objects this material is attached to. Points in space whose signed distance to the plane is negative are clipped (not rendered). See the WebGL / clipping /intersection example. Default is null. - * @default null - */ - clippingPlanes: any; - - /** - * Defines whether to clip shadows according to the clipping planes specified on this material. Default is false. - * @default false - */ - clipShadows: boolean; - - /** - * Whether to render the material's color. This can be used in conjunction with a mesh's .renderOrder property to create invisible objects that occlude other objects. Default is true. - * @default true - */ - colorWrite: boolean; - - /** - * Custom defines to be injected into the shader. These are passed in form of an object literal, with key/value pairs. { MY_CUSTOM_DEFINE: '' , PI2: Math.PI * 2 }. - * The pairs are defined in both vertex and fragment shaders. Default is undefined. - * @default undefined - */ - defines: undefined | { [key: string]: any }; - - /** - * Which depth function to use. Default is {@link LessEqualDepth}. See the depth mode constants for all possible values. - * @default THREE.LessEqualDepth - */ - depthFunc: DepthModes; - - /** - * Whether to have depth test enabled when rendering this material. Default is true. - * @default true - */ - depthTest: boolean; - - /** - * Whether rendering this material has any effect on the depth buffer. Default is true. - * When drawing 2D overlays it can be useful to disable the depth writing in order to layer several things together without creating z-index artifacts. - * @default true - */ - depthWrite: boolean; - - /** - * Whether the material is affected by fog. Default is true. - * @default fog - */ - fog: boolean; - - /** - * Unique number of this material instance. - */ - id: number; - - /** - * Whether rendering this material has any effect on the stencil buffer. Default is *false*. - * @default false - */ - stencilWrite: boolean; - - /** - * The stencil comparison function to use. Default is {@link AlwaysStencilFunc}. See stencil operation constants for all possible values. - * @default THREE.AlwaysStencilFunc - */ - stencilFunc: StencilFunc; - - /** - * The value to use when performing stencil comparisons or stencil operations. Default is *0*. - * @default 0 - */ - stencilRef: number; - - /** - * The bit mask to use when writing to the stencil buffer. Default is *0xFF*. - * @default 0xff - */ - stencilWriteMask: number; - - /** - * The bit mask to use when comparing against the stencil buffer. Default is *0xFF*. - * @default 0xff - */ - stencilFuncMask: number; - - /** - * Which stencil operation to perform when the comparison function returns false. Default is {@link KeepStencilOp}. See the stencil operation constants for all possible values. - * @default THREE.KeepStencilOp - */ - stencilFail: StencilOp; - - /** - * Which stencil operation to perform when the comparison function returns true but the depth test fails. Default is {@link KeepStencilOp}. See the stencil operation constants for all possible values. - * @default THREE.KeepStencilOp - */ - stencilZFail: StencilOp; - - /** - * Which stencil operation to perform when the comparison function returns true and the depth test passes. Default is {@link KeepStencilOp}. See the stencil operation constants for all possible values. - * @default THREE.KeepStencilOp - */ - stencilZPass: StencilOp; - - /** - * Used to check whether this or derived classes are materials. Default is true. - * You should not change this, as it used internally for optimisation. - */ - readonly isMaterial: true; - - /** - * Material name. Default is an empty string. - * @default '' - */ - name: string; - - /** - * Specifies that the material needs to be updated, WebGL wise. Set it to true if you made changes that need to be reflected in WebGL. - * This property is automatically set to true when instancing a new material. - * @default false - */ - needsUpdate: boolean; - - /** - * Opacity. Default is 1. - * @default 1 - */ - opacity: number; - - /** - * Whether to use polygon offset. Default is false. This corresponds to the POLYGON_OFFSET_FILL WebGL feature. - * @default false - */ - polygonOffset: boolean; - - /** - * Sets the polygon offset factor. Default is 0. - * @default 0 - */ - polygonOffsetFactor: number; - - /** - * Sets the polygon offset units. Default is 0. - * @default 0 - */ - polygonOffsetUnits: number; - - /** - * Override the renderer's default precision for this material. Can be "highp", "mediump" or "lowp". Defaults is null. - * @default null - */ - precision: 'highp' | 'mediump' | 'lowp' | null; - - /** - * Whether to premultiply the alpha (transparency) value. See WebGL / Materials / Transparency for an example of the difference. Default is false. - * @default false - */ - premultipliedAlpha: boolean; - - /** - * Whether to apply dithering to the color to remove the appearance of banding. Default is false. - * @default false - */ - dithering: boolean; - - /** - * Define whether the material is rendered with flat shading. Default is false. - * @default false - */ - flatShading: boolean; - - /** - * Defines which of the face sides will be rendered - front, back or both. - * Default is THREE.FrontSide. Other options are THREE.BackSide and THREE.DoubleSide. - * @default THREE.FrontSide - */ - side: Side; - - /** - * Defines which of the face sides will cast shadows. Default is *null*. - * If *null*, the value is opposite that of side, above. - * @default null - */ - shadowSide: Side; - - /** - * Defines whether this material is tone mapped according to the renderer's toneMapping setting. - * Default is true. - * @default true - */ - toneMapped: boolean; - - /** - * Defines whether this material is transparent. This has an effect on rendering as transparent objects need special treatment and are rendered after non-transparent objects. - * When set to true, the extent to which the material is transparent is controlled by setting it's .opacity property. - * Default is false. - * @default false - */ - transparent: boolean; - - /** - * Value is the string 'Material'. This shouldn't be changed, and can be used to find all objects of this type in a scene. - * @default 'Material' - */ - type: string; - - /** - * UUID of this material instance. This gets automatically assigned, so this shouldn't be edited. - */ - uuid: string; - - /** - * Defines whether vertex coloring is used. Default is false. - * @default false - */ - vertexColors: boolean; - - /** - * Defines whether this material is visible. Default is true. - * @default true - */ - visible: boolean; - - /** - * An object that can be used to store custom data about the Material. It should not hold references to functions as these will not be cloned. - * @default {} - */ - userData: any; - - /** - * This starts at 0 and counts how many times .needsUpdate is set to true. - * @default 0 - */ - version: number; - - /** - * Return a new material with the same parameters as this material. - */ - clone(): Material; - - /** - * Copy the parameters from the passed material into this material. - * @param material - */ - copy( material: Material ): this; - - /** - * This disposes the material. Textures of a material don't get disposed. These needs to be disposed by {@link Texture}. - */ - dispose(): void; - - /** - * An optional callback that is executed immediately before the shader program is compiled. This function is called with the shader source code as a parameter. Useful for the modification of built-in materials. - * @param shader Source code of the shader - * @param renderer WebGLRenderer Context that is initializing the material - */ - onBeforeCompile ( shader : Shader, renderer : WebGLRenderer ) : void; - - /** - * In case onBeforeCompile is used, this callback can be used to identify values of settings used in onBeforeCompile, so three.js can reuse a cached shader or recompile the shader as needed. - */ - customProgramCacheKey(): string; - - /** - * Sets the properties based on the values. - * @param values A container with parameters. - */ - setValues( values: MaterialParameters ): void; - - /** - * Convert the material to three.js JSON format. - * @param meta Object containing metadata such as textures or images for the material. - */ - toJSON( meta?: any ): any; - -} diff --git a/src/materials/Materials.d.ts b/src/materials/Materials.d.ts deleted file mode 100644 index ff7faa9d47a5fa..00000000000000 --- a/src/materials/Materials.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -export * from './ShadowMaterial'; -export * from './SpriteMaterial'; -export * from './RawShaderMaterial'; -export * from './ShaderMaterial'; -export * from './PointsMaterial'; -export * from './MeshPhysicalMaterial'; -export * from './MeshStandardMaterial'; -export * from './MeshPhongMaterial'; -export * from './MeshToonMaterial'; -export * from './MeshNormalMaterial'; -export * from './MeshLambertMaterial'; -export * from './MeshDepthMaterial'; -export * from './MeshDistanceMaterial'; -export * from './MeshBasicMaterial'; -export * from './MeshMatcapMaterial'; -export * from './LineDashedMaterial'; -export * from './LineBasicMaterial'; -export * from './Material'; diff --git a/src/materials/MeshBasicMaterial.d.ts b/src/materials/MeshBasicMaterial.d.ts deleted file mode 100644 index 9607f9d2289d73..00000000000000 --- a/src/materials/MeshBasicMaterial.d.ts +++ /dev/null @@ -1,119 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { MaterialParameters, Material } from './Material'; -import { Combine } from '../constants'; -/** - * parameters is an object with one or more properties defining the material's appearance. - */ -export interface MeshBasicMaterialParameters extends MaterialParameters { - color?: Color | string | number; - opacity?: number; - map?: Texture | null; - aoMap?: Texture | null; - aoMapIntensity?: number; - specularMap?: Texture | null; - alphaMap?: Texture | null; - envMap?: Texture | null; - combine?: Combine; - reflectivity?: number; - refractionRatio?: number; - wireframe?: boolean; - wireframeLinewidth?: number; - wireframeLinecap?: string; - wireframeLinejoin?: string; - skinning?: boolean; - morphTargets?: boolean; -} - -export class MeshBasicMaterial extends Material { - - constructor( parameters?: MeshBasicMaterialParameters ); - - /** - * @default 'MeshBasicMaterial' - */ - type: string; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - aoMap: Texture | null; - - /** - * @default 1 - */ - aoMapIntensity: number; - - /** - * @default null - */ - specularMap: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default null - */ - envMap: Texture | null; - - /** - * @default THREE.MultiplyOperation - */ - combine: Combine; - - /** - * @default 1 - */ - reflectivity: number; - - /** - * @default 0.98 - */ - refractionRatio: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default 'round' - */ - wireframeLinecap: string; - - /** - * @default 'round' - */ - wireframeLinejoin: string; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - setValues( parameters: MeshBasicMaterialParameters ): void; - -} diff --git a/src/materials/MeshDepthMaterial.d.ts b/src/materials/MeshDepthMaterial.d.ts deleted file mode 100644 index c51eae700f877e..00000000000000 --- a/src/materials/MeshDepthMaterial.d.ts +++ /dev/null @@ -1,72 +0,0 @@ -import { DepthPackingStrategies } from '../constants'; -import { MaterialParameters, Material } from './Material'; -import { Texture } from './../textures/Texture'; - -export interface MeshDepthMaterialParameters extends MaterialParameters { - map?: Texture | null; - alphaMap?: Texture | null; - depthPacking?: DepthPackingStrategies; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - wireframe?: boolean; - wireframeLinewidth?: number; -} - -export class MeshDepthMaterial extends Material { - - constructor( parameters?: MeshDepthMaterialParameters ); - - /** - * @default 'MeshDepthMaterial' - */ - type: string; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default THREE.BasicDepthPacking - */ - depthPacking: DepthPackingStrategies; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default false - */ - fog: boolean; - - setValues( parameters: MeshDepthMaterialParameters ): void; - -} diff --git a/src/materials/MeshDistanceMaterial.d.ts b/src/materials/MeshDistanceMaterial.d.ts deleted file mode 100644 index d57122178ddbd1..00000000000000 --- a/src/materials/MeshDistanceMaterial.d.ts +++ /dev/null @@ -1,82 +0,0 @@ -import { MaterialParameters, Material } from './Material'; -import { Vector3 } from './../math/Vector3'; -import { Texture } from './../textures/Texture'; - -export interface MeshDistanceMaterialParameters extends MaterialParameters { - map?: Texture | null; - alphaMap?: Texture | null; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - farDistance?: number; - nearDistance?: number; - referencePosition?: Vector3; -} - -export class MeshDistanceMaterial extends Material { - - constructor( parameters?: MeshDistanceMaterialParameters ); - - /** - * @default 'MeshDistanceMaterial' - */ - type: string; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default 1000 - */ - farDistance: number; - - /** - * @default 1 - */ - nearDistance: number; - - /** - * @default new THREE.Vector3() - */ - referencePosition: Vector3; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - fog: boolean; - - setValues( parameters: MeshDistanceMaterialParameters ): void; - -} diff --git a/src/materials/MeshLambertMaterial.d.ts b/src/materials/MeshLambertMaterial.d.ts deleted file mode 100644 index 9f1fecd9ed6fbd..00000000000000 --- a/src/materials/MeshLambertMaterial.d.ts +++ /dev/null @@ -1,152 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { MaterialParameters, Material } from './Material'; -import { Combine } from '../constants'; - -export interface MeshLambertMaterialParameters extends MaterialParameters { - color?: Color | string | number; - emissive?: Color | string | number; - emissiveIntensity?: number; - emissiveMap?: Texture | null; - map?: Texture | null; - lightMap?: Texture | null; - lightMapIntensity?: number; - aoMap?: Texture | null; - aoMapIntensity?: number; - specularMap?: Texture | null; - alphaMap?: Texture | null; - envMap?: Texture | null; - combine?: Combine; - reflectivity?: number; - refractionRatio?: number; - wireframe?: boolean; - wireframeLinewidth?: number; - wireframeLinecap?: string; - wireframeLinejoin?: string; - skinning?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; -} - -export class MeshLambertMaterial extends Material { - - constructor( parameters?: MeshLambertMaterialParameters ); - - /** - * @default 'MeshLambertMaterial' - */ - type: string; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default new THREE.Color( 0x000000 ) - */ - emissive: Color; - - /** - * @default 1 - */ - emissiveIntensity: number; - - /** - * @default null - */ - emissiveMap: Texture | null; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - lightMap: Texture | null; - - /** - * @default 1 - */ - lightMapIntensity: number; - - /** - * @default null - */ - aoMap: Texture | null; - - /** - * @default 1 - */ - aoMapIntensity: number; - - /** - * @default null - */ - specularMap: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default null - */ - envMap: Texture | null; - - /** - * @default THREE.MultiplyOperation - */ - combine: Combine; - - /** - * @default 1 - */ - reflectivity: number; - - /** - * @default 0.98 - */ - refractionRatio: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default 'round' - */ - wireframeLinecap: string; - - /** - * @default 'round' - */ - wireframeLinejoin: string; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - - setValues( parameters: MeshLambertMaterialParameters ): void; - -} diff --git a/src/materials/MeshMatcapMaterial.d.ts b/src/materials/MeshMatcapMaterial.d.ts deleted file mode 100644 index f4d85cd765e325..00000000000000 --- a/src/materials/MeshMatcapMaterial.d.ts +++ /dev/null @@ -1,117 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { Vector2 } from './../math/Vector2'; -import { MaterialParameters, Material } from './Material'; -import { NormalMapTypes } from '../constants'; - -export interface MeshMatcapMaterialParameters extends MaterialParameters { - - color?: Color | string | number; - matcap?: Texture | null; - map?: Texture | null; - bumpMap?: Texture | null; - bumpScale?: number; - normalMap?: Texture | null; - normalMapType?: NormalMapTypes; - normalScale?: Vector2; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - alphaMap?: Texture | null; - skinning?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; -} - -export class MeshMatcapMaterial extends Material { - - constructor( parameters?: MeshMatcapMaterialParameters ); - - /** - * @default 'MeshMatcapMaterial' - */ - type: string; - - /** - * @default { 'MATCAP': '' } - */ - defines: { [key: string]: any }; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default null - */ - matcap: Texture | null; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - bumpMap: Texture | null; - - /** - * @default 1 - */ - bumpScale: number; - - /** - * @default null - */ - normalMap: Texture | null; - - /** - * @default THREE.TangentSpaceNormalMap - */ - normalMapType: NormalMapTypes; - - /** - * @default new Vector2( 1, 1 ) - */ - normalScale: Vector2; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - - setValues( parameters: MeshMatcapMaterialParameters ): void; - -} diff --git a/src/materials/MeshNormalMaterial.d.ts b/src/materials/MeshNormalMaterial.d.ts deleted file mode 100644 index cc811061375897..00000000000000 --- a/src/materials/MeshNormalMaterial.d.ts +++ /dev/null @@ -1,99 +0,0 @@ -import { MaterialParameters, Material } from './Material'; -import { Texture } from './../textures/Texture'; -import { Vector2 } from './../math/Vector2'; -import { NormalMapTypes } from '../constants'; - -export interface MeshNormalMaterialParameters extends MaterialParameters { - - bumpMap?: Texture | null; - bumpScale?: number; - normalMap?: Texture | null; - normalMapType?: NormalMapTypes; - normalScale?: Vector2; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - wireframe?: boolean; - wireframeLinewidth?: number; - skinning?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; -} - -export class MeshNormalMaterial extends Material { - - constructor( parameters?: MeshNormalMaterialParameters ); - - /** - * @default 'MeshNormalMaterial' - */ - type: string; - - /** - * @default null - */ - bumpMap: Texture | null; - - /** - * @default 1 - */ - bumpScale: number; - - /** - * @default null - */ - normalMap: Texture | null; - - /** - * @default THREE.TangentSpaceNormalMap - */ - normalMapType: NormalMapTypes; - - /** - * @default new THREE.Vector2( 1, 1 ) - */ - normalScale: Vector2; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - - setValues( parameters: MeshNormalMaterialParameters ): void; - -} diff --git a/src/materials/MeshPhongMaterial.d.ts b/src/materials/MeshPhongMaterial.d.ts deleted file mode 100644 index 5177f01527dd2e..00000000000000 --- a/src/materials/MeshPhongMaterial.d.ts +++ /dev/null @@ -1,219 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { Vector2 } from './../math/Vector2'; -import { MaterialParameters, Material } from './Material'; -import { Combine, NormalMapTypes } from '../constants'; - -export interface MeshPhongMaterialParameters extends MaterialParameters { - /** geometry color in hexadecimal. Default is 0xffffff. */ - color?: Color | string | number; - specular?: Color | string | number; - shininess?: number; - opacity?: number; - map?: Texture | null; - lightMap?: Texture | null; - lightMapIntensity?: number; - aoMap?: Texture | null; - aoMapIntensity?: number; - emissive?: Color | string | number; - emissiveIntensity?: number; - emissiveMap?: Texture | null; - bumpMap?: Texture | null; - bumpScale?: number; - normalMap?: Texture | null; - normalMapType?: NormalMapTypes; - normalScale?: Vector2; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - specularMap?: Texture | null; - alphaMap?: Texture | null; - envMap?: Texture | null; - combine?: Combine; - reflectivity?: number; - refractionRatio?: number; - wireframe?: boolean; - wireframeLinewidth?: number; - wireframeLinecap?: string; - wireframeLinejoin?: string; - skinning?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; -} - -export class MeshPhongMaterial extends Material { - - constructor( parameters?: MeshPhongMaterialParameters ); - - /** - * @default 'MeshNormalMaterial' - */ - type: string; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default new THREE.Color( 0x111111 ) - */ - specular: Color; - - /** - * @default 30 - */ - shininess: number; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - lightMap: Texture | null; - - /** - * @default null - */ - lightMapIntensity: number; - - /** - * @default null - */ - aoMap: Texture | null; - - /** - * @default null - */ - aoMapIntensity: number; - - /** - * @default new THREE.Color( 0x000000 ) - */ - emissive: Color; - - /** - * @default 1 - */ - emissiveIntensity: number; - - /** - * @default null - */ - emissiveMap: Texture | null; - - /** - * @default null - */ - bumpMap: Texture | null; - - /** - * @default 1 - */ - bumpScale: number; - - /** - * @default null - */ - normalMap: Texture | null; - - /** - * @default THREE.TangentSpaceNormalMap - */ - normalMapType: NormalMapTypes; - - /** - * @default new Vector2( 1, 1 ) - */ - normalScale: Vector2; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default null - */ - specularMap: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default null - */ - envMap: Texture | null; - - /** - * @default THREE.MultiplyOperation - */ - combine: Combine; - - /** - * @default 1 - */ - reflectivity: number; - - /** - * @default 0.98 - */ - refractionRatio: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default 'round' - */ - wireframeLinecap: string; - - /** - * @default 'round' - */ - wireframeLinejoin: string; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - /** - * @deprecated Use {@link MeshStandardMaterial THREE.MeshStandardMaterial} instead. - */ - metal: boolean; - - setValues( parameters: MeshPhongMaterialParameters ): void; - -} diff --git a/src/materials/MeshPhysicalMaterial.d.ts b/src/materials/MeshPhysicalMaterial.d.ts deleted file mode 100644 index 9ce7a05d337a37..00000000000000 --- a/src/materials/MeshPhysicalMaterial.d.ts +++ /dev/null @@ -1,98 +0,0 @@ -import { Texture } from './../textures/Texture'; -import { Vector2 } from './../math/Vector2'; -import { - MeshStandardMaterialParameters, - MeshStandardMaterial, -} from './MeshStandardMaterial'; -import { Color } from './../math/Color'; - -export interface MeshPhysicalMaterialParameters - extends MeshStandardMaterialParameters { - - clearcoat?: number; - clearcoatMap?: Texture | null; - clearcoatRoughness?: number; - clearcoatRoughnessMap?: Texture | null; - clearcoatNormalScale?: Vector2; - clearcoatNormalMap?: Texture | null; - - reflectivity?: number; - ior?: number; - - sheen?: Color; - - transmission?: number; - transmissionMap?: Texture | null; - -} - -export class MeshPhysicalMaterial extends MeshStandardMaterial { - - constructor( parameters: MeshPhysicalMaterialParameters ); - - /** - * @default 'MeshPhysicalMaterial' - */ - type: string; - - /** - * @default { 'STANDARD': '', 'PHYSICAL': '' } - */ - defines: { [key: string]: any }; - - /** - * @default 0 - */ - clearcoat: number; - - /** - * @default null - */ - clearcoatMap: Texture | null; - - /** - * @default 0 - */ - clearcoatRoughness: number; - - /** - * @default null - */ - clearcoatRoughnessMap: Texture | null; - - /** - * @default new THREE.Vector2( 1, 1 ) - */ - clearcoatNormalScale: Vector2; - - /** - * @default null - */ - clearcoatNormalMap: Texture | null; - - /** - * @default 0.5 - */ - reflectivity: number; - - /** - * @default 1.5 - */ - ior: number; - - /** - * @default null - */ - sheen: Color | null; - - /** - * @default 0 - */ - transmission: number; - - /** - * @default null - */ - transmissionMap: Texture | null; - -} diff --git a/src/materials/MeshStandardMaterial.d.ts b/src/materials/MeshStandardMaterial.d.ts deleted file mode 100644 index ac08987343c5e9..00000000000000 --- a/src/materials/MeshStandardMaterial.d.ts +++ /dev/null @@ -1,222 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { Vector2 } from './../math/Vector2'; -import { MaterialParameters, Material } from './Material'; -import { NormalMapTypes } from '../constants'; - -export interface MeshStandardMaterialParameters extends MaterialParameters { - color?: Color | string | number; - roughness?: number; - metalness?: number; - map?: Texture | null; - lightMap?: Texture | null; - lightMapIntensity?: number; - aoMap?: Texture | null; - aoMapIntensity?: number; - emissive?: Color | string | number; - emissiveIntensity?: number; - emissiveMap?: Texture | null; - bumpMap?: Texture | null; - bumpScale?: number; - normalMap?: Texture | null; - normalMapType?: NormalMapTypes; - normalScale?: Vector2; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - roughnessMap?: Texture | null; - metalnessMap?: Texture | null; - alphaMap?: Texture | null; - envMap?: Texture | null; - envMapIntensity?: number; - refractionRatio?: number; - wireframe?: boolean; - wireframeLinewidth?: number; - skinning?: boolean; - vertexTangents?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; -} - -export class MeshStandardMaterial extends Material { - - constructor( parameters?: MeshStandardMaterialParameters ); - - /** - * @default 'MeshStandardMaterial' - */ - type: string; - - /** - * @default { 'STANDARD': '' } - */ - defines: { [key: string]: any }; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default 1 - */ - roughness: number; - - /** - * @default 0 - */ - metalness: number; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - lightMap: Texture | null; - - /** - * @default 1 - */ - lightMapIntensity: number; - - /** - * @default null - */ - aoMap: Texture | null; - - /** - * @default 1 - */ - aoMapIntensity: number; - - /** - * @default new THREE.Color( 0x000000 ) - */ - emissive: Color; - - /** - * @default 1 - */ - emissiveIntensity: number; - - /** - * @default null - */ - emissiveMap: Texture | null; - - /** - * @default null - */ - bumpMap: Texture | null; - - /** - * @default 1 - */ - bumpScale: number; - - /** - * @default null - */ - normalMap: Texture | null; - - /** - * @default THREE.TangentSpaceNormalMap - */ - normalMapType: NormalMapTypes; - - /** - * @default new THREE.Vector2( 1, 1 ) - */ - normalScale: Vector2; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default null - */ - roughnessMap: Texture | null; - - /** - * @default null - */ - metalnessMap: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default null - */ - envMap: Texture | null; - - /** - * @default 1 - */ - envMapIntensity: number; - - /** - * @default 0.98 - */ - refractionRatio: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default 'round' - */ - wireframeLinecap: string; - - /** - * @default 'round' - */ - wireframeLinejoin: string; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - vertexTangents: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - - setValues( parameters: MeshStandardMaterialParameters ): void; - -} diff --git a/src/materials/MeshToonMaterial.d.ts b/src/materials/MeshToonMaterial.d.ts deleted file mode 100644 index 60346fb37e5ae6..00000000000000 --- a/src/materials/MeshToonMaterial.d.ts +++ /dev/null @@ -1,184 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { Vector2 } from './../math/Vector2'; -import { MaterialParameters, Material } from './Material'; -import { NormalMapTypes } from '../constants'; - -export interface MeshToonMaterialParameters extends MaterialParameters { - /** geometry color in hexadecimal. Default is 0xffffff. */ - color?: Color | string | number; - opacity?: number; - gradientMap?: Texture | null; - map?: Texture | null; - lightMap?: Texture | null; - lightMapIntensity?: number; - aoMap?: Texture | null; - aoMapIntensity?: number; - emissive?: Color | string | number; - emissiveIntensity?: number; - emissiveMap?: Texture | null; - bumpMap?: Texture | null; - bumpScale?: number; - normalMap?: Texture | null; - normalMapType?: NormalMapTypes; - normalScale?: Vector2; - displacementMap?: Texture | null; - displacementScale?: number; - displacementBias?: number; - alphaMap?: Texture | null; - wireframe?: boolean; - wireframeLinewidth?: number; - wireframeLinecap?: string; - wireframeLinejoin?: string; - skinning?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; -} - -export class MeshToonMaterial extends Material { - - constructor( parameters?: MeshToonMaterialParameters ); - - /** - * @default 'MeshToonMaterial' - */ - type: string; - - /** - * @default { 'TOON': '' } - */ - defines: { [key: string]: any }; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default null - */ - gradientMap: Texture | null; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - lightMap: Texture | null; - - /** - * @default 1 - */ - lightMapIntensity: number; - - /** - * @default null - */ - aoMap: Texture | null; - - /** - * @default 1 - */ - aoMapIntensity: number; - - /** - * @default new THREE.Color( 0x000000 ) - */ - emissive: Color; - - /** - * @default 1 - */ - emissiveIntensity: number; - - /** - * @default null - */ - emissiveMap: Texture | null; - - /** - * @default null - */ - bumpMap: Texture | null; - - /** - * @default 1 - */ - bumpScale: number; - - /** - * @default null - */ - normalMap: Texture | null; - - /** - * @default THREE.TangentSpaceNormalMap - */ - normalMapType: NormalMapTypes; - - /** - * @default new THREE.Vector2( 1, 1 ) - */ - normalScale: Vector2; - - /** - * @default null - */ - displacementMap: Texture | null; - - /** - * @default 1 - */ - displacementScale: number; - - /** - * @default 0 - */ - displacementBias: number; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default 'round' - */ - wireframeLinecap: string; - - /** - * @default 'round' - */ - wireframeLinejoin: string; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - - setValues( parameters: MeshToonMaterialParameters ): void; - -} diff --git a/src/materials/PointsMaterial.d.ts b/src/materials/PointsMaterial.d.ts deleted file mode 100644 index 9c472939e81b01..00000000000000 --- a/src/materials/PointsMaterial.d.ts +++ /dev/null @@ -1,55 +0,0 @@ -import { Material, MaterialParameters } from './Material'; -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; - -export interface PointsMaterialParameters extends MaterialParameters { - color?: Color | string | number; - map?: Texture | null; - alphaMap?: Texture | null; - size?: number; - sizeAttenuation?: boolean; - morphTargets?: boolean; -} - -export class PointsMaterial extends Material { - - constructor( parameters?: PointsMaterialParameters ); - - /** - * @default 'PointsMaterial' - */ - type: string; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default 1 - */ - size: number; - - /** - * @default true - */ - sizeAttenuation: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - setValues( parameters: PointsMaterialParameters ): void; - -} diff --git a/src/materials/RawShaderMaterial.d.ts b/src/materials/RawShaderMaterial.d.ts deleted file mode 100644 index 24a279157b1f39..00000000000000 --- a/src/materials/RawShaderMaterial.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { ShaderMaterialParameters, ShaderMaterial } from './ShaderMaterial'; - -export class RawShaderMaterial extends ShaderMaterial { - - constructor( parameters?: ShaderMaterialParameters ); - -} diff --git a/src/materials/ShaderMaterial.d.ts b/src/materials/ShaderMaterial.d.ts deleted file mode 100644 index 3e3ec300741f04..00000000000000 --- a/src/materials/ShaderMaterial.d.ts +++ /dev/null @@ -1,129 +0,0 @@ -import { IUniform } from '../renderers/shaders/UniformsLib'; -import { MaterialParameters, Material } from './Material'; -import { GLSLVersion } from '../constants'; - -export interface ShaderMaterialParameters extends MaterialParameters { - uniforms?: { [uniform: string]: IUniform }; - vertexShader?: string; - fragmentShader?: string; - linewidth?: number; - wireframe?: boolean; - wireframeLinewidth?: number; - lights?: boolean; - clipping?: boolean; - skinning?: boolean; - morphTargets?: boolean; - morphNormals?: boolean; - extensions?: { - derivatives?: boolean; - fragDepth?: boolean; - drawBuffers?: boolean; - shaderTextureLOD?: boolean; - }; - glslVersion?: GLSLVersion; -} - -export class ShaderMaterial extends Material { - - constructor( parameters?: ShaderMaterialParameters ); - - /** - * @default 'ShaderMaterial' - */ - type: string; - - /** - * @default {} - */ - defines: { [key: string]: any }; - - /** - * @default {} - */ - uniforms: { [uniform: string]: IUniform }; - vertexShader: string; - fragmentShader: string; - - /** - * @default 1 - */ - linewidth: number; - - /** - * @default false - */ - wireframe: boolean; - - /** - * @default 1 - */ - wireframeLinewidth: number; - - /** - * @default false - */ - fog: boolean; - - /** - * @default false - */ - lights: boolean; - - /** - * @default false - */ - clipping: boolean; - - /** - * @default false - */ - skinning: boolean; - - /** - * @default false - */ - morphTargets: boolean; - - /** - * @default false - */ - morphNormals: boolean; - /** - * @deprecated Use {@link ShaderMaterial#extensions.derivatives extensions.derivatives} instead. - */ - derivatives: any; - - /** - * @default { derivatives: false, fragDepth: false, drawBuffers: false, shaderTextureLOD: false } - */ - extensions: { - derivatives: boolean; - fragDepth: boolean; - drawBuffers: boolean; - shaderTextureLOD: boolean; - }; - - /** - * @default { 'color': [ 1, 1, 1 ], 'uv': [ 0, 0 ], 'uv2': [ 0, 0 ] } - */ - defaultAttributeValues: any; - - /** - * @default undefined - */ - index0AttributeName: string | undefined; - - /** - * @default false - */ - uniformsNeedUpdate: boolean; - - /** - * @default null - */ - glslVersion: GLSLVersion | null; - - setValues( parameters: ShaderMaterialParameters ): void; - toJSON( meta: any ): any; - -} diff --git a/src/materials/ShadowMaterial.d.ts b/src/materials/ShadowMaterial.d.ts deleted file mode 100644 index 8d98680f71199a..00000000000000 --- a/src/materials/ShadowMaterial.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { Color } from './../math/Color'; -import { MaterialParameters, Material } from './Material'; - -export interface ShadowMaterialParameters extends MaterialParameters { - color?: Color | string | number; -} - -export class ShadowMaterial extends Material { - - constructor( parameters?: ShadowMaterialParameters ); - - /** - * @default 'ShadowMaterial' - */ - type: string; - - /** - * @default new THREE.Color( 0x000000 ) - */ - color: Color; - - /** - * @default true - */ - transparent: boolean; - -} diff --git a/src/materials/SpriteMaterial.d.ts b/src/materials/SpriteMaterial.d.ts deleted file mode 100644 index bb13cdf745812c..00000000000000 --- a/src/materials/SpriteMaterial.d.ts +++ /dev/null @@ -1,56 +0,0 @@ -import { Color } from './../math/Color'; -import { Texture } from './../textures/Texture'; -import { MaterialParameters, Material } from './Material'; - -export interface SpriteMaterialParameters extends MaterialParameters { - color?: Color | string | number; - map?: Texture | null; - alphaMap?: Texture | null; - rotation?: number; - sizeAttenuation?: boolean; -} - -export class SpriteMaterial extends Material { - - constructor( parameters?: SpriteMaterialParameters ); - /** - * @default 'SpriteMaterial' - */ - type: string; - - /** - * @default new THREE.Color( 0xffffff ) - */ - color: Color; - - /** - * @default null - */ - map: Texture | null; - - /** - * @default null - */ - alphaMap: Texture | null; - - /** - * @default 0 - */ - rotation: number; - - /** - * @default true - */ - sizeAttenuation: boolean; - - /** - * @default true - */ - transparent: boolean; - - readonly isSpriteMaterial: true; - - setValues( parameters: SpriteMaterialParameters ): void; - copy( source: SpriteMaterial ): this; - -} diff --git a/src/math/Box2.d.ts b/src/math/Box2.d.ts deleted file mode 100644 index 07a8782d6585e6..00000000000000 --- a/src/math/Box2.d.ts +++ /dev/null @@ -1,50 +0,0 @@ -import { Vector2 } from './Vector2'; - -// Math ////////////////////////////////////////////////////////////////////////////////// - -export class Box2 { - - constructor( min?: Vector2, max?: Vector2 ); - - /** - * @default new THREE.Vector2( + Infinity, + Infinity ) - */ - min: Vector2; - - /** - * @default new THREE.Vector2( - Infinity, - Infinity ) - */ - max: Vector2; - - set( min: Vector2, max: Vector2 ): Box2; - setFromPoints( points: Vector2[] ): Box2; - setFromCenterAndSize( center: Vector2, size: Vector2 ): Box2; - clone(): Box2; - copy( box: Box2 ): this; - makeEmpty(): Box2; - isEmpty(): boolean; - getCenter( target: Vector2 ): Vector2; - getSize( target: Vector2 ): Vector2; - expandByPoint( point: Vector2 ): Box2; - expandByVector( vector: Vector2 ): Box2; - expandByScalar( scalar: number ): Box2; - containsPoint( point: Vector2 ): boolean; - containsBox( box: Box2 ): boolean; - getParameter( point: Vector2, target: Vector2 ): Vector2; - intersectsBox( box: Box2 ): boolean; - clampPoint( point: Vector2, target: Vector2 ): Vector2; - distanceToPoint( point: Vector2 ): number; - intersect( box: Box2 ): Box2; - union( box: Box2 ): Box2; - translate( offset: Vector2 ): Box2; - equals( box: Box2 ): boolean; - /** - * @deprecated Use {@link Box2#isEmpty .isEmpty()} instead. - */ - empty(): any; - /** - * @deprecated Use {@link Box2#intersectsBox .intersectsBox()} instead. - */ - isIntersectionBox( b: any ): any; - -} diff --git a/src/math/Box3.d.ts b/src/math/Box3.d.ts deleted file mode 100644 index f26e0dafe60172..00000000000000 --- a/src/math/Box3.d.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { BufferAttribute } from './../core/BufferAttribute'; -import { Vector3 } from './Vector3'; -import { Object3D } from './../core/Object3D'; -import { Sphere } from './Sphere'; -import { Plane } from './Plane'; -import { Matrix4 } from './Matrix4'; -import { Triangle } from './Triangle'; - -export class Box3 { - - constructor( min?: Vector3, max?: Vector3 ); - - /** - * @default new THREE.Vector3( + Infinity, + Infinity, + Infinity ) - */ - min: Vector3; - - /** - * @default new THREE.Vector3( - Infinity, - Infinity, - Infinity ) - */ - max: Vector3; - readonly isBox3: true; - - set( min: Vector3, max: Vector3 ): this; - setFromArray( array: ArrayLike ): this; - setFromBufferAttribute( bufferAttribute: BufferAttribute ): this; - setFromPoints( points: Vector3[] ): this; - setFromCenterAndSize( center: Vector3, size: Vector3 ): this; - setFromObject( object: Object3D ): this; - clone(): Box3; - copy( box: Box3 ): this; - makeEmpty(): this; - isEmpty(): boolean; - getCenter( target: Vector3 ): Vector3; - getSize( target: Vector3 ): Vector3; - expandByPoint( point: Vector3 ): this; - expandByVector( vector: Vector3 ): this; - expandByScalar( scalar: number ): this; - expandByObject( object: Object3D ): this; - containsPoint( point: Vector3 ): boolean; - containsBox( box: Box3 ): boolean; - getParameter( point: Vector3, target: Vector3 ): Vector3; - intersectsBox( box: Box3 ): boolean; - intersectsSphere( sphere: Sphere ): boolean; - intersectsPlane( plane: Plane ): boolean; - intersectsTriangle( triangle: Triangle ): boolean; - clampPoint( point: Vector3, target: Vector3 ): Vector3; - distanceToPoint( point: Vector3 ): number; - getBoundingSphere( target: Sphere ): Sphere; - intersect( box: Box3 ): this; - union( box: Box3 ): this; - applyMatrix4( matrix: Matrix4 ): this; - translate( offset: Vector3 ): this; - equals( box: Box3 ): boolean; - /** - * @deprecated Use {@link Box3#isEmpty .isEmpty()} instead. - */ - empty(): any; - /** - * @deprecated Use {@link Box3#intersectsBox .intersectsBox()} instead. - */ - isIntersectionBox( b: any ): any; - /** - * @deprecated Use {@link Box3#intersectsSphere .intersectsSphere()} instead. - */ - isIntersectionSphere( s: any ): any; - -} diff --git a/src/math/Color.d.ts b/src/math/Color.d.ts deleted file mode 100644 index c11a901986fc8d..00000000000000 --- a/src/math/Color.d.ts +++ /dev/null @@ -1,200 +0,0 @@ -import { BufferAttribute } from './../core/BufferAttribute'; - -export interface HSL { - h: number; - s: number; - l: number; -} - -/** - * Represents a color. See also {@link ColorUtils}. - * - * see {@link https://github.com/mrdoob/three.js/blob/master/src/math/Color.js|src/math/Color.js} - * - * @example - * const color = new THREE.Color( 0xff0000 ); - */ -export class Color { - - constructor( color?: Color | string | number ); - constructor( r: number, g: number, b: number ); - - readonly isColor: true; - - /** - * Red channel value between 0 and 1. Default is 1. - * @default 1 - */ - r: number; - - /** - * Green channel value between 0 and 1. Default is 1. - * @default 1 - */ - g: number; - - /** - * Blue channel value between 0 and 1. Default is 1. - * @default 1 - */ - b: number; - - set( color: Color | string | number ): Color; - setScalar( scalar: number ): Color; - setHex( hex: number ): Color; - - /** - * Sets this color from RGB values. - * @param r Red channel value between 0 and 1. - * @param g Green channel value between 0 and 1. - * @param b Blue channel value between 0 and 1. - */ - setRGB( r: number, g: number, b: number ): Color; - - /** - * Sets this color from HSL values. - * Based on MochiKit implementation by Bob Ippolito. - * - * @param h Hue channel value between 0 and 1. - * @param s Saturation value channel between 0 and 1. - * @param l Value channel value between 0 and 1. - */ - setHSL( h: number, s: number, l: number ): Color; - - /** - * Sets this color from a CSS context style string. - * @param contextStyle Color in CSS context style format. - */ - setStyle( style: string ): Color; - - /** - * Sets this color from a color name. - * Faster than {@link Color#setStyle .setStyle()} method if you don't need the other CSS-style formats. - * @param style Color name in X11 format. - */ - setColorName( style: string ): Color; - - /** - * Clones this color. - */ - clone(): Color; - - /** - * Copies given color. - * @param color Color to copy. - */ - copy( color: Color ): this; - - /** - * Copies given color making conversion from gamma to linear space. - * @param color Color to copy. - */ - copyGammaToLinear( color: Color, gammaFactor?: number ): Color; - - /** - * Copies given color making conversion from linear to gamma space. - * @param color Color to copy. - */ - copyLinearToGamma( color: Color, gammaFactor?: number ): Color; - - /** - * Converts this color from gamma to linear space. - */ - convertGammaToLinear( gammaFactor?: number ): Color; - - /** - * Converts this color from linear to gamma space. - */ - convertLinearToGamma( gammaFactor?: number ): Color; - - /** - * Copies given color making conversion from sRGB to linear space. - * @param color Color to copy. - */ - copySRGBToLinear( color: Color ): Color; - - /** - * Copies given color making conversion from linear to sRGB space. - * @param color Color to copy. - */ - copyLinearToSRGB( color: Color ): Color; - - /** - * Converts this color from sRGB to linear space. - */ - convertSRGBToLinear(): Color; - - /** - * Converts this color from linear to sRGB space. - */ - convertLinearToSRGB(): Color; - - /** - * Returns the hexadecimal value of this color. - */ - getHex(): number; - - /** - * Returns the string formated hexadecimal value of this color. - */ - getHexString(): string; - - getHSL( target: HSL ): HSL; - - /** - * Returns the value of this color in CSS context style. - * Example: rgb(r, g, b) - */ - getStyle(): string; - - offsetHSL( h: number, s: number, l: number ): this; - - add( color: Color ): this; - addColors( color1: Color, color2: Color ): this; - addScalar( s: number ): this; - sub( color: Color ): this; - multiply( color: Color ): this; - multiplyScalar( s: number ): this; - lerp( color: Color, alpha: number ): this; - lerpColors( color1: Color, color2: Color, alpha: number ): this; - lerpHSL( color: Color, alpha: number ): this; - equals( color: Color ): boolean; - - /** - * Sets this color's red, green and blue value from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): this; - - /** - * Sets this color's red, green and blue value from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): this; - - /** - * Returns an array [red, green, blue], or copies red, green and blue into the provided array. - * @param array (optional) array to store the color to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - - /** - * Copies red, green and blue into the provided array-like. - * @param array array-like to store the color to. - * @param offset (optional) optional offset into the array-like. - * @return The provided array-like. - */ - toArray( xyz: ArrayLike, offset?: number ): ArrayLike; - - fromBufferAttribute( attribute: BufferAttribute, index: number ): this; - - /** - * List of X11 color names. - */ - static NAMES: Record; - -} diff --git a/src/math/Cylindrical.d.ts b/src/math/Cylindrical.d.ts deleted file mode 100644 index 28b877cb4b8625..00000000000000 --- a/src/math/Cylindrical.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Vector3 } from './Vector3'; - -export class Cylindrical { - - constructor( radius?: number, theta?: number, y?: number ); - - /** - * @default 1 - */ - radius: number; - - /** - * @default 0 - */ - theta: number; - - /** - * @default 0 - */ - y: number; - - clone(): Cylindrical; - copy( other: Cylindrical ): this; - set( radius: number, theta: number, y: number ): this; - setFromVector3( vec3: Vector3 ): this; - setFromCartesianCoords( x: number, y: number, z: number ): this; - -} diff --git a/src/math/Euler.d.ts b/src/math/Euler.d.ts deleted file mode 100644 index da395c021524c9..00000000000000 --- a/src/math/Euler.d.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Matrix4 } from './Matrix4'; -import { Quaternion } from './Quaternion'; -import { Vector3 } from './Vector3'; - -export class Euler { - - constructor( x?: number, y?: number, z?: number, order?: string ); - - /** - * @default 0 - */ - x: number; - - /** - * @default 0 - */ - y: number; - - /** - * @default 0 - */ - z: number; - - /** - * @default THREE.Euler.DefaultOrder - */ - order: string; - readonly isEuler: true; - - _onChangeCallback: Function; - - set( x: number, y: number, z: number, order?: string ): Euler; - clone(): Euler; - copy( euler: Euler ): this; - setFromRotationMatrix( m: Matrix4, order?: string ): Euler; - setFromQuaternion( q: Quaternion, order?: string ): Euler; - setFromVector3( v: Vector3, order?: string ): Euler; - reorder( newOrder: string ): Euler; - equals( euler: Euler ): boolean; - fromArray( xyzo: any[] ): Euler; - toArray( array?: number[], offset?: number ): number[]; - toVector3( optionalResult?: Vector3 ): Vector3; - _onChange( callback: Function ): this; - - static RotationOrders: string[]; - static DefaultOrder: string; - -} diff --git a/src/math/Frustum.d.ts b/src/math/Frustum.d.ts deleted file mode 100644 index f32c0ce5a6f888..00000000000000 --- a/src/math/Frustum.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { Plane } from './Plane'; -import { Matrix4 } from './Matrix4'; -import { Object3D } from './../core/Object3D'; -import { Sprite } from './../objects/Sprite'; -import { Sphere } from './Sphere'; -import { Box3 } from './Box3'; -import { Vector3 } from './Vector3'; - -/** - * Frustums are used to determine what is inside the camera's field of view. They help speed up the rendering process. - */ -export class Frustum { - - constructor( - p0?: Plane, - p1?: Plane, - p2?: Plane, - p3?: Plane, - p4?: Plane, - p5?: Plane - ); - - /** - * Array of 6 vectors. - */ - planes: Plane[]; - - set( - p0: Plane, - p1: Plane, - p2: Plane, - p3: Plane, - p4: Plane, - p5: Plane - ): Frustum; - clone(): Frustum; - copy( frustum: Frustum ): this; - setFromProjectionMatrix( m: Matrix4 ): this; - intersectsObject( object: Object3D ): boolean; - intersectsSprite( sprite: Sprite ): boolean; - intersectsSphere( sphere: Sphere ): boolean; - intersectsBox( box: Box3 ): boolean; - containsPoint( point: Vector3 ): boolean; - -} diff --git a/src/math/Interpolant.d.ts b/src/math/Interpolant.d.ts deleted file mode 100644 index 42b65e52318740..00000000000000 --- a/src/math/Interpolant.d.ts +++ /dev/null @@ -1,17 +0,0 @@ -export abstract class Interpolant { - - constructor( - parameterPositions: any, - sampleValues: any, - sampleSize: number, - resultBuffer?: any - ); - - parameterPositions: any; - sampleValues: any; - valueSize: number; - resultBuffer: any; - - evaluate( time: number ): any; - -} diff --git a/src/math/Line3.d.ts b/src/math/Line3.d.ts deleted file mode 100644 index e40ab24e58baa8..00000000000000 --- a/src/math/Line3.d.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { Vector3 } from './Vector3'; -import { Matrix4 } from './Matrix4'; - -export class Line3 { - - constructor( start?: Vector3, end?: Vector3 ); - - /** - * @default new THREE.Vector3() - */ - start: Vector3; - - /** - * @default new THREE.Vector3() - */ - end: Vector3; - - set( start?: Vector3, end?: Vector3 ): Line3; - clone(): Line3; - copy( line: Line3 ): this; - getCenter( target: Vector3 ): Vector3; - delta( target: Vector3 ): Vector3; - distanceSq(): number; - distance(): number; - at( t: number, target: Vector3 ): Vector3; - closestPointToPointParameter( point: Vector3, clampToLine?: boolean ): number; - closestPointToPoint( - point: Vector3, - clampToLine: boolean, - target: Vector3 - ): Vector3; - applyMatrix4( matrix: Matrix4 ): Line3; - equals( line: Line3 ): boolean; - -} diff --git a/src/math/MathUtils.d.ts b/src/math/MathUtils.d.ts deleted file mode 100644 index 9314849b232ef5..00000000000000 --- a/src/math/MathUtils.d.ts +++ /dev/null @@ -1,124 +0,0 @@ -import { Quaternion } from './Quaternion'; - -/** - * @see {@link https://github.com/mrdoob/three.js/blob/master/src/math/MathUtils.js|src/math/MathUtils.js} - */ -export namespace MathUtils { - export const DEG2RAD: number; - export const RAD2DEG: number; - - export function generateUUID(): string; - - /** - * Clamps the x to be between a and b. - * - * @param value Value to be clamped. - * @param min Minimum value - * @param max Maximum value. - */ - export function clamp( value: number, min: number, max: number ): number; - export function euclideanModulo( n: number, m: number ): number; - - /** - * Linear mapping of x from range [a1, a2] to range [b1, b2]. - * - * @param x Value to be mapped. - * @param a1 Minimum value for range A. - * @param a2 Maximum value for range A. - * @param b1 Minimum value for range B. - * @param b2 Maximum value for range B. - */ - export function mapLinear( - x: number, - a1: number, - a2: number, - b1: number, - b2: number - ): number; - - export function smoothstep( x: number, min: number, max: number ): number; - - export function smootherstep( x: number, min: number, max: number ): number; - - /** - * Random float from 0 to 1 with 16 bits of randomness. - * Standard Math.random() creates repetitive patterns when applied over larger space. - * - * @deprecated Use {@link Math#random Math.random()} - */ - export function random16(): number; - - /** - * Random integer from low to high interval. - */ - export function randInt( low: number, high: number ): number; - - /** - * Random float from low to high interval. - */ - export function randFloat( low: number, high: number ): number; - - /** - * Random float from - range / 2 to range / 2 interval. - */ - export function randFloatSpread( range: number ): number; - - /** - * Deterministic pseudo-random float in the interval [ 0, 1 ]. - */ - export function seededRandom( seed?: number ): number; - - export function degToRad( degrees: number ): number; - - export function radToDeg( radians: number ): number; - - export function isPowerOfTwo( value: number ): boolean; - - /** - * Returns a value linearly interpolated from two known points based - * on the given interval - t = 0 will return x and t = 1 will return y. - * - * @param x Start point. - * @param y End point. - * @param t interpolation factor in the closed interval [0, 1] - * @return {number} - */ - export function lerp( x: number, y: number, t: number ): number; - - /** - * Smoothly interpolate a number from x toward y in a spring-like - * manner using the dt to maintain frame rate independent movement. - * - * @param x Current point. - * @param y Target point. - * @param lambda A higher lambda value will make the movement more sudden, and a lower value will make the movement more gradual. - * @param dt Delta time in seconds. - * @return {number} - */ - export function damp( x: number, y: number, lambda: number, dt: number ): number; - - /** - * Returns a value that alternates between 0 and length. - * - * @param x The value to pingpong. - * @param length The positive value the function will pingpong to. Default is 1. - * @return {number} - */ - export function pingpong( x: number, length?: number ): number; - - /** - * @deprecated Use {@link Math#floorPowerOfTwo .floorPowerOfTwo()} - */ - export function nearestPowerOfTwo( value: number ): number; - - /** - * @deprecated Use {@link Math#ceilPowerOfTwo .ceilPowerOfTwo()} - */ - export function nextPowerOfTwo( value: number ): number; - - export function floorPowerOfTwo( value: number ): number; - - export function ceilPowerOfTwo( value: number ): number; - - export function setQuaternionFromProperEuler( q: Quaternion, a: number, b: number, c: number, order: string ): void; -} diff --git a/src/math/Matrix3.d.ts b/src/math/Matrix3.d.ts deleted file mode 100644 index 375ad32105d062..00000000000000 --- a/src/math/Matrix3.d.ts +++ /dev/null @@ -1,177 +0,0 @@ -import { Matrix4 } from './Matrix4'; -import { Vector3 } from './Vector3'; - -type Matrix3Tuple = [ - number, number, number, - number, number, number, - number, number, number, -]; - -/** - * ( interface Matrix ) - */ -export interface Matrix { - /** - * Array with matrix values. - */ - elements: number[]; - - /** - * identity():T; - */ - identity(): Matrix; - - /** - * copy(m:T):T; - */ - copy( m: this ): this; - - /** - * multiplyScalar(s:number):T; - */ - multiplyScalar( s: number ): Matrix; - - determinant(): number; - - /** - * transpose():T; - */ - transpose(): Matrix; - - /** - * invert():T; - */ - invert(): Matrix; - - /** - * clone():T; - */ - clone(): Matrix; -} - -/** - * ( class Matrix3 implements Matrix ) - */ -export class Matrix3 implements Matrix { - - /** - * Creates an identity matrix. - */ - constructor(); - - /** - * Array with matrix values. - * @default [1, 0, 0, 0, 1, 0, 0, 0, 1] - */ - elements: number[]; - - set( - n11: number, - n12: number, - n13: number, - n21: number, - n22: number, - n23: number, - n31: number, - n32: number, - n33: number - ): Matrix3; - identity(): Matrix3; - clone(): Matrix3; - copy( m: Matrix3 ): this; - extractBasis( xAxis: Vector3, yAxis: Vector3, zAxis: Vector3 ): Matrix3; - setFromMatrix4( m: Matrix4 ): Matrix3; - multiplyScalar( s: number ): Matrix3; - determinant(): number; - - /** - * Inverts this matrix in place. - */ - invert(): Matrix3; - - /** - * Transposes this matrix in place. - */ - transpose(): Matrix3; - getNormalMatrix( matrix4: Matrix4 ): Matrix3; - - /** - * Transposes this matrix into the supplied array r, and returns itself. - */ - transposeIntoArray( r: number[] ): Matrix3; - - setUvTransform( tx: number, ty: number, sx: number, sy: number, rotation: number, cx: number, cy: number ): Matrix3; - - scale( sx: number, sy: number ): Matrix3; - - rotate( theta: number ): Matrix3; - - translate( tx: number, ty: number ): Matrix3; - - equals( matrix: Matrix3 ): boolean; - - /** - * Sets the values of this matrix from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): Matrix3; - - /** - * Sets the values of this matrix from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): Matrix3; - - /** - * Returns an array with the values of this matrix, or copies them into the provided array. - * @param array (optional) array to store the matrix to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - toArray( array?: Matrix3Tuple, offset?: 0 ): Matrix3Tuple; - - /** - * Copies he values of this matrix into the provided array-like. - * @param array array-like to store the matrix to. - * @param offset (optional) optional offset into the array-like. - * @return The provided array-like. - */ - toArray( array?: ArrayLike, offset?: number ): ArrayLike; - - /** - * Multiplies this matrix by m. - */ - multiply( m: Matrix3 ): Matrix3; - - premultiply( m: Matrix3 ): Matrix3; - - /** - * Sets this matrix to a x b. - */ - multiplyMatrices( a: Matrix3, b: Matrix3 ): Matrix3; - - /** - * @deprecated Use {@link Vector3.applyMatrix3 vector.applyMatrix3( matrix )} instead. - */ - multiplyVector3( vector: Vector3 ): any; - - /** - * @deprecated This method has been removed completely. - */ - multiplyVector3Array( a: any ): any; - getInverse( matrix: Matrix4, throwOnDegenerate?: boolean ): Matrix3; - - /** - * @deprecated Use {@link Matrix3#toArray .toArray()} instead. - */ - flattenToArrayOffset( array: number[], offset: number ): number[]; - - /** - * @deprecated Use {@link Matrix3#invert .invert()} instead. - */ - getInverse( matrix: Matrix ): Matrix; - -} diff --git a/src/math/Matrix4.d.ts b/src/math/Matrix4.d.ts deleted file mode 100644 index 3b84438c52845a..00000000000000 --- a/src/math/Matrix4.d.ts +++ /dev/null @@ -1,301 +0,0 @@ -import { Vector3 } from './Vector3'; -import { Euler } from './Euler'; -import { Quaternion } from './Quaternion'; -import { Matrix } from './Matrix3'; - -type Matrix4Tuple = [ - number, number, number, number, - number, number, number, number, - number, number, number, number, - number, number, number, number, -]; - -/** - * A 4x4 Matrix. - * - * @example - * // Simple rig for rotating around 3 axes - * const m = new THREE.Matrix4(); - * const m1 = new THREE.Matrix4(); - * const m2 = new THREE.Matrix4(); - * const m3 = new THREE.Matrix4(); - * const alpha = 0; - * const beta = Math.PI; - * const gamma = Math.PI/2; - * m1.makeRotationX( alpha ); - * m2.makeRotationY( beta ); - * m3.makeRotationZ( gamma ); - * m.multiplyMatrices( m1, m2 ); - * m.multiply( m3 ); - */ -export class Matrix4 implements Matrix { - - constructor(); - - /** - * Array with matrix values. - * @default [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1] - */ - elements: number[]; - - /** - * Sets all fields of this matrix. - */ - set( - n11: number, - n12: number, - n13: number, - n14: number, - n21: number, - n22: number, - n23: number, - n24: number, - n31: number, - n32: number, - n33: number, - n34: number, - n41: number, - n42: number, - n43: number, - n44: number - ): Matrix4; - - /** - * Resets this matrix to identity. - */ - identity(): Matrix4; - clone(): Matrix4; - copy( m: Matrix4 ): this; - copyPosition( m: Matrix4 ): Matrix4; - extractBasis( xAxis: Vector3, yAxis: Vector3, zAxis: Vector3 ): Matrix4; - makeBasis( xAxis: Vector3, yAxis: Vector3, zAxis: Vector3 ): Matrix4; - - /** - * Copies the rotation component of the supplied matrix m into this matrix rotation component. - */ - extractRotation( m: Matrix4 ): Matrix4; - makeRotationFromEuler( euler: Euler ): Matrix4; - makeRotationFromQuaternion( q: Quaternion ): Matrix4; - /** - * Constructs a rotation matrix, looking from eye towards center with defined up vector. - */ - lookAt( eye: Vector3, target: Vector3, up: Vector3 ): Matrix4; - - /** - * Multiplies this matrix by m. - */ - multiply( m: Matrix4 ): Matrix4; - - premultiply( m: Matrix4 ): Matrix4; - - /** - * Sets this matrix to a x b. - */ - multiplyMatrices( a: Matrix4, b: Matrix4 ): Matrix4; - - /** - * Sets this matrix to a x b and stores the result into the flat array r. - * r can be either a regular Array or a TypedArray. - * - * @deprecated This method has been removed completely. - */ - multiplyToArray( a: Matrix4, b: Matrix4, r: number[] ): Matrix4; - - /** - * Multiplies this matrix by s. - */ - multiplyScalar( s: number ): Matrix4; - - /** - * Computes determinant of this matrix. - * Based on http://www.euclideanspace.com/maths/algebra/matrix/functions/inverse/fourD/index.htm - */ - determinant(): number; - - /** - * Transposes this matrix. - */ - transpose(): Matrix4; - - /** - * Sets the position component for this matrix from vector v. - */ - setPosition( v: Vector3 | number, y?: number, z?: number ): Matrix4; - - /** - * Inverts this matrix. - */ - invert(): Matrix4; - - /** - * Multiplies the columns of this matrix by vector v. - */ - scale( v: Vector3 ): Matrix4; - - getMaxScaleOnAxis(): number; - /** - * Sets this matrix as translation transform. - */ - makeTranslation( x: number, y: number, z: number ): Matrix4; - - /** - * Sets this matrix as rotation transform around x axis by theta radians. - * - * @param theta Rotation angle in radians. - */ - makeRotationX( theta: number ): Matrix4; - - /** - * Sets this matrix as rotation transform around y axis by theta radians. - * - * @param theta Rotation angle in radians. - */ - makeRotationY( theta: number ): Matrix4; - - /** - * Sets this matrix as rotation transform around z axis by theta radians. - * - * @param theta Rotation angle in radians. - */ - makeRotationZ( theta: number ): Matrix4; - - /** - * Sets this matrix as rotation transform around axis by angle radians. - * Based on http://www.gamedev.net/reference/articles/article1199.asp. - * - * @param axis Rotation axis. - * @param theta Rotation angle in radians. - */ - makeRotationAxis( axis: Vector3, angle: number ): Matrix4; - - /** - * Sets this matrix as scale transform. - */ - makeScale( x: number, y: number, z: number ): Matrix4; - - /** - * Sets this matrix to the transformation composed of translation, rotation and scale. - */ - compose( translation: Vector3, rotation: Quaternion, scale: Vector3 ): Matrix4; - - /** - * Decomposes this matrix into it's position, quaternion and scale components. - */ - decompose( - translation: Vector3, - rotation: Quaternion, - scale: Vector3 - ): Matrix4; - - /** - * Creates a frustum matrix. - */ - makePerspective( - left: number, - right: number, - bottom: number, - top: number, - near: number, - far: number - ): Matrix4; - - /** - * Creates a perspective projection matrix. - */ - makePerspective( - fov: number, - aspect: number, - near: number, - far: number - ): Matrix4; - - /** - * Creates an orthographic projection matrix. - */ - makeOrthographic( - left: number, - right: number, - top: number, - bottom: number, - near: number, - far: number - ): Matrix4; - equals( matrix: Matrix4 ): boolean; - - /** - * Sets the values of this matrix from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): Matrix4; - - /** - * Sets the values of this matrix from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): Matrix4; - - /** - * Returns an array with the values of this matrix, or copies them into the provided array. - * @param array (optional) array to store the matrix to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - toArray( array?: Matrix4Tuple, offset?: 0 ): Matrix4Tuple; - - /** - * Copies he values of this matrix into the provided array-like. - * @param array array-like to store the matrix to. - * @param offset (optional) optional offset into the array-like. - * @return The provided array-like. - */ - toArray( array?: ArrayLike, offset?: number ): ArrayLike; - - /** - * @deprecated Use {@link Matrix4#copyPosition .copyPosition()} instead. - */ - extractPosition( m: Matrix4 ): Matrix4; - - /** - * @deprecated Use {@link Matrix4#makeRotationFromQuaternion .makeRotationFromQuaternion()} instead. - */ - setRotationFromQuaternion( q: Quaternion ): Matrix4; - - /** - * @deprecated Use {@link Vector3#applyMatrix4 vector.applyMatrix4( matrix )} instead. - */ - multiplyVector3( v: any ): any; - - /** - * @deprecated Use {@link Vector4#applyMatrix4 vector.applyMatrix4( matrix )} instead. - */ - multiplyVector4( v: any ): any; - - /** - * @deprecated This method has been removed completely. - */ - multiplyVector3Array( array: number[] ): number[]; - - /** - * @deprecated Use {@link Vector3#transformDirection Vector3.transformDirection( matrix )} instead. - */ - rotateAxis( v: any ): void; - - /** - * @deprecated Use {@link Vector3#applyMatrix4 vector.applyMatrix4( matrix )} instead. - */ - crossVector( v: any ): void; - - /** - * @deprecated Use {@link Matrix4#toArray .toArray()} instead. - */ - flattenToArrayOffset( array: number[], offset: number ): number[]; - - /** - * @deprecated Use {@link Matrix4#invert .invert()} instead. - */ - getInverse( matrix: Matrix ): Matrix; - -} diff --git a/src/math/Plane.d.ts b/src/math/Plane.d.ts deleted file mode 100644 index e1ba1420f23d09..00000000000000 --- a/src/math/Plane.d.ts +++ /dev/null @@ -1,50 +0,0 @@ -import { Vector3 } from './Vector3'; -import { Sphere } from './Sphere'; -import { Line3 } from './Line3'; -import { Box3 } from './Box3'; -import { Matrix4 } from './Matrix4'; -import { Matrix3 } from './Matrix3'; - -export class Plane { - - constructor( normal?: Vector3, constant?: number ); - - /** - * @default new THREE.Vector3( 1, 0, 0 ) - */ - normal: Vector3; - - /** - * @default 0 - */ - constant: number; - - readonly isPlane: true; - - set( normal: Vector3, constant: number ): Plane; - setComponents( x: number, y: number, z: number, w: number ): Plane; - setFromNormalAndCoplanarPoint( normal: Vector3, point: Vector3 ): Plane; - setFromCoplanarPoints( a: Vector3, b: Vector3, c: Vector3 ): Plane; - clone(): Plane; - copy( plane: Plane ): this; - normalize(): Plane; - negate(): Plane; - distanceToPoint( point: Vector3 ): number; - distanceToSphere( sphere: Sphere ): number; - projectPoint( point: Vector3, target: Vector3 ): Vector3; - orthoPoint( point: Vector3, target: Vector3 ): Vector3; - intersectLine( line: Line3, target: Vector3 ): Vector3 | undefined; - intersectsLine( line: Line3 ): boolean; - intersectsBox( box: Box3 ): boolean; - intersectsSphere( sphere: Sphere ): boolean; - coplanarPoint( target: Vector3 ): Vector3; - applyMatrix4( matrix: Matrix4, optionalNormalMatrix?: Matrix3 ): Plane; - translate( offset: Vector3 ): Plane; - equals( plane: Plane ): boolean; - - /** - * @deprecated Use {@link Plane#intersectsLine .intersectsLine()} instead. - */ - isIntersectionLine( l: any ): any; - -} diff --git a/src/math/Quaternion.d.ts b/src/math/Quaternion.d.ts deleted file mode 100644 index 6ea08ae87bf489..00000000000000 --- a/src/math/Quaternion.d.ts +++ /dev/null @@ -1,188 +0,0 @@ -import { Euler } from './Euler'; -import { Vector3 } from './Vector3'; -import { Matrix4 } from './Matrix4'; - -/** - * Implementation of a quaternion. This is used for rotating things without incurring in the dreaded gimbal lock issue, amongst other advantages. - * - * @example - * const quaternion = new THREE.Quaternion(); - * quaternion.setFromAxisAngle( new THREE.Vector3( 0, 1, 0 ), Math.PI / 2 ); - * const vector = new THREE.Vector3( 1, 0, 0 ); - * vector.applyQuaternion( quaternion ); - */ -export class Quaternion { - - /** - * @param x x coordinate - * @param y y coordinate - * @param z z coordinate - * @param w w coordinate - */ - constructor( x?: number, y?: number, z?: number, w?: number ); - - /** - * @default 0 - */ - x: number; - - /** - * @default 0 - */ - y: number; - - /** - * @default 0 - */ - z: number; - - /** - * @default 1 - */ - w: number; - readonly isQuaternion: true; - - /** - * Sets values of this quaternion. - */ - set( x: number, y: number, z: number, w: number ): Quaternion; - - /** - * Clones this quaternion. - */ - clone(): Quaternion; - - /** - * Copies values of q to this quaternion. - */ - copy( q: Quaternion ): this; - - /** - * Sets this quaternion from rotation specified by Euler angles. - */ - setFromEuler( euler: Euler ): Quaternion; - - /** - * Sets this quaternion from rotation specified by axis and angle. - * Adapted from http://www.euclideanspace.com/maths/geometry/rotations/conversions/angleToQuaternion/index.htm. - * Axis have to be normalized, angle is in radians. - */ - setFromAxisAngle( axis: Vector3, angle: number ): Quaternion; - - /** - * Sets this quaternion from rotation component of m. Adapted from http://www.euclideanspace.com/maths/geometry/rotations/conversions/matrixToQuaternion/index.htm. - */ - setFromRotationMatrix( m: Matrix4 ): Quaternion; - setFromUnitVectors( vFrom: Vector3, vTo: Vector3 ): Quaternion; - angleTo( q: Quaternion ): number; - rotateTowards( q: Quaternion, step: number ): Quaternion; - - identity(): Quaternion; - - /** - * Inverts this quaternion. - */ - invert(): Quaternion; - - conjugate(): Quaternion; - dot( v: Quaternion ): number; - lengthSq(): number; - - /** - * Computes length of this quaternion. - */ - length(): number; - - /** - * Normalizes this quaternion. - */ - normalize(): Quaternion; - - /** - * Multiplies this quaternion by b. - */ - multiply( q: Quaternion ): Quaternion; - premultiply( q: Quaternion ): Quaternion; - - /** - * Sets this quaternion to a x b - * Adapted from http://www.euclideanspace.com/maths/algebra/realNormedAlgebra/quaternions/code/index.htm. - */ - multiplyQuaternions( a: Quaternion, b: Quaternion ): Quaternion; - - slerp( qb: Quaternion, t: number ): Quaternion; - equals( v: Quaternion ): boolean; - - /** - * Sets this quaternion's x, y, z and w value from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): this; - - /** - * Sets this quaternion's x, y, z and w value from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): this; - - /** - * Returns an array [x, y, z, w], or copies x, y, z and w into the provided array. - * @param array (optional) array to store the quaternion to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - - /** - * Copies x, y, z and w into the provided array-like. - * @param array array-like to store the quaternion to. - * @param offset (optional) optional offset into the array. - * @return The provided array-like. - */ - toArray( array: ArrayLike, offset?: number ): ArrayLike; - - _onChange( callback: Function ): Quaternion; - _onChangeCallback: Function; - - /** - * Adapted from http://www.euclideanspace.com/maths/algebra/realNormedAlgebra/quaternions/slerp/. - */ - static slerp( - qa: Quaternion, - qb: Quaternion, - qm: Quaternion, - t: number - ): Quaternion; - - static slerpFlat( - dst: number[], - dstOffset: number, - src0: number[], - srcOffset: number, - src1: number[], - stcOffset1: number, - t: number - ): Quaternion; - - static multiplyQuaternionsFlat( - dst: number[], - dstOffset: number, - src0: number[], - srcOffset: number, - src1: number[], - stcOffset1: number - ): number[]; - - /** - * @deprecated Use {@link Vector#applyQuaternion vector.applyQuaternion( quaternion )} instead. - */ - multiplyVector3( v: any ): any; - - /** - * @deprecated Use {@link Quaternion#invert .invert()} instead. - */ - inverse(): Quaternion; - -} diff --git a/src/math/Ray.d.ts b/src/math/Ray.d.ts deleted file mode 100644 index a069facca4e1d6..00000000000000 --- a/src/math/Ray.d.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { Vector3 } from './Vector3'; -import { Sphere } from './Sphere'; -import { Plane } from './Plane'; -import { Box3 } from './Box3'; -import { Matrix4 } from './Matrix4'; - -export class Ray { - - constructor( origin?: Vector3, direction?: Vector3 ); - - /** - * @default new THREE.Vector3() - */ - origin: Vector3; - - /** - * @default new THREE.Vector3( 0, 0, - 1 ) - */ - direction: Vector3; - - set( origin: Vector3, direction: Vector3 ): Ray; - clone(): Ray; - copy( ray: Ray ): this; - at( t: number, target: Vector3 ): Vector3; - lookAt( v: Vector3 ): Ray; - recast( t: number ): Ray; - closestPointToPoint( point: Vector3, target: Vector3 ): Vector3; - distanceToPoint( point: Vector3 ): number; - distanceSqToPoint( point: Vector3 ): number; - distanceSqToSegment( - v0: Vector3, - v1: Vector3, - optionalPointOnRay?: Vector3, - optionalPointOnSegment?: Vector3 - ): number; - intersectSphere( sphere: Sphere, target: Vector3 ): Vector3 | null; - intersectsSphere( sphere: Sphere ): boolean; - distanceToPlane( plane: Plane ): number; - intersectPlane( plane: Plane, target: Vector3 ): Vector3 | null; - intersectsPlane( plane: Plane ): boolean; - intersectBox( box: Box3, target: Vector3 ): Vector3 | null; - intersectsBox( box: Box3 ): boolean; - intersectTriangle( - a: Vector3, - b: Vector3, - c: Vector3, - backfaceCulling: boolean, - target: Vector3 - ): Vector3 | null; - applyMatrix4( matrix4: Matrix4 ): Ray; - equals( ray: Ray ): boolean; - - /** - * @deprecated Use {@link Ray#intersectsBox .intersectsBox()} instead. - */ - isIntersectionBox( b: any ): any; - - /** - * @deprecated Use {@link Ray#intersectsPlane .intersectsPlane()} instead. - */ - isIntersectionPlane( p: any ): any; - - /** - * @deprecated Use {@link Ray#intersectsSphere .intersectsSphere()} instead. - */ - isIntersectionSphere( s: any ): any; - -} diff --git a/src/math/Sphere.d.ts b/src/math/Sphere.d.ts deleted file mode 100644 index 7013bcb997c0ab..00000000000000 --- a/src/math/Sphere.d.ts +++ /dev/null @@ -1,42 +0,0 @@ -import { Vector3 } from './Vector3'; -import { Box3 } from './Box3'; -import { Plane } from './Plane'; -import { Matrix4 } from './Matrix4'; - -export class Sphere { - - constructor( center?: Vector3, radius?: number ); - - /** - * @default new Vector3() - */ - center: Vector3; - - /** - * @default 1 - */ - radius: number; - - set( center: Vector3, radius: number ): Sphere; - setFromPoints( points: Vector3[], optionalCenter?: Vector3 ): Sphere; - clone(): Sphere; - copy( sphere: Sphere ): this; - isEmpty(): boolean; - makeEmpty(): this; - containsPoint( point: Vector3 ): boolean; - distanceToPoint( point: Vector3 ): number; - intersectsSphere( sphere: Sphere ): boolean; - intersectsBox( box: Box3 ): boolean; - intersectsPlane( plane: Plane ): boolean; - clampPoint( point: Vector3, target: Vector3 ): Vector3; - getBoundingBox( target: Box3 ): Box3; - applyMatrix4( matrix: Matrix4 ): Sphere; - translate( offset: Vector3 ): Sphere; - equals( sphere: Sphere ): boolean; - - /** - * @deprecated Use {@link Sphere#isEmpty .isEmpty()} instead. - */ - empty(): any; - -} diff --git a/src/math/Spherical.d.ts b/src/math/Spherical.d.ts deleted file mode 100644 index 23d80ba1ac91ad..00000000000000 --- a/src/math/Spherical.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { Vector3 } from './Vector3'; - -export class Spherical { - - constructor( radius?: number, phi?: number, theta?: number ); - - /** - * @default 1 - */ - radius: number; - - /** - * @default 0 - */ - phi: number; - - /** - * @default 0 - */ - theta: number; - - set( radius: number, phi: number, theta: number ): this; - clone(): Spherical; - copy( other: Spherical ): this; - makeSafe(): this; - setFromVector3( v: Vector3 ): this; - setFromCartesianCoords( x: number, y: number, z: number ): this; - -} diff --git a/src/math/SphericalHarmonics3.d.ts b/src/math/SphericalHarmonics3.d.ts deleted file mode 100644 index 0f3f6486de4260..00000000000000 --- a/src/math/SphericalHarmonics3.d.ts +++ /dev/null @@ -1,58 +0,0 @@ -import { Vector3 } from './Vector3'; - -export class SphericalHarmonics3 { - - constructor(); - - /** - * @default [new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3(), new THREE.Vector3()] - */ - coefficients: Vector3[]; - readonly isSphericalHarmonics3: true; - - set ( coefficients: Vector3[] ): SphericalHarmonics3; - zero(): SphericalHarmonics3; - add( sh: SphericalHarmonics3 ): SphericalHarmonics3; - addScaledSH( sh: SphericalHarmonics3, s: number ): SphericalHarmonics3; - scale( s: number ): SphericalHarmonics3; - lerp( sh: SphericalHarmonics3, alpha: number ): SphericalHarmonics3; - equals( sh: SphericalHarmonics3 ): boolean; - copy( sh: SphericalHarmonics3 ): SphericalHarmonics3; - clone(): SphericalHarmonics3; - - /** - * Sets the values of this spherical harmonics from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): this; - - /** - * Sets the values of this spherical harmonics from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): this; - - /** - * Returns an array with the values of this spherical harmonics, or copies them into the provided array. - * @param array (optional) array to store the spherical harmonics to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - - /** - * Returns an array with the values of this spherical harmonics, or copies them into the provided array-like. - * @param array array-like to store the spherical harmonics to. - * @param offset (optional) optional offset into the array-like. - * @return The provided array-like. - */ - toArray( array: ArrayLike, offset?: number ): ArrayLike; - - getAt( normal: Vector3, target: Vector3 ) : Vector3; - getIrradianceAt( normal: Vector3, target: Vector3 ) : Vector3; - - static getBasisAt( normal: Vector3, shBasis: number[] ): void; - -} diff --git a/src/math/Triangle.d.ts b/src/math/Triangle.d.ts deleted file mode 100644 index 643ae9305be37f..00000000000000 --- a/src/math/Triangle.d.ts +++ /dev/null @@ -1,82 +0,0 @@ -import { Vector2 } from './Vector2'; -import { Vector3 } from './Vector3'; -import { Plane } from './Plane'; -import { Box3 } from './Box3'; - -export class Triangle { - - constructor( a?: Vector3, b?: Vector3, c?: Vector3 ); - - /** - * @default new THREE.Vector3() - */ - a: Vector3; - - /** - * @default new THREE.Vector3() - */ - b: Vector3; - - /** - * @default new THREE.Vector3() - */ - c: Vector3; - - set( a: Vector3, b: Vector3, c: Vector3 ): Triangle; - setFromPointsAndIndices( - points: Vector3[], - i0: number, - i1: number, - i2: number - ): Triangle; - clone(): Triangle; - copy( triangle: Triangle ): this; - getArea(): number; - getMidpoint( target: Vector3 ): Vector3; - getNormal( target: Vector3 ): Vector3; - getPlane( target: Plane ): Plane; - getBarycoord( point: Vector3, target: Vector3 ): Vector3; - getUV( point: Vector3, uv1: Vector2, uv2: Vector2, uv3: Vector2, target: Vector2 ): Vector2; - containsPoint( point: Vector3 ): boolean; - intersectsBox( box: Box3 ): boolean; - isFrontFacing( direction: Vector3 ): boolean; - closestPointToPoint( point: Vector3, target: Vector3 ): Vector3; - equals( triangle: Triangle ): boolean; - - static getNormal( - a: Vector3, - b: Vector3, - c: Vector3, - target: Vector3 - ): Vector3; - static getBarycoord( - point: Vector3, - a: Vector3, - b: Vector3, - c: Vector3, - target: Vector3 - ): Vector3; - static containsPoint( - point: Vector3, - a: Vector3, - b: Vector3, - c: Vector3 - ): boolean; - static getUV( - point: Vector3, - p1: Vector3, - p2: Vector3, - p3: Vector3, - uv1: Vector2, - uv2: Vector2, - uv3: Vector2, - target: Vector2 - ): Vector2; - static isFrontFacing( - a: Vector3, - b: Vector3, - c: Vector3, - direction: Vector3 - ): boolean; - -} diff --git a/src/math/Vector2.d.ts b/src/math/Vector2.d.ts deleted file mode 100644 index b466e6c18f504b..00000000000000 --- a/src/math/Vector2.d.ts +++ /dev/null @@ -1,461 +0,0 @@ -import { Matrix3 } from './Matrix3'; -import { BufferAttribute } from './../core/BufferAttribute'; - -type Vector2tuple = [number, number]; - -/** - * ( interface Vector ) - * - * Abstract interface of {@link https://github.com/mrdoob/three.js/blob/master/src/math/Vector2.js|Vector2}, - * {@link https://github.com/mrdoob/three.js/blob/master/src/math/Vector3.js|Vector3} - * and {@link https://github.com/mrdoob/three.js/blob/master/src/math/Vector4.js|Vector4}. - * - * Currently the members of Vector is NOT type safe because it accepts different typed vectors. - * - * Those definitions will be changed when TypeScript innovates Generics to be type safe. - * - * @example - * const v:THREE.Vector = new THREE.Vector3(); - * v.addVectors(new THREE.Vector2(0, 1), new THREE.Vector2(2, 3)); // invalid but compiled successfully - */ -export interface Vector { - setComponent( index: number, value: number ): this; - - getComponent( index: number ): number; - - set( ...args: number[] ): this; - - setScalar( scalar: number ): this; - - /** - * copy(v:T):T; - */ - copy( v: Vector ): this; - - /** - * NOTE: The second argument is deprecated. - * - * add(v:T):T; - */ - add( v: Vector ): this; - - /** - * addVectors(a:T, b:T):T; - */ - addVectors( a: Vector, b: Vector ): this; - - addScaledVector( vector: Vector, scale: number ): this; - - /** - * Adds the scalar value s to this vector's values. - */ - addScalar( scalar: number ): this; - - /** - * sub(v:T):T; - */ - sub( v: Vector ): this; - - /** - * subVectors(a:T, b:T):T; - */ - subVectors( a: Vector, b: Vector ): this; - - /** - * multiplyScalar(s:number):T; - */ - multiplyScalar( s: number ): this; - - /** - * divideScalar(s:number):T; - */ - divideScalar( s: number ): this; - - /** - * negate():T; - */ - negate(): this; - - /** - * dot(v:T):T; - */ - dot( v: Vector ): number; - - /** - * lengthSq():number; - */ - lengthSq(): number; - - /** - * length():number; - */ - length(): number; - - /** - * normalize():T; - */ - normalize(): this; - - /** - * NOTE: Vector4 doesn't have the property. - * - * distanceTo(v:T):number; - */ - distanceTo?( v: Vector ): number; - - /** - * NOTE: Vector4 doesn't have the property. - * - * distanceToSquared(v:T):number; - */ - distanceToSquared?( v: Vector ): number; - - /** - * setLength(l:number):T; - */ - setLength( l: number ): this; - - /** - * lerp(v:T, alpha:number):T; - */ - lerp( v: Vector, alpha: number ): this; - - /** - * equals(v:T):boolean; - */ - equals( v: Vector ): boolean; - - /** - * clone():T; - */ - clone(): Vector; -} - -/** - * 2D vector. - * - * ( class Vector2 implements Vector ) - */ -export class Vector2 implements Vector { - - constructor( x?: number, y?: number ); - - /** - * @default 0 - */ - x: number; - - /** - * @default 0 - */ - y: number; - width: number; - height: number; - readonly isVector2: true; - - /** - * Sets value of this vector. - */ - set( x: number, y: number ): this; - - /** - * Sets the x and y values of this vector both equal to scalar. - */ - setScalar( scalar: number ): this; - - /** - * Sets X component of this vector. - */ - setX( x: number ): this; - - /** - * Sets Y component of this vector. - */ - setY( y: number ): this; - - /** - * Sets a component of this vector. - */ - setComponent( index: number, value: number ): this; - - /** - * Gets a component of this vector. - */ - getComponent( index: number ): number; - - /** - * Returns a new Vector2 instance with the same `x` and `y` values. - */ - clone(): Vector2; - - /** - * Copies value of v to this vector. - */ - copy( v: Vector2 ): this; - - /** - * Adds v to this vector. - */ - add( v: Vector2, w?: Vector2 ): this; - - /** - * Adds the scalar value s to this vector's x and y values. - */ - addScalar( s: number ): this; - - /** - * Sets this vector to a + b. - */ - addVectors( a: Vector2, b: Vector2 ): this; - - /** - * Adds the multiple of v and s to this vector. - */ - addScaledVector( v: Vector2, s: number ): this; - - /** - * Subtracts v from this vector. - */ - sub( v: Vector2 ): this; - - /** - * Subtracts s from this vector's x and y components. - */ - subScalar( s: number ): this; - - /** - * Sets this vector to a - b. - */ - subVectors( a: Vector2, b: Vector2 ): this; - - /** - * Multiplies this vector by v. - */ - multiply( v: Vector2 ): this; - - /** - * Multiplies this vector by scalar s. - */ - multiplyScalar( scalar: number ): this; - - /** - * Divides this vector by v. - */ - divide( v: Vector2 ): this; - - /** - * Divides this vector by scalar s. - * Set vector to ( 0, 0 ) if s == 0. - */ - divideScalar( s: number ): this; - - /** - * Multiplies this vector (with an implicit 1 as the 3rd component) by m. - */ - applyMatrix3( m: Matrix3 ): this; - - /** - * If this vector's x or y value is greater than v's x or y value, replace that value with the corresponding min value. - */ - min( v: Vector2 ): this; - - /** - * If this vector's x or y value is less than v's x or y value, replace that value with the corresponding max value. - */ - max( v: Vector2 ): this; - - /** - * If this vector's x or y value is greater than the max vector's x or y value, it is replaced by the corresponding value. - * If this vector's x or y value is less than the min vector's x or y value, it is replaced by the corresponding value. - * @param min the minimum x and y values. - * @param max the maximum x and y values in the desired range. - */ - clamp( min: Vector2, max: Vector2 ): this; - - /** - * If this vector's x or y values are greater than the max value, they are replaced by the max value. - * If this vector's x or y values are less than the min value, they are replaced by the min value. - * @param min the minimum value the components will be clamped to. - * @param max the maximum value the components will be clamped to. - */ - clampScalar( min: number, max: number ): this; - - /** - * If this vector's length is greater than the max value, it is replaced by the max value. - * If this vector's length is less than the min value, it is replaced by the min value. - * @param min the minimum value the length will be clamped to. - * @param max the maximum value the length will be clamped to. - */ - clampLength( min: number, max: number ): this; - - /** - * The components of the vector are rounded down to the nearest integer value. - */ - floor(): this; - - /** - * The x and y components of the vector are rounded up to the nearest integer value. - */ - ceil(): this; - - /** - * The components of the vector are rounded to the nearest integer value. - */ - round(): this; - - /** - * The components of the vector are rounded towards zero (up if negative, down if positive) to an integer value. - */ - roundToZero(): this; - - /** - * Inverts this vector. - */ - negate(): this; - - /** - * Computes dot product of this vector and v. - */ - dot( v: Vector2 ): number; - - /** - * Computes cross product of this vector and v. - */ - cross( v: Vector2 ): number; - - /** - * Computes squared length of this vector. - */ - lengthSq(): number; - - /** - * Computes length of this vector. - */ - length(): number; - - /** - * @deprecated Use {@link Vector2#manhattanLength .manhattanLength()} instead. - */ - lengthManhattan(): number; - - /** - * Computes the Manhattan length of this vector. - * - * see {@link http://en.wikipedia.org/wiki/Taxicab_geometry|Wikipedia: Taxicab Geometry} - * - * @return {number} - */ - manhattanLength(): number; - - /** - * Normalizes this vector. - */ - normalize(): this; - - /** - * computes the angle in radians with respect to the positive x-axis - */ - angle(): number; - - /** - * Computes distance of this vector to v. - */ - distanceTo( v: Vector2 ): number; - - /** - * Computes squared distance of this vector to v. - */ - distanceToSquared( v: Vector2 ): number; - - /** - * @deprecated Use {@link Vector2#manhattanDistanceTo .manhattanDistanceTo()} instead. - */ - distanceToManhattan( v: Vector2 ): number; - - /** - * Computes the Manhattan length (distance) from this vector to the given vector v - * - * see {@link http://en.wikipedia.org/wiki/Taxicab_geometry|Wikipedia: Taxicab Geometry} - * - * @param {Vector2} v - * - * @return {number} - */ - manhattanDistanceTo( v: Vector2 ): number; - - /** - * Normalizes this vector and multiplies it by l. - */ - setLength( length: number ): this; - - /** - * Linearly interpolates between this vector and v, where alpha is the distance along the line - alpha = 0 will be this vector, and alpha = 1 will be v. - * @param v vector to interpolate towards. - * @param alpha interpolation factor in the closed interval [0, 1]. - */ - lerp( v: Vector2, alpha: number ): this; - - /** - * Sets this vector to be the vector linearly interpolated between v1 and v2 where alpha is the distance along the line connecting the two vectors - alpha = 0 will be v1, and alpha = 1 will be v2. - * @param v1 the starting vector. - * @param v2 vector to interpolate towards. - * @param alpha interpolation factor in the closed interval [0, 1]. - */ - lerpVectors( v1: Vector2, v2: Vector2, alpha: number ): this; - - /** - * Checks for strict equality of this vector and v. - */ - equals( v: Vector2 ): boolean; - - /** - * Sets this vector's x and y value from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): this; - - /** - * Sets this vector's x and y value from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): this; - - /** - * Returns an array [x, y], or copies x and y into the provided array. - * @param array (optional) array to store the vector to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - toArray( array?: Vector2tuple, offset?: 0 ): Vector2tuple; - - /** - * Copies x and y into the provided array-like. - * @param array array-like to store the vector to. - * @param offset (optional) optional offset into the array. - * @return The provided array-like. - */ - toArray( array: ArrayLike, offset?: number ): ArrayLike; - - /** - * Sets this vector's x and y values from the attribute. - * @param attribute the source attribute. - * @param index index in the attribute. - */ - fromBufferAttribute( attribute: BufferAttribute, index: number ): this; - - /** - * Rotates the vector around center by angle radians. - * @param center the point around which to rotate. - * @param angle the angle to rotate, in radians. - */ - rotateAround( center: Vector2, angle: number ): this; - - /** - * Sets this vector's x and y from Math.random - */ - random(): this; - -} diff --git a/src/math/Vector3.d.ts b/src/math/Vector3.d.ts deleted file mode 100644 index d94a305c242156..00000000000000 --- a/src/math/Vector3.d.ts +++ /dev/null @@ -1,308 +0,0 @@ -import { Euler } from './Euler'; -import { Matrix3 } from './Matrix3'; -import { Matrix4 } from './Matrix4'; -import { Quaternion } from './Quaternion'; -import { Camera } from './../cameras/Camera'; -import { Spherical } from './Spherical'; -import { Cylindrical } from './Cylindrical'; -import { BufferAttribute } from './../core/BufferAttribute'; -import { InterleavedBufferAttribute } from './../core/InterleavedBufferAttribute'; -import { Vector } from './Vector2'; - -type Vector3Tuple = [number, number, number]; - -/** - * 3D vector. ( class Vector3 implements Vector ) - * - * see {@link https://github.com/mrdoob/three.js/blob/master/src/math/Vector3.js} - * - * @example - * const a = new THREE.Vector3( 1, 0, 0 ); - * const b = new THREE.Vector3( 0, 1, 0 ); - * const c = new THREE.Vector3(); - * c.crossVectors( a, b ); - */ -export class Vector3 implements Vector { - - constructor( x?: number, y?: number, z?: number ); - - /** - * @default 0 - */ - x: number; - - /** - * @default 0 - */ - y: number; - - /** - * @default 0 - */ - z: number; - readonly isVector3: true; - - /** - * Sets value of this vector. - */ - set( x: number, y: number, z: number ): this; - - /** - * Sets all values of this vector. - */ - setScalar( scalar: number ): this; - - /** - * Sets x value of this vector. - */ - setX( x: number ): Vector3; - - /** - * Sets y value of this vector. - */ - setY( y: number ): Vector3; - - /** - * Sets z value of this vector. - */ - setZ( z: number ): Vector3; - - setComponent( index: number, value: number ): this; - - getComponent( index: number ): number; - - /** - * Clones this vector. - */ - clone(): Vector3; - - /** - * Copies value of v to this vector. - */ - copy( v: Vector3 ): this; - - /** - * Adds v to this vector. - */ - add( v: Vector3 ): this; - - addScalar( s: number ): this; - - addScaledVector( v: Vector3, s: number ): this; - - /** - * Sets this vector to a + b. - */ - addVectors( a: Vector3, b: Vector3 ): this; - - /** - * Subtracts v from this vector. - */ - sub( a: Vector3 ): this; - - subScalar( s: number ): this; - - /** - * Sets this vector to a - b. - */ - subVectors( a: Vector3, b: Vector3 ): this; - - multiply( v: Vector3 ): this; - - /** - * Multiplies this vector by scalar s. - */ - multiplyScalar( s: number ): this; - - multiplyVectors( a: Vector3, b: Vector3 ): this; - - applyEuler( euler: Euler ): this; - - applyAxisAngle( axis: Vector3, angle: number ): this; - - applyMatrix3( m: Matrix3 ): this; - - applyNormalMatrix( m: Matrix3 ): this; - - applyMatrix4( m: Matrix4 ): this; - - applyQuaternion( q: Quaternion ): this; - - project( camera: Camera ): this; - - unproject( camera: Camera ): this; - - transformDirection( m: Matrix4 ): this; - - divide( v: Vector3 ): this; - - /** - * Divides this vector by scalar s. - * Set vector to ( 0, 0, 0 ) if s == 0. - */ - divideScalar( s: number ): this; - - min( v: Vector3 ): this; - - max( v: Vector3 ): this; - - clamp( min: Vector3, max: Vector3 ): this; - - clampScalar( min: number, max: number ): this; - - clampLength( min: number, max: number ): this; - - floor(): this; - - ceil(): this; - - round(): this; - - roundToZero(): this; - - /** - * Inverts this vector. - */ - negate(): this; - - /** - * Computes dot product of this vector and v. - */ - dot( v: Vector3 ): number; - - /** - * Computes squared length of this vector. - */ - lengthSq(): number; - - /** - * Computes length of this vector. - */ - length(): number; - - /** - * Computes Manhattan length of this vector. - * http://en.wikipedia.org/wiki/Taxicab_geometry - * - * @deprecated Use {@link Vector3#manhattanLength .manhattanLength()} instead. - */ - lengthManhattan(): number; - - /** - * Computes the Manhattan length of this vector. - * - * see {@link http://en.wikipedia.org/wiki/Taxicab_geometry|Wikipedia: Taxicab Geometry} - * - * @return {number} - */ - manhattanLength(): number; - - /** - * Computes the Manhattan length (distance) from this vector to the given vector v - * - * see {@link http://en.wikipedia.org/wiki/Taxicab_geometry|Wikipedia: Taxicab Geometry} - * - * @param {Vector3} v - * - * @return {number} - */ - manhattanDistanceTo( v: Vector3 ): number; - - /** - * Normalizes this vector. - */ - normalize(): this; - - /** - * Normalizes this vector and multiplies it by l. - */ - setLength( l: number ): this; - lerp( v: Vector3, alpha: number ): this; - - lerpVectors( v1: Vector3, v2: Vector3, alpha: number ): this; - - /** - * Sets this vector to cross product of itself and v. - */ - cross( a: Vector3 ): this; - - /** - * Sets this vector to cross product of a and b. - */ - crossVectors( a: Vector3, b: Vector3 ): this; - projectOnVector( v: Vector3 ): this; - projectOnPlane( planeNormal: Vector3 ): this; - reflect( vector: Vector3 ): this; - angleTo( v: Vector3 ): number; - - /** - * Computes distance of this vector to v. - */ - distanceTo( v: Vector3 ): number; - - /** - * Computes squared distance of this vector to v. - */ - distanceToSquared( v: Vector3 ): number; - - /** - * @deprecated Use {@link Vector3#manhattanDistanceTo .manhattanDistanceTo()} instead. - */ - distanceToManhattan( v: Vector3 ): number; - - setFromSpherical( s: Spherical ): this; - setFromSphericalCoords( r: number, phi: number, theta:number ): this; - setFromCylindrical( s: Cylindrical ): this; - setFromCylindricalCoords( radius: number, theta: number, y: number ): this; - setFromMatrixPosition( m: Matrix4 ): this; - setFromMatrixScale( m: Matrix4 ): this; - setFromMatrixColumn( matrix: Matrix4, index: number ): this; - setFromMatrix3Column( matrix: Matrix3, index: number ): this; - - /** - * Checks for strict equality of this vector and v. - */ - equals( v: Vector3 ): boolean; - - /** - * Sets this vector's x, y and z value from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): this; - - /** - * Sets this vector's x, y and z value from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): this; - - /** - * Returns an array [x, y, z], or copies x, y and z into the provided array. - * @param array (optional) array to store the vector to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - toArray( array?: Vector3Tuple, offset?: 0 ): Vector3Tuple; - - /** - * Copies x, y and z into the provided array-like. - * @param array array-like to store the vector to. - * @param offset (optional) optional offset into the array-like. - * @return The provided array-like. - */ - toArray( array: ArrayLike, offset?: number ): ArrayLike; - - fromBufferAttribute( - attribute: BufferAttribute | InterleavedBufferAttribute, - index: number - ): this; - - /** - * Sets this vector's x, y and z from Math.random - */ - random(): this; - -} diff --git a/src/math/Vector4.d.ts b/src/math/Vector4.d.ts deleted file mode 100644 index a825070e1138af..00000000000000 --- a/src/math/Vector4.d.ts +++ /dev/null @@ -1,237 +0,0 @@ -import { Matrix4 } from './Matrix4'; -import { Quaternion } from './Quaternion'; -import { BufferAttribute } from './../core/BufferAttribute'; -import { Vector } from './Vector2'; - -type Vector4Tuple = [number, number, number, number]; - -/** - * 4D vector. - * - * ( class Vector4 implements Vector ) - */ -export class Vector4 implements Vector { - - constructor( x?: number, y?: number, z?: number, w?: number ); - - /** - * @default 0 - */ - x: number; - - /** - * @default 0 - */ - y: number; - - /** - * @default 0 - */ - z: number; - - /** - * @default 0 - */ - w: number; - - width: number; - height: number; - readonly isVector4: true; - - /** - * Sets value of this vector. - */ - set( x: number, y: number, z: number, w: number ): this; - - /** - * Sets all values of this vector. - */ - setScalar( scalar: number ): this; - - /** - * Sets X component of this vector. - */ - setX( x: number ): this; - - /** - * Sets Y component of this vector. - */ - setY( y: number ): this; - - /** - * Sets Z component of this vector. - */ - setZ( z: number ): this; - - /** - * Sets w component of this vector. - */ - setW( w: number ): this; - - setComponent( index: number, value: number ): this; - - getComponent( index: number ): number; - - /** - * Clones this vector. - */ - clone(): Vector4; - - /** - * Copies value of v to this vector. - */ - copy( v: Vector4 ): this; - - /** - * Adds v to this vector. - */ - add( v: Vector4 ): this; - - addScalar( scalar: number ): this; - - /** - * Sets this vector to a + b. - */ - addVectors( a: Vector4, b: Vector4 ): this; - - addScaledVector( v: Vector4, s: number ): this; - /** - * Subtracts v from this vector. - */ - sub( v: Vector4 ): this; - - subScalar( s: number ): this; - - /** - * Sets this vector to a - b. - */ - subVectors( a: Vector4, b: Vector4 ): this; - - multiply( v: Vector4 ): this; - - /** - * Multiplies this vector by scalar s. - */ - multiplyScalar( s: number ): this; - - applyMatrix4( m: Matrix4 ): this; - - /** - * Divides this vector by scalar s. - * Set vector to ( 0, 0, 0 ) if s == 0. - */ - divideScalar( s: number ): this; - - /** - * http://www.euclideanspace.com/maths/geometry/rotations/conversions/quaternionToAngle/index.htm - * @param q is assumed to be normalized - */ - setAxisAngleFromQuaternion( q: Quaternion ): this; - - /** - * http://www.euclideanspace.com/maths/geometry/rotations/conversions/matrixToAngle/index.htm - * @param m assumes the upper 3x3 of m is a pure rotation matrix (i.e, unscaled) - */ - setAxisAngleFromRotationMatrix( m: Matrix4 ): this; - - min( v: Vector4 ): this; - max( v: Vector4 ): this; - clamp( min: Vector4, max: Vector4 ): this; - clampScalar( min: number, max: number ): this; - floor(): this; - ceil(): this; - round(): this; - roundToZero(): this; - - /** - * Inverts this vector. - */ - negate(): this; - - /** - * Computes dot product of this vector and v. - */ - dot( v: Vector4 ): number; - - /** - * Computes squared length of this vector. - */ - lengthSq(): number; - - /** - * Computes length of this vector. - */ - length(): number; - - /** - * Computes the Manhattan length of this vector. - * - * see {@link http://en.wikipedia.org/wiki/Taxicab_geometry|Wikipedia: Taxicab Geometry} - * - * @return {number} - */ - manhattanLength(): number; - - /** - * Normalizes this vector. - */ - normalize(): this; - /** - * Normalizes this vector and multiplies it by l. - */ - setLength( length: number ): this; - - /** - * Linearly interpolate between this vector and v with alpha factor. - */ - lerp( v: Vector4, alpha: number ): this; - - lerpVectors( v1: Vector4, v2: Vector4, alpha: number ): this; - - /** - * Checks for strict equality of this vector and v. - */ - equals( v: Vector4 ): boolean; - - /** - * Sets this vector's x, y, z and w value from the provided array. - * @param array the source array. - * @param offset (optional) offset into the array. Default is 0. - */ - fromArray( array: number[], offset?: number ): this; - - /** - * Sets this vector's x, y, z and w value from the provided array-like. - * @param array the source array-like. - * @param offset (optional) offset into the array-like. Default is 0. - */ - fromArray( array: ArrayLike, offset?: number ): this; - - /** - * Returns an array [x, y, z, w], or copies x, y, z and w into the provided array. - * @param array (optional) array to store the vector to. If this is not provided, a new array will be created. - * @param offset (optional) optional offset into the array. - * @return The created or provided array. - */ - toArray( array?: number[], offset?: number ): number[]; - toArray( array?: Vector4Tuple, offset?: 0 ): Vector4Tuple; - - /** - * Copies x, y, z and w into the provided array-like. - * @param array array-like to store the vector to. - * @param offset (optional) optional offset into the array-like. - * @return The provided array-like. - */ - toArray( array: ArrayLike, offset?: number ): ArrayLike; - - fromBufferAttribute( - attribute: BufferAttribute, - index: number - ): this; - - /** - * Sets this vector's x, y, z and w from Math.random - */ - random(): this; - -} diff --git a/src/math/interpolants/CubicInterpolant.d.ts b/src/math/interpolants/CubicInterpolant.d.ts deleted file mode 100644 index 435d476fc407ff..00000000000000 --- a/src/math/interpolants/CubicInterpolant.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Interpolant } from '../Interpolant'; - -export class CubicInterpolant extends Interpolant { - - constructor( - parameterPositions: any, - samplesValues: any, - sampleSize: number, - resultBuffer?: any - ); - - interpolate_( i1: number, t0: number, t: number, t1: number ): any; - -} diff --git a/src/math/interpolants/DiscreteInterpolant.d.ts b/src/math/interpolants/DiscreteInterpolant.d.ts deleted file mode 100644 index f553d17c4abd29..00000000000000 --- a/src/math/interpolants/DiscreteInterpolant.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Interpolant } from '../Interpolant'; - -export class DiscreteInterpolant extends Interpolant { - - constructor( - parameterPositions: any, - samplesValues: any, - sampleSize: number, - resultBuffer?: any - ); - - interpolate_( i1: number, t0: number, t: number, t1: number ): any; - -} diff --git a/src/math/interpolants/LinearInterpolant.d.ts b/src/math/interpolants/LinearInterpolant.d.ts deleted file mode 100644 index e539a0960be087..00000000000000 --- a/src/math/interpolants/LinearInterpolant.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Interpolant } from '../Interpolant'; - -export class LinearInterpolant extends Interpolant { - - constructor( - parameterPositions: any, - samplesValues: any, - sampleSize: number, - resultBuffer?: any - ); - - interpolate_( i1: number, t0: number, t: number, t1: number ): any; - -} diff --git a/src/math/interpolants/QuaternionLinearInterpolant.d.ts b/src/math/interpolants/QuaternionLinearInterpolant.d.ts deleted file mode 100644 index 6519fd918063bd..00000000000000 --- a/src/math/interpolants/QuaternionLinearInterpolant.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { Interpolant } from '../Interpolant'; - -export class QuaternionLinearInterpolant extends Interpolant { - - constructor( - parameterPositions: any, - samplesValues: any, - sampleSize: number, - resultBuffer?: any - ); - - interpolate_( i1: number, t0: number, t: number, t1: number ): any; - -} diff --git a/src/objects/Bone.d.ts b/src/objects/Bone.d.ts deleted file mode 100644 index 86cc50d4ae3b38..00000000000000 --- a/src/objects/Bone.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { Object3D } from './../core/Object3D'; - -// Objects ////////////////////////////////////////////////////////////////////////////////// - -export class Bone extends Object3D { - - constructor(); - readonly isBone: true; - type: 'Bone'; - -} diff --git a/src/objects/Group.d.ts b/src/objects/Group.d.ts deleted file mode 100644 index b350726c810e44..00000000000000 --- a/src/objects/Group.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Object3D } from './../core/Object3D'; - -export class Group extends Object3D { - - constructor(); - type: 'Group'; - readonly isGroup: true; - -} diff --git a/src/objects/InstancedMesh.d.ts b/src/objects/InstancedMesh.d.ts deleted file mode 100644 index 9f955bcf783088..00000000000000 --- a/src/objects/InstancedMesh.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { BufferGeometry } from '../core/BufferGeometry'; -import { Material } from './../materials/Material'; -import { BufferAttribute } from './../core/BufferAttribute'; -import { Mesh } from './Mesh'; -import { Matrix4 } from './../math/Matrix4'; -import { Color } from './../math/Color'; - -export class InstancedMesh extends Mesh { - - constructor( - geometry: BufferGeometry, - material: Material | Material[], - count: number - ); - - count: number; - instanceColor: null | BufferAttribute; - instanceMatrix: BufferAttribute; - readonly isInstancedMesh: true; - - getColorAt( index: number, color: Color ): void; - getMatrixAt( index: number, matrix: Matrix4 ): void; - setColorAt( index: number, color: Color ): void; - setMatrixAt( index: number, matrix: Matrix4 ): void; - dispose(): void; - -} diff --git a/src/objects/LOD.d.ts b/src/objects/LOD.d.ts deleted file mode 100644 index f52915a2be5124..00000000000000 --- a/src/objects/LOD.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Object3D } from './../core/Object3D'; -import { Raycaster } from './../core/Raycaster'; -import { Camera } from './../cameras/Camera'; -import { Intersection } from '../core/Raycaster'; - -export class LOD extends Object3D { - - constructor(); - - type: 'LOD'; - - levels: { distance: number; object: Object3D }[]; - autoUpdate: boolean; - readonly isLOD: true; - - addLevel( object: Object3D, distance?: number ): this; - getCurrentLevel(): number; - getObjectForDistance( distance: number ): Object3D | null; - raycast( raycaster: Raycaster, intersects: Intersection[] ): void; - update( camera: Camera ): void; - toJSON( meta: any ): any; - - /** - * @deprecated Use {@link LOD#levels .levels} instead. - */ - objects: any[]; - -} diff --git a/src/objects/Line.d.ts b/src/objects/Line.d.ts deleted file mode 100644 index 8c931853db690f..00000000000000 --- a/src/objects/Line.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { Material } from './../materials/Material'; -import { Raycaster } from './../core/Raycaster'; -import { Object3D } from './../core/Object3D'; -import { BufferGeometry } from '../core/BufferGeometry'; -import { Intersection } from '../core/Raycaster'; - -export class Line extends Object3D { - - constructor( - geometry?: BufferGeometry, - material?: Material | Material[] - ); - - geometry: BufferGeometry; - material: Material | Material[]; - - type: 'Line' | 'LineLoop' | 'LineSegments' | string; - readonly isLine: true; - - morphTargetInfluences?: number[]; - morphTargetDictionary?: { [key: string]: number }; - - computeLineDistances(): this; - raycast( raycaster: Raycaster, intersects: Intersection[] ): void; - updateMorphTargets(): void; - -} diff --git a/src/objects/LineLoop.d.ts b/src/objects/LineLoop.d.ts deleted file mode 100644 index a07807165058eb..00000000000000 --- a/src/objects/LineLoop.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { Line } from './Line'; -import { Material } from './../materials/Material'; -import { BufferGeometry } from '../core/BufferGeometry'; - -export class LineLoop extends Line { - - constructor( - geometry?: BufferGeometry, - material?: Material | Material[] - ); - - type: 'LineLoop'; - readonly isLineLoop: true; - -} diff --git a/src/objects/LineSegments.d.ts b/src/objects/LineSegments.d.ts deleted file mode 100644 index 4cbb2dd7155473..00000000000000 --- a/src/objects/LineSegments.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { Material } from './../materials/Material'; -import { Line } from './Line'; -import { BufferGeometry } from '../core/BufferGeometry'; - -/** - * @deprecated - */ -export const LineStrip: number; -/** - * @deprecated - */ -export const LinePieces: number; - -export class LineSegments extends Line { - - constructor( - geometry?: BufferGeometry, - material?: Material | Material[] - ); - - /** - * @default 'LineSegments' - */ - type: 'LineSegments' | string; - readonly isLineSegments: true; - -} diff --git a/src/objects/Mesh.d.ts b/src/objects/Mesh.d.ts deleted file mode 100644 index 762bedf3e82398..00000000000000 --- a/src/objects/Mesh.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { Material } from './../materials/Material'; -import { Raycaster } from './../core/Raycaster'; -import { Object3D } from './../core/Object3D'; -import { BufferGeometry } from '../core/BufferGeometry'; -import { Intersection } from '../core/Raycaster'; - -export class Mesh extends Object3D { - - constructor( - geometry?: BufferGeometry, - material?: Material | Material[] - ); - - geometry: BufferGeometry; - material: Material | Material[]; - morphTargetInfluences?: number[]; - morphTargetDictionary?: { [key: string]: number }; - readonly isMesh: true; - type: string; - - updateMorphTargets(): void; - raycast( raycaster: Raycaster, intersects: Intersection[] ): void; - -} diff --git a/src/objects/Points.d.ts b/src/objects/Points.d.ts deleted file mode 100644 index 52ee59cab16b74..00000000000000 --- a/src/objects/Points.d.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Material } from './../materials/Material'; -import { Raycaster } from './../core/Raycaster'; -import { Object3D } from './../core/Object3D'; -import { BufferGeometry } from '../core/BufferGeometry'; -import { Intersection } from '../core/Raycaster'; - -/** - * A class for displaying points. The points are rendered by the WebGLRenderer using gl.POINTS. - */ -export class Points extends Object3D { - - /** - * @param geometry An instance of BufferGeometry. - * @param material An instance of Material (optional). - */ - constructor( - geometry?: BufferGeometry, - material?: Material | Material[] - ); - - type: 'Points'; - morphTargetInfluences?: number[]; - morphTargetDictionary?: { [key: string]: number }; - readonly isPoints: true; - - /** - * An instance of BufferGeometry, where each vertex designates the position of a particle in the system. - */ - geometry: BufferGeometry; - - /** - * An instance of Material, defining the object's appearance. Default is a PointsMaterial with randomised colour. - */ - material: Material | Material[]; - - raycast( raycaster: Raycaster, intersects: Intersection[] ): void; - updateMorphTargets(): void; - -} diff --git a/src/objects/Skeleton.d.ts b/src/objects/Skeleton.d.ts deleted file mode 100644 index 2ea6ca69a521d9..00000000000000 --- a/src/objects/Skeleton.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { Bone } from './Bone'; -import { Matrix4 } from './../math/Matrix4'; -import { DataTexture } from './../textures/DataTexture'; - -export class Skeleton { - - constructor( bones: Bone[], boneInverses?: Matrix4[] ); - - uuid: string; - bones: Bone[]; - boneInverses: Matrix4[]; - boneMatrices: Float32Array; - boneTexture: null | DataTexture; - boneTextureSize: number; - frame: number; - - init(): void; - calculateInverses(): void; - pose(): void; - update(): void; - clone(): Skeleton; - getBoneByName( name: string ): undefined | Bone; - dispose() :void; - - /** - * @deprecated This property has been removed completely. - */ - useVertexTexture: boolean; - -} diff --git a/src/objects/SkinnedMesh.d.ts b/src/objects/SkinnedMesh.d.ts deleted file mode 100644 index 704c5efef128dc..00000000000000 --- a/src/objects/SkinnedMesh.d.ts +++ /dev/null @@ -1,26 +0,0 @@ -import { Material } from './../materials/Material'; -import { Matrix4 } from './../math/Matrix4'; -import { Skeleton } from './Skeleton'; -import { Mesh } from './Mesh'; -import { BufferGeometry } from '../core/BufferGeometry'; - -export class SkinnedMesh extends Mesh { - - constructor( - geometry?: BufferGeometry, - material?: Material | Material[], - useVertexTexture?: boolean - ); - - bindMode: string; - bindMatrix: Matrix4; - bindMatrixInverse: Matrix4; - skeleton: Skeleton; - readonly isSkinnedMesh: true; - - bind( skeleton: Skeleton, bindMatrix?: Matrix4 ): void; - pose(): void; - normalizeSkinWeights(): void; - updateMatrixWorld( force?: boolean ): void; - -} diff --git a/src/objects/Sprite.d.ts b/src/objects/Sprite.d.ts deleted file mode 100644 index b8d5882418b193..00000000000000 --- a/src/objects/Sprite.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { Vector2 } from './../math/Vector2'; -import { Raycaster } from './../core/Raycaster'; -import { Object3D } from './../core/Object3D'; -import { Intersection } from '../core/Raycaster'; -import { SpriteMaterial } from '../materials/Materials'; -import { BufferGeometry } from '../core/BufferGeometry'; - -export class Sprite extends Object3D { - - constructor( material?: SpriteMaterial ); - - type: 'Sprite'; - readonly isSprite: true; - - geometry: BufferGeometry; - material: SpriteMaterial; - center: Vector2; - - raycast( raycaster: Raycaster, intersects: Intersection[] ): void; - copy( source: this ): this; - -} diff --git a/src/polyfills.d.ts b/src/polyfills.d.ts deleted file mode 100644 index 5b78bf28b27724..00000000000000 --- a/src/polyfills.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -// log handlers -export function warn( message?: any, ...optionalParams: any[] ): void; -export function error( message?: any, ...optionalParams: any[] ): void; -export function log( message?: any, ...optionalParams: any[] ): void; - -// typed array parameters -export type TypedArray = - Int8Array - | Uint8Array - | Uint8ClampedArray - | Int16Array - | Uint16Array - | Int32Array - | Uint32Array - | Float32Array - | Float64Array; diff --git a/src/renderers/WebGL1Renderer.d.ts b/src/renderers/WebGL1Renderer.d.ts deleted file mode 100644 index 8ed3d82f00314d..00000000000000 --- a/src/renderers/WebGL1Renderer.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { WebGLRenderer, WebGLRendererParameters } from './WebGLRenderer'; - -export class WebGL1Renderer extends WebGLRenderer { - - constructor( parameters?: WebGLRendererParameters ); - readonly isWebGL1Renderer: true; - -} diff --git a/src/renderers/WebGLCubeRenderTarget.d.ts b/src/renderers/WebGLCubeRenderTarget.d.ts deleted file mode 100644 index fad513bb93691a..00000000000000 --- a/src/renderers/WebGLCubeRenderTarget.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { WebGLRenderTargetOptions, WebGLRenderTarget } from './WebGLRenderTarget'; -import { WebGLRenderer } from './WebGLRenderer'; -import { Texture } from './../textures/Texture'; -import { CubeTexture } from './../textures/CubeTexture'; - -export class WebGLCubeRenderTarget extends WebGLRenderTarget { - - constructor( - size: number, - options?: WebGLRenderTargetOptions - ); - - texture: CubeTexture; - - fromEquirectangularTexture( renderer: WebGLRenderer, texture: Texture ): this; - - clear( renderer: WebGLRenderer, color: boolean, depth: boolean, stencil: boolean ): void; - -} diff --git a/src/renderers/WebGLMultisampleRenderTarget.d.ts b/src/renderers/WebGLMultisampleRenderTarget.d.ts deleted file mode 100644 index 65ec6b3299bce1..00000000000000 --- a/src/renderers/WebGLMultisampleRenderTarget.d.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { - WebGLRenderTarget, - WebGLRenderTargetOptions, -} from './WebGLRenderTarget'; - -export class WebGLMultisampleRenderTarget extends WebGLRenderTarget { - - constructor( - width: number, - height: number, - options?: WebGLRenderTargetOptions - ); - - readonly isWebGLMultisampleRenderTarget: true; - - /** - * Specifies the number of samples to be used for the renderbuffer storage.However, the maximum supported size for multisampling is platform dependent and defined via gl.MAX_SAMPLES. - * @default 4 - */ - samples: number; - -} diff --git a/src/renderers/WebGLRenderTarget.d.ts b/src/renderers/WebGLRenderTarget.d.ts deleted file mode 100644 index 4c911a28cdfcb4..00000000000000 --- a/src/renderers/WebGLRenderTarget.d.ts +++ /dev/null @@ -1,104 +0,0 @@ -import { Vector4 } from './../math/Vector4'; -import { Texture } from './../textures/Texture'; -import { DepthTexture } from './../textures/DepthTexture'; -import { EventDispatcher } from './../core/EventDispatcher'; -import { Wrapping, TextureFilter, TextureDataType, TextureEncoding } from '../constants'; - -export interface WebGLRenderTargetOptions { - wrapS?: Wrapping; - wrapT?: Wrapping; - magFilter?: TextureFilter; - minFilter?: TextureFilter; - format?: number; // RGBAFormat; - type?: TextureDataType; // UnsignedByteType; - anisotropy?: number; // 1; - depthBuffer?: boolean; // true; - stencilBuffer?: boolean; // false; - generateMipmaps?: boolean; // true; - depthTexture?: DepthTexture; - encoding?: TextureEncoding; -} - -export class WebGLRenderTarget extends EventDispatcher { - - constructor( - width: number, - height: number, - options?: WebGLRenderTargetOptions - ); - - uuid: string; - width: number; - height: number; - scissor: Vector4; - - /** - * @default false - */ - scissorTest: boolean; - viewport: Vector4; - texture: Texture; - - /** - * @default true - */ - depthBuffer: boolean; - - /** - * @default true - */ - stencilBuffer: boolean; - - /** - * @default null - */ - depthTexture: DepthTexture; - readonly isWebGLRenderTarget: true; - - /** - * @deprecated Use {@link Texture#wrapS texture.wrapS} instead. - */ - wrapS: any; - /** - * @deprecated Use {@link Texture#wrapT texture.wrapT} instead. - */ - wrapT: any; - /** - * @deprecated Use {@link Texture#magFilter texture.magFilter} instead. - */ - magFilter: any; - /** - * @deprecated Use {@link Texture#minFilter texture.minFilter} instead. - */ - minFilter: any; - /** - * @deprecated Use {@link Texture#anisotropy texture.anisotropy} instead. - */ - anisotropy: any; - /** - * @deprecated Use {@link Texture#offset texture.offset} instead. - */ - offset: any; - /** - * @deprecated Use {@link Texture#repeat texture.repeat} instead. - */ - repeat: any; - /** - * @deprecated Use {@link Texture#format texture.format} instead. - */ - format: any; - /** - * @deprecated Use {@link Texture#type texture.type} instead. - */ - type: any; - /** - * @deprecated Use {@link Texture#generateMipmaps texture.generateMipmaps} instead. - */ - generateMipmaps: any; - - setSize( width: number, height: number ): void; - clone(): WebGLRenderTarget; - copy( source: WebGLRenderTarget ): this; - dispose(): void; - -} diff --git a/src/renderers/WebGLRenderer.d.ts b/src/renderers/WebGLRenderer.d.ts deleted file mode 100644 index 2ef2a91b78879a..00000000000000 --- a/src/renderers/WebGLRenderer.d.ts +++ /dev/null @@ -1,532 +0,0 @@ -import { Scene } from './../scenes/Scene'; -import { Camera } from './../cameras/Camera'; -import { WebGLExtensions } from './webgl/WebGLExtensions'; -import { WebGLInfo } from './webgl/WebGLInfo'; -import { WebGLShadowMap } from './webgl/WebGLShadowMap'; -import { WebGLCapabilities } from './webgl/WebGLCapabilities'; -import { WebGLProperties } from './webgl/WebGLProperties'; -import { WebGLProgram } from './webgl/WebGLProgram'; -import { WebGLRenderLists } from './webgl/WebGLRenderLists'; -import { WebGLState } from './webgl/WebGLState'; -import { Vector2 } from './../math/Vector2'; -import { Vector4 } from './../math/Vector4'; -import { Color } from './../math/Color'; -import { WebGLRenderTarget } from './WebGLRenderTarget'; -import { Object3D } from './../core/Object3D'; -import { Material } from './../materials/Material'; -import { ToneMapping, ShadowMapType, CullFace, TextureEncoding } from '../constants'; -import { WebXRManager } from '../renderers/webxr/WebXRManager'; -import { RenderTarget } from './webgl/WebGLRenderLists'; -import { BufferGeometry } from './../core/BufferGeometry'; -import { Texture } from '../textures/Texture'; -import { XRAnimationLoopCallback } from './webxr/WebXR'; - -export interface Renderer { - domElement: HTMLCanvasElement; - - render( scene: Object3D, camera: Camera ): void; - setSize( width: number, height: number, updateStyle?: boolean ): void; -} - -export interface WebGLRendererParameters { - /** - * A Canvas where the renderer draws its output. - */ - canvas?: HTMLCanvasElement | OffscreenCanvas; - - /** - * A WebGL Rendering Context. - * (https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext) - * Default is null - */ - context?: WebGLRenderingContext; - - /** - * shader precision. Can be "highp", "mediump" or "lowp". - */ - precision?: string; - - /** - * default is false. - */ - alpha?: boolean; - - /** - * default is true. - */ - premultipliedAlpha?: boolean; - - /** - * default is false. - */ - antialias?: boolean; - - /** - * default is true. - */ - stencil?: boolean; - - /** - * default is false. - */ - preserveDrawingBuffer?: boolean; - - /** - * Can be "high-performance", "low-power" or "default" - */ - powerPreference?: string; - - /** - * default is true. - */ - depth?: boolean; - - /** - * default is false. - */ - logarithmicDepthBuffer?: boolean; - - /** - * default is false. - */ - failIfMajorPerformanceCaveat?: boolean; - -} - -export interface WebGLDebug { - - /** - * Enables error checking and reporting when shader programs are being compiled. - */ - checkShaderErrors: boolean; - -} - -/** - * The WebGL renderer displays your beautifully crafted scenes using WebGL, if your device supports it. - * This renderer has way better performance than CanvasRenderer. - * - * see {@link https://github.com/mrdoob/three.js/blob/master/src/renderers/WebGLRenderer.js|src/renderers/WebGLRenderer.js} - */ -export class WebGLRenderer implements Renderer { - - /** - * parameters is an optional object with properties defining the renderer's behaviour. The constructor also accepts no parameters at all. In all cases, it will assume sane defaults when parameters are missing. - */ - constructor( parameters?: WebGLRendererParameters ); - - /** - * A Canvas where the renderer draws its output. - * This is automatically created by the renderer in the constructor (if not provided already); you just need to add it to your page. - * @default document.createElementNS( 'http://www.w3.org/1999/xhtml', 'canvas' ) - */ - domElement: HTMLCanvasElement; - - /** - * The HTML5 Canvas's 'webgl' context obtained from the canvas where the renderer will draw. - */ - context: WebGLRenderingContext; - - /** - * Defines whether the renderer should automatically clear its output before rendering. - * @default true - */ - autoClear: boolean; - - /** - * If autoClear is true, defines whether the renderer should clear the color buffer. Default is true. - * @default true - */ - autoClearColor: boolean; - - /** - * If autoClear is true, defines whether the renderer should clear the depth buffer. Default is true. - * @default true - */ - autoClearDepth: boolean; - - /** - * If autoClear is true, defines whether the renderer should clear the stencil buffer. Default is true. - * @default true - */ - autoClearStencil: boolean; - - /** - * Debug configurations. - * @default { checkShaderErrors: true } - */ - debug: WebGLDebug; - - /** - * Defines whether the renderer should sort objects. Default is true. - * @default true - */ - sortObjects: boolean; - - /** - * @default [] - */ - clippingPlanes: any[]; - - /** - * @default false - */ - localClippingEnabled: boolean; - - extensions: WebGLExtensions; - - /** - * Default is LinearEncoding. - * @default THREE.LinearEncoding - */ - outputEncoding: TextureEncoding; - - /** - * @default false - */ - physicallyCorrectLights: boolean; - - /** - * @default THREE.NoToneMapping - */ - toneMapping: ToneMapping; - - /** - * @default 1 - */ - toneMappingExposure: number; - - /** - * @default 8 - */ - maxMorphTargets: number; - - /** - * @default 4 - */ - maxMorphNormals: number; - - info: WebGLInfo; - - shadowMap: WebGLShadowMap; - - pixelRatio: number; - - capabilities: WebGLCapabilities; - properties: WebGLProperties; - renderLists: WebGLRenderLists; - state: WebGLState; - - xr: WebXRManager; - - /** - * Return the WebGL context. - */ - getContext(): WebGLRenderingContext; - getContextAttributes(): any; - forceContextLoss(): void; - - /** - * @deprecated Use {@link WebGLCapabilities#getMaxAnisotropy .capabilities.getMaxAnisotropy()} instead. - */ - getMaxAnisotropy(): number; - - /** - * @deprecated Use {@link WebGLCapabilities#precision .capabilities.precision} instead. - */ - getPrecision(): string; - - getPixelRatio(): number; - setPixelRatio( value: number ): void; - - getDrawingBufferSize( target: Vector2 ): Vector2; - setDrawingBufferSize( width: number, height: number, pixelRatio: number ): void; - - getSize( target: Vector2 ): Vector2; - - /** - * Resizes the output canvas to (width, height), and also sets the viewport to fit that size, starting in (0, 0). - */ - setSize( width: number, height: number, updateStyle?: boolean ): void; - - getCurrentViewport( target: Vector4 ): Vector4; - - /** - * Copies the viewport into target. - */ - getViewport( target: Vector4 ): Vector4; - - /** - * Sets the viewport to render from (x, y) to (x + width, y + height). - * (x, y) is the lower-left corner of the region. - */ - setViewport( x: Vector4 | number, y?: number, width?: number, height?: number ): void; - - /** - * Copies the scissor area into target. - */ - getScissor( target: Vector4 ): Vector4; - - /** - * Sets the scissor area from (x, y) to (x + width, y + height). - */ - setScissor( x: Vector4 | number, y?: number, width?: number, height?: number ): void; - - /** - * Returns true if scissor test is enabled; returns false otherwise. - */ - getScissorTest(): boolean; - - /** - * Enable the scissor test. When this is enabled, only the pixels within the defined scissor area will be affected by further renderer actions. - */ - setScissorTest( enable: boolean ): void; - - /** - * Sets the custom opaque sort function for the WebGLRenderLists. Pass null to use the default painterSortStable function. - */ - setOpaqueSort( method: Function ): void; - - /** - * Sets the custom transparent sort function for the WebGLRenderLists. Pass null to use the default reversePainterSortStable function. - */ - setTransparentSort( method: Function ): void; - - /** - * Returns a THREE.Color instance with the current clear color. - */ - getClearColor( target: Color ): Color; - - /** - * Sets the clear color, using color for the color and alpha for the opacity. - */ - setClearColor( color: Color | string | number, alpha?: number ): void; - - /** - * Returns a float with the current clear alpha. Ranges from 0 to 1. - */ - getClearAlpha(): number; - - setClearAlpha( alpha: number ): void; - - /** - * Tells the renderer to clear its color, depth or stencil drawing buffer(s). - * Arguments default to true - */ - clear( color?: boolean, depth?: boolean, stencil?: boolean ): void; - - clearColor(): void; - clearDepth(): void; - clearStencil(): void; - clearTarget( - renderTarget: WebGLRenderTarget, - color: boolean, - depth: boolean, - stencil: boolean - ): void; - - /** - * @deprecated Use {@link WebGLState#reset .state.reset()} instead. - */ - resetGLState(): void; - dispose(): void; - - renderBufferImmediate( - object: Object3D, - program: WebGLProgram, - ): void; - - renderBufferDirect( - camera: Camera, - scene: Scene, - geometry: BufferGeometry, - material: Material, - object: Object3D, - geometryGroup: any - ): void; - - /** - * A build in function that can be used instead of requestAnimationFrame. For WebXR projects this function must be used. - * @param callback The function will be called every available frame. If `null` is passed it will stop any already ongoing animation. - */ - setAnimationLoop( callback: XRAnimationLoopCallback | null ): void; - - /** - * @deprecated Use {@link WebGLRenderer#setAnimationLoop .setAnimationLoop()} instead. - */ - animate( callback: Function ): void; - - /** - * Compiles all materials in the scene with the camera. This is useful to precompile shaders before the first rendering. - */ - compile( - scene: Object3D, - camera: Camera - ): void; - - /** - * Render a scene or an object using a camera. - * The render is done to a previously specified {@link WebGLRenderTarget#renderTarget .renderTarget} set by calling - * {@link WebGLRenderer#setRenderTarget .setRenderTarget} or to the canvas as usual. - * - * By default render buffers are cleared before rendering but you can prevent this by setting the property - * {@link WebGLRenderer#autoClear autoClear} to false. If you want to prevent only certain buffers being cleared - * you can set either the {@link WebGLRenderer#autoClearColor autoClearColor}, - * {@link WebGLRenderer#autoClearStencil autoClearStencil} or {@link WebGLRenderer#autoClearDepth autoClearDepth} - * properties to false. To forcibly clear one ore more buffers call {@link WebGLRenderer#clear .clear}. - */ - render( - scene: Object3D, - camera: Camera - ): void; - - /** - * Returns the current active cube face. - */ - getActiveCubeFace(): number; - - /** - * Returns the current active mipmap level. - */ - getActiveMipmapLevel(): number; - - /** - * Sets the given WebGLFramebuffer. This method can only be used if no render target is set via - * {@link WebGLRenderer#setRenderTarget .setRenderTarget}. - * - * @param value The WebGLFramebuffer. - */ - setFramebuffer( value: WebGLFramebuffer ): void; - - /** - * Returns the current render target. If no render target is set, null is returned. - */ - getRenderTarget(): RenderTarget | null; - - /** - * @deprecated Use {@link WebGLRenderer#getRenderTarget .getRenderTarget()} instead. - */ - getCurrentRenderTarget(): RenderTarget | null; - - /** - * Sets the active render target. - * - * @param renderTarget The {@link WebGLRenderTarget renderTarget} that needs to be activated. When `null` is given, the canvas is set as the active render target instead. - * @param activeCubeFace Specifies the active cube side (PX 0, NX 1, PY 2, NY 3, PZ 4, NZ 5) of {@link WebGLCubeRenderTarget}. - * @param activeMipmapLevel Specifies the active mipmap level. - */ - setRenderTarget( renderTarget: RenderTarget | null, activeCubeFace?: number, activeMipmapLevel?: number ): void; - - readRenderTargetPixels( - renderTarget: RenderTarget, - x: number, - y: number, - width: number, - height: number, - buffer: any, - activeCubeFaceIndex?: number - ): void; - - /** - * Copies a region of the currently bound framebuffer into the selected mipmap level of the selected texture. - * This region is defined by the size of the destination texture's mip level, offset by the input position. - * - * @param position Specifies the pixel offset from which to copy out of the framebuffer. - * @param texture Specifies the destination texture. - * @param level Specifies the destination mipmap level of the texture. - */ - copyFramebufferToTexture( position: Vector2, texture: Texture, level?: number ): void; - - /** - * Copies srcTexture to the specified level of dstTexture, offset by the input position. - * - * @param position Specifies the pixel offset into the dstTexture where the copy will occur. - * @param srcTexture Specifies the source texture. - * @param dstTexture Specifies the destination texture. - * @param level Specifies the destination mipmap level of the texture. - */ - copyTextureToTexture( position: Vector2, srcTexture: Texture, dstTexture: Texture, level?: number ): void; - - /** - * Initializes the given texture. Can be used to preload a texture rather than waiting until first render (which can cause noticeable lags due to decode and GPU upload overhead). - * - * @param texture The texture to Initialize. - */ - initTexture( texture: Texture ): void; - - /** - * Can be used to reset the internal WebGL state. - */ - resetState(): void; - - /** - * @deprecated - */ - gammaFactor: number; - - /** - * @deprecated Use {@link WebGLRenderer#xr .xr} instead. - */ - vr: boolean; - - /** - * @deprecated Use {@link WebGLShadowMap#enabled .shadowMap.enabled} instead. - */ - shadowMapEnabled: boolean; - - /** - * @deprecated Use {@link WebGLShadowMap#type .shadowMap.type} instead. - */ - shadowMapType: ShadowMapType; - - /** - * @deprecated Use {@link WebGLShadowMap#cullFace .shadowMap.cullFace} instead. - */ - shadowMapCullFace: CullFace; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'OES_texture_float' )} instead. - */ - supportsFloatTextures(): any; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'OES_texture_half_float' )} instead. - */ - supportsHalfFloatTextures(): any; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'OES_standard_derivatives' )} instead. - */ - supportsStandardDerivatives(): any; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'WEBGL_compressed_texture_s3tc' )} instead. - */ - supportsCompressedTextureS3TC(): any; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'WEBGL_compressed_texture_pvrtc' )} instead. - */ - supportsCompressedTexturePVRTC(): any; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'EXT_blend_minmax' )} instead. - */ - supportsBlendMinMax(): any; - - /** - * @deprecated Use {@link WebGLCapabilities#vertexTextures .capabilities.vertexTextures} instead. - */ - supportsVertexTextures(): any; - - /** - * @deprecated Use {@link WebGLExtensions#get .extensions.get( 'ANGLE_instanced_arrays' )} instead. - */ - supportsInstancedArrays(): any; - - /** - * @deprecated Use {@link WebGLRenderer#setScissorTest .setScissorTest()} instead. - */ - enableScissorTest( boolean: any ): any; - -} diff --git a/src/renderers/shaders/ShaderChunk.d.ts b/src/renderers/shaders/ShaderChunk.d.ts deleted file mode 100644 index cd08d18bfef08b..00000000000000 --- a/src/renderers/shaders/ShaderChunk.d.ts +++ /dev/null @@ -1,120 +0,0 @@ -// Renderers / Shaders ///////////////////////////////////////////////////////////////////// -export let ShaderChunk: { - [name: string]: string; - - alphamap_fragment: string; - alphamap_pars_fragment: string; - alphatest_fragment: string; - aomap_fragment: string; - aomap_pars_fragment: string; - begin_vertex: string; - beginnormal_vertex: string; - bsdfs: string; - bumpmap_pars_fragment: string; - clipping_planes_fragment: string; - clipping_planes_pars_fragment: string; - clipping_planes_pars_vertex: string; - clipping_planes_vertex: string; - color_fragment: string; - color_pars_fragment: string; - color_pars_vertex: string; - color_vertex: string; - common: string; - cube_frag: string; - cube_vert: string; - cube_uv_reflection_fragment: string; - defaultnormal_vertex: string; - depth_frag: string; - depth_vert: string; - distanceRGBA_frag: string; - distanceRGBA_vert: string; - displacementmap_vertex: string; - displacementmap_pars_vertex: string; - emissivemap_fragment: string; - emissivemap_pars_fragment: string; - encodings_pars_fragment: string; - encodings_fragment: string; - envmap_fragment: string; - envmap_common_pars_fragment: string - envmap_pars_fragment: string; - envmap_pars_vertex: string; - envmap_vertex: string; - equirect_frag: string; - equirect_vert: string; - fog_fragment: string; - fog_pars_fragment: string; - linedashed_frag: string; - linedashed_vert: string; - lightmap_fragment: string; - lightmap_pars_fragment: string; - lights_lambert_vertex: string; - lights_pars_begin: string; - envmap_physical_pars_fragment: string; - lights_pars_map: string; - lights_phong_fragment: string; - lights_phong_pars_fragment: string; - lights_physical_fragment: string; - lights_physical_pars_fragment: string; - lights_fragment_begin: string; - lights_fragment_maps: string; - lights_fragment_end: string; - logdepthbuf_fragment: string; - logdepthbuf_pars_fragment: string; - logdepthbuf_pars_vertex: string; - logdepthbuf_vertex: string; - map_fragment: string; - map_pars_fragment: string; - map_particle_fragment: string; - map_particle_pars_fragment: string; - meshbasic_frag: string; - meshbasic_vert: string; - meshlambert_frag: string; - meshlambert_vert: string; - meshphong_frag: string; - meshphong_vert: string; - meshphysical_frag: string; - meshphysical_vert: string; - metalnessmap_fragment: string; - metalnessmap_pars_fragment: string; - morphnormal_vertex: string; - morphtarget_pars_vertex: string; - morphtarget_vertex: string; - normal_flip: string; - normal_frag: string; - normal_fragment_begin: string; - normal_fragment_maps: string; - normal_vert: string; - normalmap_pars_fragment: string; - clearcoat_normal_fragment_begin: string; - clearcoat_normal_fragment_maps: string; - clearcoat_pars_fragment: string; - packing: string; - points_frag: string; - points_vert: string; - shadow_frag: string; - shadow_vert: string; - - premultiplied_alpha_fragment: string; - project_vertex: string; - roughnessmap_fragment: string; - roughnessmap_pars_fragment: string; - shadowmap_pars_fragment: string; - shadowmap_pars_vertex: string; - shadowmap_vertex: string; - shadowmask_pars_fragment: string; - skinbase_vertex: string; - skinning_pars_vertex: string; - skinning_vertex: string; - skinnormal_vertex: string; - specularmap_fragment: string; - specularmap_pars_fragment: string; - tonemapping_fragment: string; - tonemapping_pars_fragment: string; - uv2_pars_fragment: string; - uv2_pars_vertex: string; - uv2_vertex: string; - uv_pars_fragment: string; - uv_pars_vertex: string; - uv_vertex: string; - worldpos_vertex: string; -}; diff --git a/src/renderers/shaders/ShaderLib.d.ts b/src/renderers/shaders/ShaderLib.d.ts deleted file mode 100644 index e2c31b942391f1..00000000000000 --- a/src/renderers/shaders/ShaderLib.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { IUniform } from './UniformsLib'; - -export interface Shader { - uniforms: { [uniform: string]: IUniform }; - vertexShader: string; - fragmentShader: string; -} - -export let ShaderLib: { - [name: string]: Shader; - basic: Shader; - lambert: Shader; - phong: Shader; - standard: Shader; - matcap: Shader; - points: Shader; - dashed: Shader; - depth: Shader; - normal: Shader; - sprite: Shader; - background: Shader; - cube: Shader; - equirect: Shader; - distanceRGBA: Shader; - shadow: Shader; - physical: Shader; -}; diff --git a/src/renderers/shaders/UniformsLib.d.ts b/src/renderers/shaders/UniformsLib.d.ts deleted file mode 100644 index efe4d361aaf5ca..00000000000000 --- a/src/renderers/shaders/UniformsLib.d.ts +++ /dev/null @@ -1,152 +0,0 @@ -export interface IUniform { - value: any; -} - -export let UniformsLib: { - common: { - diffuse: IUniform; - opacity: IUniform; - map: IUniform; - uvTransform: IUniform; - uv2Transform: IUniform; - alphaMap: IUniform; - }; - specularmap: { - specularMap: IUniform; - }; - envmap: { - envMap: IUniform; - flipEnvMap: IUniform; - reflectivity: IUniform; - refractionRatio: IUniform; - maxMipLevel: IUniform; - }; - aomap: { - aoMap: IUniform; - aoMapIntensity: IUniform; - }; - lightmap: { - lightMap: IUniform; - lightMapIntensity: IUniform; - }; - emissivemap: { - emissiveMap: IUniform; - }; - bumpmap: { - bumpMap: IUniform; - bumpScale: IUniform; - }; - normalmap: { - normalMap: IUniform; - normalScale: IUniform; - }; - displacementmap: { - displacementMap: IUniform; - displacementScale: IUniform; - displacementBias: IUniform; - }; - roughnessmap: { - roughnessMap: IUniform; - }; - metalnessmap: { - metalnessMap: IUniform; - }; - gradientmap: { - gradientMap: IUniform; - }; - fog: { - fogDensity: IUniform; - fogNear: IUniform; - fogFar: IUniform; - fogColor: IUniform; - }; - lights: { - ambientLightColor: IUniform; - directionalLights: { - value: any[]; - properties: { - direction: {}; - color: {}; - }; - }; - directionalLightShadows: { - value: any[]; - properties: { - shadowBias: {}; - shadowNormalBias: {}; - shadowRadius: {}; - shadowMapSize: {}; - }; - }; - directionalShadowMap: IUniform; - directionalShadowMatrix: IUniform; - spotLights: { - value: any[]; - properties: { - color: {}; - position: {}; - direction: {}; - distance: {}; - coneCos: {}; - penumbraCos: {}; - decay: {}; - }; - }; - spotLightShadows: { - value: any[]; - properties: { - shadowBias: {}; - shadowNormalBias: {}; - shadowRadius: {}; - shadowMapSize: {}; - }; - }; - spotShadowMap: IUniform; - spotShadowMatrix: IUniform; - pointLights: { - value: any[]; - properties: { - color: {}; - position: {}; - decay: {}; - distance: {}; - }; - }; - pointLightShadows: { - value: any[]; - properties: { - shadowBias: {}; - shadowNormalBias: {}; - shadowRadius: {}; - shadowMapSize: {}; - }; - }; - pointShadowMap: IUniform; - pointShadowMatrix: IUniform; - hemisphereLights: { - value: any[]; - properties: { - direction: {}; - skycolor: {}; - groundColor: {}; - }; - }; - rectAreaLights: { - value: any[]; - properties: { - color: {}; - position: {}; - width: {}; - height: {}; - }; - }; - }; - points: { - diffuse: IUniform; - opacity: IUniform; - size: IUniform; - scale: IUniform; - map: IUniform; - uvTransform: IUniform; - }; -}; diff --git a/src/renderers/shaders/UniformsUtils.d.ts b/src/renderers/shaders/UniformsUtils.d.ts deleted file mode 100644 index c8118b8f88f09f..00000000000000 --- a/src/renderers/shaders/UniformsUtils.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -export function cloneUniforms( uniforms_src: any ): any; -export function mergeUniforms( uniforms: any[] ): any; - -export namespace UniformsUtils { - export { - mergeUniforms as merge, - cloneUniforms as clone, - }; -} diff --git a/src/renderers/webgl/WebGLAnimation.d.ts b/src/renderers/webgl/WebGLAnimation.d.ts deleted file mode 100644 index eda5c17b1d2cfd..00000000000000 --- a/src/renderers/webgl/WebGLAnimation.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -export class WebGLAnimation { - - start(): void; - - stop(): void; - - setAnimationLoop( callback: Function ): void; - - setContext( value: Window ): void; - -} diff --git a/src/renderers/webgl/WebGLAttributes.d.ts b/src/renderers/webgl/WebGLAttributes.d.ts deleted file mode 100644 index 638d9f85a7a385..00000000000000 --- a/src/renderers/webgl/WebGLAttributes.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { WebGLCapabilities } from './WebGLCapabilities'; -import { BufferAttribute } from '../../core/BufferAttribute'; -import { InterleavedBufferAttribute } from '../../core/InterleavedBufferAttribute'; - -export class WebGLAttributes { - - constructor( gl: WebGLRenderingContext | WebGL2RenderingContext, capabilities: WebGLCapabilities ); - - get( attribute: BufferAttribute | InterleavedBufferAttribute ): { - buffer: WebGLBuffer, - type: number, - bytesPerElement: number, - version: number - }; - - remove( attribute: BufferAttribute | InterleavedBufferAttribute ): void; - - update( attribute: BufferAttribute | InterleavedBufferAttribute, bufferType: number ): void; - -} diff --git a/src/renderers/webgl/WebGLBackground.d.ts b/src/renderers/webgl/WebGLBackground.d.ts deleted file mode 100644 index 1e8769a7c4afe5..00000000000000 --- a/src/renderers/webgl/WebGLBackground.d.ts +++ /dev/null @@ -1,21 +0,0 @@ - -import { Color } from '../../math/Color'; -import { WebGLRenderer } from '../WebGLRenderer'; -import { WebGLState } from './WebGLState'; -import { WebGLObjects } from './WebGLObjects'; -import { WebGLRenderList } from './WebGLRenderLists'; -import { Scene } from '../../scenes/Scene'; -import { Camera } from '../../cameras/Camera'; -import { WebGLCubeMaps } from './WebGLCubeMaps'; - -export class WebGLBackground { - - constructor( renderer: WebGLRenderer, cubemaps: WebGLCubeMaps, state: WebGLState, objects: WebGLObjects, premultipliedAlpha: boolean ); - - getClearColor(): Color; - setClearColor( color: Color, alpha: number ): void; - getClearAlpha(): number; - setClearAlpha( alpha: number ): void; - render( renderList: WebGLRenderList, scene: Scene, camera: Camera, forceClear: boolean ): void; - -} diff --git a/src/renderers/webgl/WebGLBindingStates.d.ts b/src/renderers/webgl/WebGLBindingStates.d.ts deleted file mode 100644 index 46bc088f63af80..00000000000000 --- a/src/renderers/webgl/WebGLBindingStates.d.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { WebGLExtensions } from './WebGLExtensions'; -import { WebGLAttributes } from './WebGLAttributes'; -import { WebGLProgram } from './WebGLProgram'; -import { WebGLCapabilities } from './WebGLCapabilities'; -import { Object3D } from './../../core/Object3D'; -import { BufferGeometry } from './../../core/BufferGeometry'; -import { BufferAttribute } from './../../core/BufferAttribute'; -import { Material } from './../../materials/Material'; - -export class WebGLBindingStates { - - constructor( gl: WebGLRenderingContext, extensions: WebGLExtensions, attributes: WebGLAttributes, capabilities: WebGLCapabilities ); - - setup( object: Object3D, material: Material, program: WebGLProgram, geometry: BufferGeometry, index: BufferAttribute ): void; - reset(): void; - resetDefaultState(): void; - dispose(): void; - releaseStatesOfGeometry(): void; - releaseStatesOfProgram(): void; - initAttributes(): void; - enableAttribute( attribute: number ): void; - disableUnusedAttributes(): void; - -} diff --git a/src/renderers/webgl/WebGLBufferRenderer.d.ts b/src/renderers/webgl/WebGLBufferRenderer.d.ts deleted file mode 100644 index 162b8b90af13dd..00000000000000 --- a/src/renderers/webgl/WebGLBufferRenderer.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -// Renderers / WebGL ///////////////////////////////////////////////////////////////////// -import { WebGLExtensions } from './WebGLExtensions'; -import { WebGLInfo } from './WebGLInfo'; -import { WebGLCapabilities } from './WebGLCapabilities'; - -export class WebGLBufferRenderer { - - constructor( gl: WebGLRenderingContext, extensions: WebGLExtensions, info: WebGLInfo, capabilities: WebGLCapabilities ); - - setMode( value: any ): void; - render( start: any, count: number ): void; - renderInstances( - start: any, - count: number, - primcount: number - ): void; - -} diff --git a/src/renderers/webgl/WebGLCapabilities.d.ts b/src/renderers/webgl/WebGLCapabilities.d.ts deleted file mode 100644 index 3703b59d53c61f..00000000000000 --- a/src/renderers/webgl/WebGLCapabilities.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -export interface WebGLCapabilitiesParameters { - precision?: string; - logarithmicDepthBuffer?: boolean; -} - -export class WebGLCapabilities { - - constructor( - gl: WebGLRenderingContext, - extensions: any, - parameters: WebGLCapabilitiesParameters - ); - - readonly isWebGL2: boolean; - precision: string; - logarithmicDepthBuffer: boolean; - maxTextures: number; - maxVertexTextures: number; - maxTextureSize: number; - maxCubemapSize: number; - maxAttributes: number; - maxVertexUniforms: number; - maxVaryings: number; - maxFragmentUniforms: number; - vertexTextures: boolean; - floatFragmentTextures: boolean; - floatVertexTextures: boolean; - - getMaxAnisotropy(): number; - getMaxPrecision( precision: string ): string; - -} diff --git a/src/renderers/webgl/WebGLClipping.d.ts b/src/renderers/webgl/WebGLClipping.d.ts deleted file mode 100644 index 425be449057ec3..00000000000000 --- a/src/renderers/webgl/WebGLClipping.d.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { Camera } from './../../cameras/Camera'; -import { Material } from './../../materials/Material'; -import { WebGLProperties } from './WebGLProperties'; - -export class WebGLClipping { - - constructor( properties: WebGLProperties ); - - uniform: { value: any; needsUpdate: boolean }; - - /** - * @default 0 - */ - numPlanes: number; - - /** - * @default 0 - */ - numIntersection: number; - - init( planes: any[], enableLocalClipping: boolean, camera: Camera ): boolean; - beginShadows(): void; - endShadows(): void; - setState( - material: Material, - camera: Camera, - useCache: boolean - ): void; - -} diff --git a/src/renderers/webgl/WebGLCubeMaps.d.ts b/src/renderers/webgl/WebGLCubeMaps.d.ts deleted file mode 100644 index 4b78cb6e76bb2e..00000000000000 --- a/src/renderers/webgl/WebGLCubeMaps.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { WebGLRenderer } from '../WebGLRenderer'; - -export class WebGLCubeMaps { - - constructor( renderer: WebGLRenderer ); - - get( texture: any ): any; - dispose(): void; - -} diff --git a/src/renderers/webgl/WebGLExtensions.d.ts b/src/renderers/webgl/WebGLExtensions.d.ts deleted file mode 100644 index eec040419b2cec..00000000000000 --- a/src/renderers/webgl/WebGLExtensions.d.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { WebGLCapabilities } from './WebGLCapabilities'; - -export class WebGLExtensions { - - constructor( gl: WebGLRenderingContext ); - - has( name: string ): boolean; - init( capabilities: WebGLCapabilities ): void; - get( name: string ): any; - -} diff --git a/src/renderers/webgl/WebGLGeometries.d.ts b/src/renderers/webgl/WebGLGeometries.d.ts deleted file mode 100644 index 54169c185ef1f3..00000000000000 --- a/src/renderers/webgl/WebGLGeometries.d.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { WebGLAttributes } from './WebGLAttributes'; -import { WebGLInfo } from './WebGLInfo'; -import { BufferAttribute } from '../../core/BufferAttribute'; -import { BufferGeometry } from '../../core/BufferGeometry'; -import { Object3D } from '../../core/Object3D'; - -export class WebGLGeometries { - - constructor( gl: WebGLRenderingContext, attributes: WebGLAttributes, info: WebGLInfo ); - - get( object: Object3D, geometry: BufferGeometry ): BufferGeometry; - update( geometry: BufferGeometry ): void; - getWireframeAttribute( geometry: BufferGeometry ): BufferAttribute; - -} diff --git a/src/renderers/webgl/WebGLIndexedBufferRenderer.d.ts b/src/renderers/webgl/WebGLIndexedBufferRenderer.d.ts deleted file mode 100644 index 96356e18f822e3..00000000000000 --- a/src/renderers/webgl/WebGLIndexedBufferRenderer.d.ts +++ /dev/null @@ -1,19 +0,0 @@ -export class WebGLIndexedBufferRenderer { - - constructor( - gl: WebGLRenderingContext, - extensions: any, - info: any, - capabilities: any - ); - - setMode( value: any ): void; - setIndex( index: any ): void; - render( start: any, count: number ): void; - renderInstances( - start: any, - count: number, - primcount: number - ): void; - -} diff --git a/src/renderers/webgl/WebGLInfo.d.ts b/src/renderers/webgl/WebGLInfo.d.ts deleted file mode 100644 index eb2f48d5c63ac6..00000000000000 --- a/src/renderers/webgl/WebGLInfo.d.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { WebGLProgram } from './WebGLProgram'; - -/** - * An object with a series of statistical information about the graphics board memory and the rendering process. - */ -export class WebGLInfo { - - constructor( gl: WebGLRenderingContext ); - - /** - * @default true - */ - autoReset: boolean; - - /** - * @default { geometries: 0, textures: 0 } - */ - memory: { - geometries: number; - textures: number; - }; - - /** - * @default null - */ - programs: WebGLProgram[] | null; - - /** - * @default { frame: 0, calls: 0, triangles: 0, points: 0, lines: 0 } - */ - render: { - calls: number; - frame: number; - lines: number; - points: number; - triangles: number; - }; - update( count: number, mode: number, instanceCount: number ): void; - reset(): void; - -} diff --git a/src/renderers/webgl/WebGLLights.d.ts b/src/renderers/webgl/WebGLLights.d.ts deleted file mode 100644 index 2b58df1c63dfb3..00000000000000 --- a/src/renderers/webgl/WebGLLights.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { WebGLExtensions } from './WebGLExtensions'; -import { WebGLCapabilities } from './WebGLCapabilities'; - -export class WebGLLights { - - constructor( extensions: WebGLExtensions, capabilities: WebGLCapabilities ); - - state: { - version: number; - - hash: { - directionalLength: number; - pointLength: number; - spotLength: number; - rectAreaLength: number; - hemiLength: number; - - numDirectionalShadows: number; - numPointShadows: number; - numSpotShadows: number; - }; - - ambient: Array; - probe: Array; - directional: Array; - directionalShadow: Array; - directionalShadowMap: Array; - directionalShadowMatrix: Array; - spot: Array; - spotShadow: Array; - spotShadowMap: Array; - spotShadowMatrix: Array; - rectArea: Array; - point: Array; - pointShadow: Array; - pointShadowMap: Array; - pointShadowMatrix: Array; - hemi: Array; - }; - - get( light: any ): any; - setup( lights: any ): void; - setupView( lights: any, camera: any ): void; - -} diff --git a/src/renderers/webgl/WebGLMaterials.d.ts b/src/renderers/webgl/WebGLMaterials.d.ts deleted file mode 100644 index 238b6cc315178f..00000000000000 --- a/src/renderers/webgl/WebGLMaterials.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { Material } from '../../materials/Material'; -import { IFog } from '../../scenes/Fog'; -import { WebGLProperties } from './WebGLProperties'; - -export class WebGLMaterials { - - constructor( properties: WebGLProperties ); - - refreshMaterialUniforms( uniforms: object, material: Material, pixelRatio: number, height: number ): void; - refreshFogUniforms( uniforms: object, fog: IFog ): void; - -} diff --git a/src/renderers/webgl/WebGLMorphtargets.d.ts b/src/renderers/webgl/WebGLMorphtargets.d.ts deleted file mode 100644 index 473112c04ec310..00000000000000 --- a/src/renderers/webgl/WebGLMorphtargets.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { Object3D } from '../../core/Object3D'; -import { BufferGeometry } from '../../core/BufferGeometry'; -import { Material } from '../../materials/Material'; -import { WebGLProgram } from './WebGLProgram'; - -export class WebGLMorphtargets { - - constructor( gl: WebGLRenderingContext ); - - update( object: Object3D, geometry: BufferGeometry, material: Material, program: WebGLProgram ): void; - -} diff --git a/src/renderers/webgl/WebGLObjects.d.ts b/src/renderers/webgl/WebGLObjects.d.ts deleted file mode 100644 index 73158d5bceb001..00000000000000 --- a/src/renderers/webgl/WebGLObjects.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -export class WebGLObjects { - - constructor( - gl: WebGLRenderingContext, - geometries: any, - attributes: any, - info: any - ); - - update( object: any ): any; - dispose(): void; - -} diff --git a/src/renderers/webgl/WebGLProgram.d.ts b/src/renderers/webgl/WebGLProgram.d.ts deleted file mode 100644 index 3fbd3703c2204c..00000000000000 --- a/src/renderers/webgl/WebGLProgram.d.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { WebGLRenderer } from './../WebGLRenderer'; -import { WebGLShader } from './WebGLShader'; -import { WebGLUniforms } from './WebGLUniforms'; - -export class WebGLProgram { - - constructor( - renderer: WebGLRenderer, - cacheKey: string, - parameters: object - ); - - name: string; - id: number; - cacheKey: string; // unique identifier for this program, used for looking up compiled programs from cache. - - /** - * @default 1 - */ - usedTimes: number; - program: any; - vertexShader: WebGLShader; - fragmentShader: WebGLShader; - /** - * @deprecated Use {@link WebGLProgram#getUniforms getUniforms()} instead. - */ - uniforms: any; - /** - * @deprecated Use {@link WebGLProgram#getAttributes getAttributes()} instead. - */ - attributes: any; - - getUniforms(): WebGLUniforms; - getAttributes(): any; - destroy(): void; - -} diff --git a/src/renderers/webgl/WebGLPrograms.d.ts b/src/renderers/webgl/WebGLPrograms.d.ts deleted file mode 100644 index 5df48f7c8fd860..00000000000000 --- a/src/renderers/webgl/WebGLPrograms.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { WebGLRenderer } from './../WebGLRenderer'; -import { WebGLProgram } from './WebGLProgram'; -import { WebGLCapabilities } from './WebGLCapabilities'; -import { WebGLCubeMaps } from './WebGLCubeMaps'; -import { WebGLExtensions } from './WebGLExtensions'; -import { WebGLClipping } from './WebGLClipping'; -import { WebGLBindingStates } from './WebGLBindingStates'; -import { Material } from './../../materials/Material'; -import { Scene } from './../../scenes/Scene'; - -export class WebGLPrograms { - - constructor( renderer: WebGLRenderer, cubemaps: WebGLCubeMaps, extensions: WebGLExtensions, capabilities: WebGLCapabilities, bindingStates: WebGLBindingStates, clipping: WebGLClipping ); - - programs: WebGLProgram[]; - - getParameters( - material: Material, - lights: any, - shadows: object[], - scene: Scene, - object: any - ): any; - getProgramCacheKey( parameters: any ): string; - getUniforms( material: Material ): object; - acquireProgram( - parameters: any, - cacheKey: string - ): WebGLProgram; - releaseProgram( program: WebGLProgram ): void; - -} diff --git a/src/renderers/webgl/WebGLProperties.d.ts b/src/renderers/webgl/WebGLProperties.d.ts deleted file mode 100644 index 66b76b183704d5..00000000000000 --- a/src/renderers/webgl/WebGLProperties.d.ts +++ /dev/null @@ -1,10 +0,0 @@ -export class WebGLProperties { - - constructor(); - - get( object: any ): any; - remove( object: any ): void; - update( object: any, key: any, value: any ): any; - dispose(): void; - -} diff --git a/src/renderers/webgl/WebGLRenderLists.d.ts b/src/renderers/webgl/WebGLRenderLists.d.ts deleted file mode 100644 index 2beb10e643fe3f..00000000000000 --- a/src/renderers/webgl/WebGLRenderLists.d.ts +++ /dev/null @@ -1,67 +0,0 @@ -import { Object3D } from './../../core/Object3D'; -import { Material } from './../../materials/Material'; -import { WebGLProgram } from './WebGLProgram'; -import { Group } from './../../objects/Group'; -import { Scene } from './../../scenes/Scene'; -import { Camera } from './../../cameras/Camera'; -import { BufferGeometry } from '../../core/BufferGeometry'; -import { WebGLProperties } from './WebGLProperties'; - -export interface RenderTarget {} // not defined in the code, used in LightShadow and WebGRenderer classes - -export interface RenderItem { - id: number; - object: Object3D; - geometry: BufferGeometry | null; - material: Material; - program: WebGLProgram; - groupOrder: number; - renderOrder: number; - z: number; - group: Group | null; -} - -export class WebGLRenderList { - - constructor( properties: WebGLProperties ); - - /** - * @default [] - */ - opaque: Array; - - /** - * @default [] - */ - transparent: Array; - - init(): void; - push( - object: Object3D, - geometry: BufferGeometry | null, - material: Material, - groupOrder: number, - z: number, - group: Group | null - ): void; - unshift( - object: Object3D, - geometry: BufferGeometry | null, - material: Material, - groupOrder: number, - z: number, - group: Group | null - ): void; - sort( opaqueSort: Function, transparentSort: Function ): void; - finish(): void; - -} - -export class WebGLRenderLists { - - constructor( properties: WebGLProperties ); - - dispose(): void; - get( scene: Scene, camera: Camera ): WebGLRenderList; - -} diff --git a/src/renderers/webgl/WebGLRenderStates.d.ts b/src/renderers/webgl/WebGLRenderStates.d.ts deleted file mode 100644 index 12dba2a688a848..00000000000000 --- a/src/renderers/webgl/WebGLRenderStates.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Scene } from '../../scenes/Scene'; -import { Camera } from '../../cameras/Camera'; -import { Light } from '../../lights/Light'; -import { WebGLLights } from './WebGLLights'; -import { WebGLExtensions } from './WebGLExtensions'; -import { WebGLCapabilities } from './WebGLCapabilities'; - -interface WebGLRenderState { - - init(): void; - - state: { - lightsArray: Light[]; - shadowsArray: Light[]; - lights: WebGLLights; - }; - setupLights(): void; - setupLightsView( camera: Camera ): void; - pushLight( light: Light ): void; - pushShadow( shadowLight: Light ): void; - -} - -export class WebGLRenderStates { - - constructor( extensions: WebGLExtensions, capabilities: WebGLCapabilities ); - - // renderCallDepth indexes start from 0. - get( scene: Scene, renderCallDepth?: number ): WebGLRenderState; - - dispose(): void; - -} diff --git a/src/renderers/webgl/WebGLShader.d.ts b/src/renderers/webgl/WebGLShader.d.ts deleted file mode 100644 index e686a7ead0bc75..00000000000000 --- a/src/renderers/webgl/WebGLShader.d.ts +++ /dev/null @@ -1,5 +0,0 @@ -export class WebGLShader { - - constructor( gl: WebGLRenderingContext, type: string, string: string ); - -} diff --git a/src/renderers/webgl/WebGLShadowMap.d.ts b/src/renderers/webgl/WebGLShadowMap.d.ts deleted file mode 100644 index d05cebbf8edb87..00000000000000 --- a/src/renderers/webgl/WebGLShadowMap.d.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { Scene } from './../../scenes/Scene'; -import { Camera } from './../../cameras/Camera'; -import { WebGLRenderer } from '../WebGLRenderer'; -import { ShadowMapType } from '../../constants'; -import { WebGLObjects } from './WebGLObjects'; -import { Light } from '../../lights/Light'; - -export class WebGLShadowMap { - - constructor( - _renderer: WebGLRenderer, - _objects: WebGLObjects, - maxTextureSize: number - ); - - /** - * @default false - */ - enabled: boolean; - - /** - * @default true - */ - autoUpdate: boolean; - - /** - * @default false - */ - needsUpdate: boolean; - - /** - * @default THREE.PCFShadowMap - */ - type: ShadowMapType; - - render( shadowsArray: Light[], scene: Scene, camera: Camera ): void; - - /** - * @deprecated Use {@link Material#shadowSide} instead. - */ - cullFace: any; - -} diff --git a/src/renderers/webgl/WebGLState.d.ts b/src/renderers/webgl/WebGLState.d.ts deleted file mode 100644 index 30caa67330f2c2..00000000000000 --- a/src/renderers/webgl/WebGLState.d.ts +++ /dev/null @@ -1,128 +0,0 @@ -import { CullFace, Blending, BlendingEquation, BlendingSrcFactor, BlendingDstFactor, DepthModes } from '../../constants'; -import { WebGLCapabilities } from './WebGLCapabilities'; -import { WebGLExtensions } from './WebGLExtensions'; -import { Material } from '../../materials/Material'; -import { Vector4 } from '../../math/Vector4'; - -export class WebGLColorBuffer { - - constructor(); - - setMask( colorMask: boolean ): void; - setLocked( lock: boolean ): void; - setClear( r: number, g: number, b: number, a: number, premultipliedAlpha: boolean ): void; - reset(): void; - -} - -export class WebGLDepthBuffer { - - constructor(); - - setTest( depthTest: boolean ): void; - setMask( depthMask: boolean ): void; - setFunc( depthFunc: DepthModes ): void; - setLocked( lock: boolean ): void; - setClear( depth: number ): void; - reset(): void; - -} - -export class WebGLStencilBuffer { - - constructor(); - - setTest( stencilTest: boolean ): void; - setMask( stencilMask: number ): void; - setFunc( stencilFunc: number, stencilRef: number, stencilMask: number ): void; - setOp( stencilFail: number, stencilZFail: number, stencilZPass: number ): void; - setLocked( lock: boolean ): void; - setClear( stencil: number ): void; - reset(): void; - -} - -export class WebGLState { - - constructor( gl: WebGLRenderingContext, extensions: WebGLExtensions, capabilities: WebGLCapabilities ); - - buffers: { - color: WebGLColorBuffer; - depth: WebGLDepthBuffer; - stencil: WebGLStencilBuffer; - }; - - initAttributes(): void; - enableAttribute( attribute: number ): void; - enableAttributeAndDivisor( attribute: number, meshPerAttribute: number ): void; - disableUnusedAttributes(): void; - vertexAttribPointer( index: number, size: number, type: number, normalized: boolean, stride: number, offset: number ): void; - enable( id: number ): void; - disable( id: number ): void; - useProgram( program: any ): boolean; - setBlending( - blending: Blending, - blendEquation?: BlendingEquation, - blendSrc?: BlendingSrcFactor, - blendDst?: BlendingDstFactor, - blendEquationAlpha?: BlendingEquation, - blendSrcAlpha?: BlendingSrcFactor, - blendDstAlpha?: BlendingDstFactor, - premultiplyAlpha?: boolean - ): void; - setMaterial( material: Material, frontFaceCW: boolean ): void; - setFlipSided( flipSided: boolean ): void; - setCullFace( cullFace: CullFace ): void; - setLineWidth( width: number ): void; - setPolygonOffset( polygonoffset: boolean, factor?: number, units?: number ): void; - setScissorTest( scissorTest: boolean ): void; - activeTexture( webglSlot: number ): void; - bindTexture( webglType: number, webglTexture: any ): void; - unbindTexture(): void; - // Same interface as https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext/compressedTexImage2D - compressedTexImage2D( - target: number, - level: number, - internalformat: number, - width: number, - height: number, - border: number, - data: ArrayBufferView - ): void; - // Same interface as https://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext/texImage2D - texImage2D( - target: number, - level: number, - internalformat: number, - width: number, - height: number, - border: number, - format: number, - type: number, - pixels: ArrayBufferView | null - ): void; - texImage2D( - target: number, - level: number, - internalformat: number, - format: number, - type: number, - source: any - ): void; - texImage3D( - target: number, - level: number, - internalformat: number, - width: number, - height: number, - depth: number, - border: number, - format: number, - type: number, - pixels: any - ): void; - scissor( scissor: Vector4 ): void; - viewport( viewport: Vector4 ): void; - reset(): void; - -} diff --git a/src/renderers/webgl/WebGLTextures.d.ts b/src/renderers/webgl/WebGLTextures.d.ts deleted file mode 100644 index a031d3937f0da1..00000000000000 --- a/src/renderers/webgl/WebGLTextures.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { WebGLExtensions } from './WebGLExtensions'; -import { WebGLState } from './WebGLState'; -import { WebGLProperties } from './WebGLProperties'; -import { WebGLCapabilities } from './WebGLCapabilities'; -import { WebGLUtils } from './WebGLUtils'; -import { WebGLInfo } from './WebGLInfo'; - -export class WebGLTextures { - - constructor( - gl: WebGLRenderingContext, - extensions: WebGLExtensions, - state: WebGLState, - properties: WebGLProperties, - capabilities: WebGLCapabilities, - utils: WebGLUtils, - info: WebGLInfo - ); - - allocateTextureUnit(): void; - resetTextureUnits(): void; - setTexture2D( texture: any, slot: number ): void; - setTexture2DArray( texture: any, slot: number ): void; - setTexture3D( texture: any, slot: number ): void; - setTextureCube( texture: any, slot: number ): void; - setupRenderTarget( renderTarget: any ): void; - updateRenderTargetMipmap( renderTarget: any ): void; - updateMultisampleRenderTarget( renderTarget: any ): void; - safeSetTexture2D( texture: any, slot: number ): void; - safeSetTextureCube( texture: any, slot: number ): void; - -} diff --git a/src/renderers/webgl/WebGLUniforms.d.ts b/src/renderers/webgl/WebGLUniforms.d.ts deleted file mode 100644 index b70f3baddd43c9..00000000000000 --- a/src/renderers/webgl/WebGLUniforms.d.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { WebGLProgram } from './WebGLProgram'; -import { WebGLTextures } from './WebGLTextures'; - -export class WebGLUniforms { - - constructor( gl: WebGLRenderingContext, program: WebGLProgram ); - - setValue( gl: WebGLRenderingContext, name: string, value: any, textures: WebGLTextures ): void; - setOptional( gl: WebGLRenderingContext, object: any, name: string ): void; - - static upload( gl: WebGLRenderingContext, seq: any, values: any[], textures: WebGLTextures ): void; - static seqWithValue( seq: any, values: any[] ): any[]; - -} diff --git a/src/renderers/webgl/WebGLUtils.d.ts b/src/renderers/webgl/WebGLUtils.d.ts deleted file mode 100644 index a70856e1401000..00000000000000 --- a/src/renderers/webgl/WebGLUtils.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -export class WebGLUtils { - - constructor( gl: WebGLRenderingContext | WebGL2RenderingContext, extensions: any, capabilities: any ); - - convert( p: any ): void; - -} diff --git a/src/renderers/webxr/WebXR.d.ts b/src/renderers/webxr/WebXR.d.ts deleted file mode 100644 index 5c45b05d2dddf0..00000000000000 --- a/src/renderers/webxr/WebXR.d.ts +++ /dev/null @@ -1,321 +0,0 @@ -export declare type XRSessionMode = 'inline' | 'immersive-vr' | 'immersive-ar'; - -export declare type XRReferenceSpaceType = 'viewer' | 'local' | 'local-floor' | 'bounded-floor' | 'unbounded'; - -export declare type XREnvironmentBlendMode = 'opaque' | 'additive' | 'alpha-blend'; - -export declare type XRVisibilityState = 'visible' | 'visible-blurred' | 'hidden'; - -export declare type XRHandedness = 'none' | 'left' | 'right'; - -export declare type XRTargetRayMode = 'gaze' | 'tracked-pointer' | 'screen'; - -export declare type XREye = 'none' | 'left' | 'right'; - -export declare type XREventType = 'end' | 'select' | 'selectstart' | 'selectend' | 'squeeze' | 'squeezestart' | 'squeezeend' | 'inputsourceschange'; - -export interface XRSpace extends EventTarget {} - -export declare type XRAnimationLoopCallback = ( time: number, frame?: XRFrame ) => void; - -export declare type XRFrameRequestCallback = ( time: number, frame: XRFrame ) => void; - -export interface XR extends EventTarget { - requestSession( mode: XRSessionMode, options?: XRSessionInit ): Promise; - isSessionSupported( mode: XRSessionMode ): Promise; -} - -export interface Window { - XRSession?: Constructor; - XR?: Constructor; -} - -export interface Navigator { - xr?: XR; -} - -export interface XRReferenceSpace extends XRSpace { - getOffsetReferenceSpace( originOffset: XRRigidTransform ): XRReferenceSpace; -} -export interface XRHitTestOptionsInit { - space: XRSpace; - offsetRay?: XRRay; -} - -export interface XRTransientInputHitTestOptionsInit { - profile: string; - offsetRay?: XRRay; -} - -export interface XRViewport { - readonly x: number; - readonly y: number; - readonly width: number; - readonly height: number; -} - -export interface WebGLRenderingContext { - makeXRCompatible(): Promise; -} - -export interface XRRenderState { - readonly depthNear: number; - readonly depthFar: number; - readonly inlineVerticalFieldOfView?: number; - readonly baseLayer?: XRWebGLLayer; -} - -export interface XRRenderStateInit { - depthNear?: number; - depthFar?: number; - inlineVerticalFieldOfView?: number; - baseLayer?: XRWebGLLayer; -} - -export interface XRInputSource { - readonly handedness: XRHandedness; - readonly targetRayMode: XRTargetRayMode; - readonly targetRaySpace: XRSpace; - readonly gripSpace?: XRSpace; - readonly profiles: Array; - readonly gamepad: Gamepad; - readonly hand?: XRHand; -} - -export interface XRSessionInit { - optionalFeatures?: string[]; - requiredFeatures?: string[]; -} - -export interface XRSession { - addEventListener: Function; - removeEventListener: Function; - requestReferenceSpace( type: XRReferenceSpaceType ): Promise; - updateRenderState( renderStateInit: XRRenderStateInit ): Promise; - requestAnimationFrame( callback: XRFrameRequestCallback ): number; - cancelAnimationFrame( id: number ): void; - end(): Promise; - renderState: XRRenderState; - inputSources: Array; - environmentBlendMode: XREnvironmentBlendMode; - visibilityState: XRVisibilityState; - - // hit test - requestHitTestSource( options: XRHitTestOptionsInit ): Promise; - requestHitTestSourceForTransientInput( options: XRTransientInputHitTestOptionsInit ): Promise; - - // legacy AR hit test - requestHitTest( ray: XRRay, referenceSpace: XRReferenceSpace ): Promise; - - // legacy plane detection - updateWorldTrackingState( options: { planeDetectionState?: { enabled: boolean } } ): void; -} - -export interface XRReferenceSpace extends XRSpace { - getOffsetReferenceSpace( originOffset: XRRigidTransform ): XRReferenceSpace; - onreset: any; -} - -export declare type XRPlaneSet = Set; -export declare type XRAnchorSet = Set; - -export interface XRFrame { - readonly session: XRSession; - getViewerPose( referenceSpace: XRReferenceSpace ): XRViewerPose | undefined; - getPose( space: XRSpace, baseSpace: XRSpace ): XRPose | undefined; - - // AR - getHitTestResults( hitTestSource: XRHitTestSource ): Array; - getHitTestResultsForTransientInput( hitTestSource: XRTransientInputHitTestSource ): Array; - // Anchors - trackedAnchors?: XRAnchorSet; - createAnchor( pose: XRRigidTransform, space: XRSpace ): Promise; - // Planes - worldInformation: { - detectedPlanes?: XRPlaneSet; - }; - // Hand tracking - getJointPose( joint: XRJointSpace, baseSpace: XRSpace ): XRJointPose; -} - -export interface XRViewerPose { - readonly transform: XRRigidTransform; - readonly views: Array -} - -export interface XRPose { - readonly emulatedPosition: boolean; - readonly transform: XRRigidTransform; -} - -export interface XRWebGLLayerInit { - antialias?: boolean; - depth?: boolean; - stencil?: boolean; - alpha?: boolean; - ignoreDepthValues?: boolean; - framebufferScaleFactor?: number; -} - -export interface XRLayer {} - -export interface XRWebGLLayer extends XRLayer{ - framebuffer: WebGLFramebuffer; - framebufferWidth: number; - framebufferHeight: number; - getViewport( view: XRView ): XRViewport; -} - -export declare class XRWebGLLayer implements XRWebGLLayer { - - constructor( session: XRSession, gl: WebGLRenderingContext | undefined, options?: XRWebGLLayerInit ) - -} - -export interface DOMPointInit { - w?: number; - x?: number; - y?: number; - z?: number; -} - -export declare class XRRigidTransform { - - constructor( matrix: Float32Array | DOMPointInit, direction?: DOMPointInit ); - position: DOMPointReadOnly; - orientation: DOMPointReadOnly; - matrix: Float32Array; - inverse: XRRigidTransform; - -} - -export interface XRView { - readonly eye: XREye; - readonly projectionMatrix: Float32Array; - readonly viewMatrix: Float32Array; - readonly transform: XRRigidTransform; -} - -export interface XRRayDirectionInit { - x?: number; - y?: number; - z?: number; - w?: number; -} - -export declare class XRRay { - - readonly origin: DOMPointReadOnly; - readonly direction: XRRayDirectionInit; - matrix: Float32Array; - - constructor( transformOrOrigin: XRRigidTransform | DOMPointInit, direction?: XRRayDirectionInit ) - -} - -export declare enum XRHitTestTrackableType { - 'point', 'plane', 'mesh', -} - -export interface XRHitResult { - hitMatrix: Float32Array; -} - -export interface XRTransientInputHitTestResult { - readonly inputSource: XRInputSource; - readonly results: Array; -} - -export interface XRHitTestResult { - getPose( baseSpace: XRSpace ): XRPose | undefined | null; - // When anchor system is enabled - createAnchor?( pose: XRRigidTransform ): Promise; -} - -export interface XRHitTestSource { - cancel(): void; -} - -export interface XRTransientInputHitTestSource { - cancel(): void; -} - -export interface XRHitTestOptionsInit { - space: XRSpace; - entityTypes?: Array; - offsetRay?: XRRay; -} - -export interface XRTransientInputHitTestOptionsInit { - profile: string; - entityTypes?: Array; - offsetRay?: XRRay; -} - -export interface XRAnchor { - anchorSpace: XRSpace; - delete(): void; -} - -export interface XRPlane { - orientation: 'Horizontal' | 'Vertical'; - planeSpace: XRSpace; - polygon: Array; - lastChangedTime: number; -} - -export declare enum XRHandJoint { - 'wrist', - 'thumb-metacarpal', - 'thumb-phalanx-proximal', - 'thumb-phalanx-distal', - 'thumb-tip', - 'index-finger-metacarpal', - 'index-finger-phalanx-proximal', - 'index-finger-phalanx-intermediate', - 'index-finger-phalanx-distal', - 'index-finger-tip', - 'middle-finger-metacarpal', - 'middle-finger-phalanx-proximal', - 'middle-finger-phalanx-intermediate', - 'middle-finger-phalanx-distal', - 'middle-finger-tip', - 'ring-finger-metacarpal', - 'ring-finger-phalanx-proximal', - 'ring-finger-phalanx-intermediate', - 'ring-finger-phalanx-distal', - 'ring-finger-tip', - 'pinky-finger-metacarpal', - 'pinky-finger-phalanx-proximal', - 'pinky-finger-phalanx-intermediate', - 'pinky-finger-phalanx-distal', - 'pinky-finger-tip' -} - -export interface XRJointSpace extends XRSpace { - readonly jointName: XRHandJoint; -} - -export interface XRJointPose extends XRPose { - readonly radius: number | undefined; -} - -export interface XRHand extends Map { - readonly size: number; -} - -declare type Constructor = { - new ( ...args: any[] ): T, - prototype: T -}; - -export interface XRInputSourceChangeEvent { - session: XRSession; - removed: Array; - added: Array; -} - -export interface XRInputSourceEvent extends Event { - readonly frame: XRFrame; - readonly inputSource: XRInputSource; -} diff --git a/src/renderers/webxr/WebXRController.d.ts b/src/renderers/webxr/WebXRController.d.ts deleted file mode 100644 index 94056f962ec559..00000000000000 --- a/src/renderers/webxr/WebXRController.d.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Group } from '../../objects/Group'; -import { XREventType, XRFrame, XRInputSource, XRReferenceSpace } from './WebXR'; - -export type XRControllerEventType = XREventType | 'disconnected' | 'connected' - -export class WebXRController { - - constructor(); - - getTargetRaySpace(): Group; - getGripSpace(): Group; - dispatchEvent( event: { type: XRControllerEventType, data?: XRInputSource } ): this; - disconnect( inputSource: XRInputSource ): this; - update( inputSource: XRInputSource, frame: XRFrame, referenceSpace: XRReferenceSpace ): this; - -} diff --git a/src/renderers/webxr/WebXRManager.d.ts b/src/renderers/webxr/WebXRManager.d.ts deleted file mode 100644 index 1bcddb758692aa..00000000000000 --- a/src/renderers/webxr/WebXRManager.d.ts +++ /dev/null @@ -1,32 +0,0 @@ -import { Group } from '../../objects/Group'; -import { Camera } from '../../cameras/Camera'; -import { EventDispatcher } from '../../core/EventDispatcher'; -import { XRFrameRequestCallback, XRReferenceSpace, XRReferenceSpaceType, XRSession } from './WebXR'; - -export class WebXRManager extends EventDispatcher { - - constructor( renderer: any, gl: WebGLRenderingContext ); - - /** - * @default false - */ - enabled: boolean; - - /** - * @default false - */ - isPresenting: boolean; - - getController( id: number ): Group; - getControllerGrip( id: number ): Group; - getHand( id: number ): Group; - setFramebufferScaleFactor( value: number ): void; - setReferenceSpaceType( value: XRReferenceSpaceType ): void; - getReferenceSpace(): XRReferenceSpace; - getSession(): XRSession; - setSession( value: XRSession ): void; - getCamera( camera: Camera ): Camera; - setAnimationLoop( callback: XRFrameRequestCallback ): void; - dispose(): void; - -} diff --git a/src/scenes/Fog.d.ts b/src/scenes/Fog.d.ts deleted file mode 100644 index 5d129ec65f4658..00000000000000 --- a/src/scenes/Fog.d.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { Color } from './../math/Color'; - -export interface IFog { - name: string; - color: Color; - clone(): IFog; - toJSON(): any; -} - -/** - * This class contains the parameters that define linear fog, i.e., that grows linearly denser with the distance. - */ -export class Fog implements IFog { - - constructor( color: Color | number | string, near?: number, far?: number ); - - /** - * @default '' - */ - name: string; - - /** - * Fog color. - */ - color: Color; - - /** - * The minimum distance to start applying fog. Objects that are less than 'near' units from the active camera won't be affected by fog. - * @default 1 - */ - near: number; - - /** - * The maximum distance at which fog stops being calculated and applied. Objects that are more than 'far' units away from the active camera won't be affected by fog. - * @default 1000 - */ - far: number; - - readonly isFog: true; - - clone(): Fog; - toJSON(): any; - -} diff --git a/src/scenes/FogExp2.d.ts b/src/scenes/FogExp2.d.ts deleted file mode 100644 index eabf17b4758989..00000000000000 --- a/src/scenes/FogExp2.d.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Color } from './../math/Color'; -import { IFog } from './Fog'; -/** - * This class contains the parameters that define linear fog, i.e., that grows exponentially denser with the distance. - */ -export class FogExp2 implements IFog { - - constructor( hex: number | string, density?: number ); - - /** - * @default '' - */ - name: string; - - color: Color; - - /** - * Defines how fast the fog will grow dense. - * @default 0.00025 - */ - density: number; - - readonly isFogExp2: true; - - clone(): FogExp2; - toJSON(): any; - -} diff --git a/src/scenes/Scene.d.ts b/src/scenes/Scene.d.ts deleted file mode 100644 index 82785bb5004553..00000000000000 --- a/src/scenes/Scene.d.ts +++ /dev/null @@ -1,72 +0,0 @@ -import { IFog } from './Fog'; -import { Material } from './../materials/Material'; -import { Object3D } from './../core/Object3D'; -import { Color } from '../math/Color'; -import { Texture } from '../textures/Texture'; -import { WebGLRenderer } from '../renderers/WebGLRenderer'; -import { Camera } from '../cameras/Camera'; -import { WebGLRenderTarget } from '../renderers/WebGLRenderTarget'; -import { WebGLCubeRenderTarget } from '../renderers/WebGLCubeRenderTarget'; - -// Scenes ///////////////////////////////////////////////////////////////////// - -/** - * Scenes allow you to set up what and where is to be rendered by three.js. This is where you place objects, lights and cameras. - */ -export class Scene extends Object3D { - - constructor(); - - type: 'Scene'; - - /** - * A fog instance defining the type of fog that affects everything rendered in the scene. Default is null. - * @default null - */ - fog: IFog | null; - - /** - * If not null, it will force everything in the scene to be rendered with that material. Default is null. - * @default null - */ - overrideMaterial: Material | null; - - /** - * @default true - */ - autoUpdate: boolean; - - /** - * @default null - */ - background: null | Color | Texture | WebGLCubeRenderTarget; - - /** - * @default null - */ - environment: null | Texture; - - readonly isScene: true; - - /** - * Calls before rendering scene - */ - onBeforeRender: ( - renderer: WebGLRenderer, - scene: Scene, - camera: Camera, - renderTarget: WebGLRenderTarget | any // any required for Object3D.onBeforeRender compatibility - ) => void; - - /** - * Calls after rendering scene - */ - onAfterRender: ( - renderer: WebGLRenderer, - scene: Scene, - camera: Camera - ) => void; - - toJSON( meta?: any ): any; - -} diff --git a/src/textures/CanvasTexture.d.ts b/src/textures/CanvasTexture.d.ts deleted file mode 100644 index 8a04dc4ed89178..00000000000000 --- a/src/textures/CanvasTexture.d.ts +++ /dev/null @@ -1,38 +0,0 @@ -import { Texture } from './Texture'; -import { - Mapping, - Wrapping, - TextureFilter, - PixelFormat, - TextureDataType, -} from '../constants'; - -export class CanvasTexture extends Texture { - - /** - * @param canvas - * @param [format=THREE.RGBAFormat] - * @param [type=THREE.UnsignedByteType] - * @param [mapping=THREE.Texture.DEFAULT_MAPPING] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.LinearFilter] - * @param [minFilter=THREE.LinearMipmapLinearFilter] - * @param [anisotropy=1] - * @param [encoding=THREE.LinearEncoding] - */ - constructor( - canvas: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ImageBitmap, - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - format?: PixelFormat, - type?: TextureDataType, - anisotropy?: number - ); - - readonly isCanvasTexture: true; - -} diff --git a/src/textures/CompressedTexture.d.ts b/src/textures/CompressedTexture.d.ts deleted file mode 100644 index c2316ba46b31f7..00000000000000 --- a/src/textures/CompressedTexture.d.ts +++ /dev/null @@ -1,58 +0,0 @@ -import { Texture } from './Texture'; -import { - Mapping, - Wrapping, - TextureFilter, - CompressedPixelFormat, - TextureDataType, - TextureEncoding, -} from '../constants'; - -export class CompressedTexture extends Texture { - - /** - * @param mipmaps - * @param width - * @param height - * @param [format=THREE.RGBAFormat] - * @param [type=THREE.UnsignedByteType] - * @param [mapping=THREE.Texture.DEFAULT_MAPPING] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.LinearFilter] - * @param [minFilter=THREE.LinearMipmapLinearFilter] - * @param [anisotropy=1] - * @param [encoding=THREE.LinearEncoding] - */ - constructor( - mipmaps: ImageData[], - width: number, - height: number, - format?: CompressedPixelFormat, - type?: TextureDataType, - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - anisotropy?: number, - encoding?: TextureEncoding - ); - - image: { width: number; height: number }; - - mipmaps: ImageData[]; - - /** - * @default false - */ - flipY: boolean; - - /** - * @default false - */ - generateMipmaps: boolean; - - readonly isCompressedTexture: true; - -} diff --git a/src/textures/CubeTexture.d.ts b/src/textures/CubeTexture.d.ts deleted file mode 100644 index 662817f2a89a02..00000000000000 --- a/src/textures/CubeTexture.d.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { Texture } from './Texture'; -import { - Mapping, - Wrapping, - TextureFilter, - PixelFormat, - TextureDataType, - TextureEncoding, -} from '../constants'; - -export class CubeTexture extends Texture { - - /** - * @param [images=[]] - * @param [mapping=THREE.CubeReflectionMapping] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.LinearFilter] - * @param [minFilter=THREE.LinearMipmapLinearFilter] - * @param [format=THREE.RGBFormat] - * @param [type=THREE.UnsignedByteType] - * @param [anisotropy=1] - * @param [encoding=THREE.LinearEncoding] - */ - constructor( - images?: any[], // HTMLImageElement or HTMLCanvasElement - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - format?: PixelFormat, - type?: TextureDataType, - anisotropy?: number, - encoding?: TextureEncoding - ); - - images: any; // returns and sets the value of Texture.image in the codde ? - - /** - * @default false - */ - flipY: boolean; - - readonly isCubeTexture: true; - -} diff --git a/src/textures/DataTexture.d.ts b/src/textures/DataTexture.d.ts deleted file mode 100644 index a56931f795065c..00000000000000 --- a/src/textures/DataTexture.d.ts +++ /dev/null @@ -1,67 +0,0 @@ -import { Texture } from './Texture'; -import { - Mapping, - Wrapping, - TextureFilter, - PixelFormat, - TextureDataType, - TextureEncoding, -} from '../constants'; -import { TypedArray } from '../polyfills'; - -export class DataTexture extends Texture { - - /** - * @param data - * @param width - * @param height - * @param [format=THREE.RGBAFormat] - * @param [type=THREE.UnsignedByteType] - * @param [mapping=THREE.Texture.DEFAULT_MAPPING] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.NearestFilter] - * @param [minFilter=THREE.NearestFilter] - * @param [anisotropy=1] - * @param [encoding=THREE.LinearEncoding] - */ - constructor( - data: TypedArray, - width: number, - height: number, - format?: PixelFormat, - type?: TextureDataType, - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - anisotropy?: number, - encoding?: TextureEncoding - ); - - image: ImageData; - - /** - * @default false - */ - flipY: boolean; - - /** - * @default false - */ - generateMipmaps: boolean; - - /** - * @default 1 - */ - unpackAlignment: number; - - /** - * @default THREE.DepthFormat - */ - format: PixelFormat; - - readonly isDataTexture: true; - -} diff --git a/src/textures/DataTexture2DArray.d.ts b/src/textures/DataTexture2DArray.d.ts deleted file mode 100644 index 1a1bd059682c5d..00000000000000 --- a/src/textures/DataTexture2DArray.d.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { Texture } from './Texture'; -import { TypedArray } from '../polyfills'; -import { TextureFilter } from '../constants'; - -export class DataTexture2DArray extends Texture { - - constructor( - data: TypedArray, - width: number, - height: number, - depth: number - ); - - /** - * @default THREE.NearestFilter - */ - magFilter: TextureFilter; - - /** - * @default THREE.NearestFilter - */ - minFilter: TextureFilter; - - /** - * @default THREE.ClampToEdgeWrapping - */ - wrapR: boolean; - - /** - * @default false - */ - flipY: boolean; - - /** - * @default false - */ - generateMipmaps: boolean; - - readonly isDataTexture2DArray: true; - -} diff --git a/src/textures/DataTexture3D.d.ts b/src/textures/DataTexture3D.d.ts deleted file mode 100644 index c48f679ef0dd39..00000000000000 --- a/src/textures/DataTexture3D.d.ts +++ /dev/null @@ -1,41 +0,0 @@ -import { Texture } from './Texture'; -import { TypedArray } from '../polyfills'; -import { TextureFilter } from '../constants'; - -export class DataTexture3D extends Texture { - - constructor( - data: TypedArray, - width: number, - height: number, - depth: number - ); - - /** - * @default THREE.NearestFilter - */ - magFilter: TextureFilter; - - /** - * @default THREE.NearestFilter - */ - minFilter: TextureFilter; - - /** - * @default THREE.ClampToEdgeWrapping - */ - wrapR: boolean; - - /** - * @default false - */ - flipY: boolean; - - /** - * @default false - */ - generateMipmaps: boolean; - - readonly isDataTexture3D: true; - -} diff --git a/src/textures/DepthTexture.d.ts b/src/textures/DepthTexture.d.ts deleted file mode 100644 index df5fe302182535..00000000000000 --- a/src/textures/DepthTexture.d.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Texture } from './Texture'; -import { - Mapping, - Wrapping, - TextureFilter, - TextureDataType, -} from '../constants'; - -export class DepthTexture extends Texture { - - /** - * @param width - * @param height - * @param type - * @param [mapping=THREE.Texture.DEFAULT_MAPPING] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.NearestFilter] - * @param [minFilter=THREE.NearestFilter] - * @param [anisotropy=1] - */ - constructor( - width: number, - height: number, - type?: TextureDataType, - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - anisotropy?: number - ); - - image: { width: number; height: number }; - - /** - * @default false - */ - flipY: boolean; - - /** - * @default false - */ - generateMipmaps: boolean; - - readonly isDepthTexture: true; - -} diff --git a/src/textures/Texture.d.ts b/src/textures/Texture.d.ts deleted file mode 100644 index ccc50ac95532b3..00000000000000 --- a/src/textures/Texture.d.ts +++ /dev/null @@ -1,175 +0,0 @@ -import { Vector2 } from './../math/Vector2'; -import { Matrix3 } from './../math/Matrix3'; -import { EventDispatcher } from './../core/EventDispatcher'; -import { - Mapping, - Wrapping, - TextureFilter, - PixelFormat, - PixelFormatGPU, - TextureDataType, - TextureEncoding -} from '../constants'; - -export class Texture extends EventDispatcher { - - /** - * @param [image] - * @param [mapping=THREE.Texture.DEFAULT_MAPPING] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.LinearFilter] - * @param [minFilter=THREE.LinearMipmapLinearFilter] - * @param [format=THREE.RGBAFormat] - * @param [type=THREE.UnsignedByteType] - * @param [anisotropy=1] - * @param [encoding=THREE.LinearEncoding] - */ - constructor( - image?: HTMLImageElement | HTMLCanvasElement | HTMLVideoElement, - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - format?: PixelFormat, - type?: TextureDataType, - anisotropy?: number, - encoding?: TextureEncoding - ); - - id: number; - uuid: string; - - /** - * @default '' - */ - name: string; - sourceFile: string; - - /** - * @default THREE.Texture.DEFAULT_IMAGE - */ - image: any; // HTMLImageElement or ImageData or { width: number, height: number } in some children; - - /** - * @default [] - */ - mipmaps: any[]; // ImageData[] for 2D textures and CubeTexture[] for cube textures; - - /** - * @default THREE.Texture.DEFAULT_MAPPING - */ - mapping: Mapping; - - /** - * @default THREE.ClampToEdgeWrapping - */ - wrapS: Wrapping; - - /** - * @default THREE.ClampToEdgeWrapping - */ - wrapT: Wrapping; - - /** - * @default THREE.LinearFilter - */ - magFilter: TextureFilter; - - /** - * @default THREE.LinearMipmapLinearFilter - */ - minFilter: TextureFilter; - - /** - * @default 1 - */ - anisotropy: number; - - /** - * @default THREE.RGBAFormat - */ - format: PixelFormat; - - internalFormat: PixelFormatGPU | null; - - /** - * @default THREE.UnsignedByteType - */ - type: TextureDataType; - - /** - * @default new THREE.Matrix3() - */ - matrix: Matrix3; - - /** - * @default true - */ - matrixAutoUpdate: boolean; - - /** - * @default new THREE.Vector2( 0, 0 ) - */ - offset: Vector2; - - /** - * @default new THREE.Vector2( 1, 1 ) - */ - repeat: Vector2; - - /** - * @default new THREE.Vector2( 0, 0 ) - */ - center: Vector2; - - /** - * @default 0 - */ - rotation: number; - - /** - * @default true - */ - generateMipmaps: boolean; - - /** - * @default false - */ - premultiplyAlpha: boolean; - - /** - * @default true - */ - flipY: boolean; - - /** - * @default 4 - */ - unpackAlignment: number; - - /** - * @default THREE.LinearEncoding - */ - encoding: TextureEncoding; - - /** - * @default 0 - */ - version: number; - needsUpdate: boolean; - readonly isTexture: true; - - onUpdate: () => void; - static DEFAULT_IMAGE: any; - static DEFAULT_MAPPING: any; - - clone(): Texture; - copy( source: Texture ): this; - toJSON( meta: any ): any; - dispose(): void; - transformUv( uv: Vector2 ): Vector2; - updateMatrix(): void; - -} diff --git a/src/textures/VideoTexture.d.ts b/src/textures/VideoTexture.d.ts deleted file mode 100644 index 4afd718723a322..00000000000000 --- a/src/textures/VideoTexture.d.ts +++ /dev/null @@ -1,42 +0,0 @@ -import { Texture } from './Texture'; -import { - Mapping, - Wrapping, - TextureFilter, - PixelFormat, - TextureDataType, -} from '../constants'; - -export class VideoTexture extends Texture { - - /** - * @param video - * @param [mapping=THREE.Texture.DEFAULT_MAPPING] - * @param [wrapS=THREE.ClampToEdgeWrapping] - * @param [wrapT=THREE.ClampToEdgeWrapping] - * @param [magFilter=THREE.LinearFilter] - * @param [minFilter=THREE.LinearFilter] - * @param [format=THREE.RGBFormat] - * @param [type=THREE.UnsignedByteType] - * @param [anisotropy=1] - */ - constructor( - video: HTMLVideoElement, - mapping?: Mapping, - wrapS?: Wrapping, - wrapT?: Wrapping, - magFilter?: TextureFilter, - minFilter?: TextureFilter, - format?: PixelFormat, - type?: TextureDataType, - anisotropy?: number - ); - - readonly isVideoTexture: true; - - /** - * @default false - */ - generateMipmaps: boolean; - -} diff --git a/src/utils.d.ts b/src/utils.d.ts deleted file mode 100644 index d74f7bf918f45d..00000000000000 --- a/src/utils.d.ts +++ /dev/null @@ -1,2 +0,0 @@ -export function arrayMin( array: number[] ): number; -export function arrayMax( array: number[] ): number; diff --git a/utils/build/tsconfig-examples.lint.json b/utils/build/tsconfig-examples.lint.json deleted file mode 100644 index a29e24478dae6f..00000000000000 --- a/utils/build/tsconfig-examples.lint.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "compilerOptions": { - "noEmit": true, - "target": "ES6", - "strict": true - }, - "include": [ - "../../examples/jsm/**/*.ts" - ] -} diff --git a/utils/build/tsconfig.lint.json b/utils/build/tsconfig.lint.json deleted file mode 100644 index f56e8134398091..00000000000000 --- a/utils/build/tsconfig.lint.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "compilerOptions": { - "noEmit": true, - "target": "ES6", - "strict": true - }, - "include": [ - "../../src/**/*.ts" - ] -}