import { Object3D, PerspectiveCamera, Box3 } from 'three'; import { CustomObjectIntersection } from './CustomObjectIntersection'; import { CustomObjectIntersectInput } from './CustomObjectIntersectInput'; import { ICustomObject } from './ICustomObject'; /** * This class encasulate a Object3D, and made it possible to add flags to it. * It might be extended with more flags in the future. * @beta */ export declare class CustomObject implements ICustomObject { private readonly _object; private _isPartOfBoundingBox; private _shouldPick; private _shouldPickBoundingBox; private _useDepthTest; private _receiveShadow; /** * Constructor * @beta */ constructor(object: Object3D); /** * Get the Object3D * @beta */ get object(): Object3D; /** * Set or get whether it should be part of the combined bounding box or not. * Default is true. * @beta */ get isPartOfBoundingBox(): boolean; set isPartOfBoundingBox(value: boolean); /** * Set or get whether it should be picked by the camera manager * Default is false. * @beta */ get shouldPick(): boolean; set shouldPick(value: boolean); /** * Set or get whether it should be also give the bounding box when picked by the camera * Default is false. * @beta */ get shouldPickBoundingBox(): boolean; set shouldPickBoundingBox(value: boolean); /** * Get whether it should be rendered with depth test (on top on other objects) * Default is true. * @beta */ get useDepthTest(): boolean; set useDepthTest(value: boolean); /** * Whether CAD shadows fall on this object. * Default is false. * @deprecated No longer read. Request the shadow on the material instead with * `CustomObjectEffectMaterial.setReceivesShadow`. * @beta */ get receiveShadow(): boolean; set receiveShadow(value: boolean); /** * Get the bounding box from the object * @beta */ getBoundingBox(target: Box3): Box3; /** * Intersect the object with the raycaster. * This function can be overridden to provide custom intersection logic. * @beta */ intersectIfCloser(intersectInput: CustomObjectIntersectInput, closestDistance: number | undefined): undefined | CustomObjectIntersection; /** * This method is called before rendering of the custom object * @beta */ beforeRender(_camera: PerspectiveCamera): void; }