UNPKG

threepipe

Version:

A 3D viewer framework built on top of three.js in TypeScript with a focus on quality rendering, modularity and extensibility.

36 lines 1.42 kB
import { IPassID, IPipelinePass } from '../../postprocessing'; import { AViewerPluginSync, ISerializedConfig, ThreeViewer } from '../../viewer'; import { SerializationMetaType } from '../../utils'; import { ICamera, IRenderManager, IScene } from '../../core'; /** * Pipeline Pass Plugin * * Base class for creating a plugin that registers a custom pass to the main render pipeline * * @category Plugins */ export declare abstract class PipelinePassPlugin<T extends IPipelinePass, TPassId extends IPassID, TEvent extends string, TViewer extends ThreeViewer = ThreeViewer> extends AViewerPluginSync<TEvent, TViewer> { abstract passId: TPassId; enabled: boolean; protected _pass?: T; protected abstract _createPass(): T; /** * This function is called every frame before composer render, if this pass is being used in the pipeline * @param _ * @param _1 * @param _2 */ protected _beforeRender(_?: IScene, _1?: ICamera, _2?: IRenderManager): boolean; constructor(); onAdded(viewer: TViewer): void; onRemove(viewer: TViewer): void; get pass(): T | undefined; toJSON(meta?: SerializationMetaType): ISerializedConfig & { pass?: any; }; fromJSON(data: ISerializedConfig & { pass?: any; }, meta?: SerializationMetaType): this | null | Promise<this | null>; setDirty(): void; } //# sourceMappingURL=PipelinePassPlugin.d.ts.map