UNPKG

@polygonjs/polygonjs

Version:

node-based WebGL 3D engine https://polygonjs.com

25 lines (24 loc) 726 B
import { WebGLRenderTarget, Camera, OrthographicCamera, Scene, ShaderMaterial, Texture } from 'three'; export interface DepthReadMaterial extends ShaderMaterial { unifoms: { cameraNear: { value: number; }; cameraFar: { value: number; }; tDiffuse: { value: Texture | null; }; tDepth: { value: Texture | null; }; }; } export interface DepthSetup { scene: Scene; camera: OrthographicCamera; material: DepthReadMaterial; } export declare function setupDepthReadScene(): DepthSetup; export declare function updateDepthSetup(setup: DepthSetup, camera: Camera, renderTarget: WebGLRenderTarget): void;