UNPKG

@threepipe/plugin-path-tracing

Version:

Path tracing plugin interfaces for Threepipe

37 lines 1.66 kB
import { AViewerPluginSync, ProgressivePlugin, ThreeViewer } from 'threepipe'; import { WebGLPathTracer } from 'three-gpu-pathtracer'; /** * ThreeGpuPathTracerPlugin * * Path Tracing plugin for Threepipe using [three-gpu-pathtracer](https://github.com/gkjohnson/three-gpu-pathtracer). * * This plugin allows for GPU-accelerated path tracing in Three.js scenes. (using webgl2) * * It provides options to configure the path tracing parameters such as bounces, samples per frame, and more. * It also integrates with the Three.js scene and camera, updating materials and lights as needed. * Serialization and deserialization are supported for plugin state management. * It listens to scene updates, camera changes, and material updates to refresh the path tracing setup. * It can be enabled or disabled, and it automatically handles rendering to the screen or to a texture. * It supports progressive rendering, allowing for a smooth transition of rendered frames. * */ export declare class ThreeGpuPathTracerPlugin extends AViewerPluginSync { static readonly PluginType = "ThreeGpuPathTracerPlugin"; enabled: boolean; get maxFrameCount(): number; set maxFrameCount(value: number); samplesPerFrame: number; tracer: WebGLPathTracer | undefined; dependencies: (typeof ProgressivePlugin)[]; constructor(enabled?: boolean); private _enableChange; setDirty(): void; onAdded(viewer: ThreeViewer): void; private _refreshing; private _sceneNeedsRefresh; refreshScene(): void; private _refreshScene; reset(): void; dispose(): void; } //# sourceMappingURL=ThreeGpuPathTracerPlugin.d.ts.map