threepipe
Version:
A 3D viewer framework built on top of three.js in TypeScript with a focus on quality rendering, modularity and extensibility.
34 lines • 1.68 kB
TypeScript
import { Light, LightShadow, Object3D } from 'three';
import { IObject3D, IObject3DEvent, IObject3DEventTypes, IObject3DUserData } from '../IObject';
export interface ILight<TShadowSupport extends LightShadow | undefined = LightShadow | undefined, E extends ILightEvent = ILightEvent, ET extends ILightEventTypes = ILightEventTypes> extends Light<TShadowSupport, E, ET>, IObject3D<E, ET> {
assetType: 'light';
readonly isLight: true;
/**
* @deprecated use `this` instead
*/
lightObject: this;
userData: IObject3DUserData;
/**
* @param removeFromParent - remove from parent. Default true
*/
dispose(removeFromParent?: boolean): void;
target?: Object3D;
traverse(callback: (object: IObject3D) => void): void;
traverseVisible(callback: (object: IObject3D) => void): void;
traverseAncestors(callback: (object: IObject3D) => void): void;
getObjectById<T extends IObject3D = IObject3D>(id: number): T | undefined;
getObjectByName<T extends IObject3D = IObject3D>(name: string): T | undefined;
getObjectByProperty<T extends IObject3D = IObject3D>(name: string, value: string): T | undefined;
copy(source: this, recursive?: boolean, distanceFromTarget?: number, worldSpace?: boolean, ...args: any[]): this;
clone(recursive?: boolean): this;
add(...object: IObject3D[]): this;
remove(...object: IObject3D[]): this;
parent: IObject3D | null;
children: IObject3D[];
}
export type ILightEventTypes = IObject3DEventTypes | 'lightUpdate';
export type ILightEvent = Omit<IObject3DEvent, 'type'> & {
type: ILightEventTypes;
light?: ILight | null;
};
//# sourceMappingURL=ILight.d.ts.map