UNPKG

@animech-public/playcanvas

Version:
2 lines (1 loc) 665 B
import{RenderPass as r}from"../../platform/graphics/render-pass.js";import{SHADER_FORWARDHDR as e}from"../../scene/constants.js";class s extends r{constructor(r,e,s,t,i,o){super(r),this.viewBindGroups=[],this.renderer=e,this.camera=s,this.worldClusters=t,this.receivers=i,this.lightArray=o}destroy(){this.viewBindGroups.forEach((r=>{r.defaultUniformBuffer.destroy(),r.destroy()})),this.viewBindGroups.length=0}execute(){this.device;const{renderer:r,camera:s,receivers:t,renderTarget:i,worldClusters:o,lightArray:n}=this;r.renderForwardLayer(s,i,null,void 0,e,this.viewBindGroups,{meshInstances:t,splitLights:n,lightClusters:o})}}export{s as RenderPassLightmapper};