fix(renderTarget): 修复了threeJS更新版本后引发的renderPass渲染问题

This commit is contained in:
mipha.ly 2019-03-16 20:00:32 +08:00 committed by 刘叶
parent 113aae900b
commit 81e0f15873
3 changed files with 11 additions and 1 deletions

View File

@ -43,6 +43,14 @@ scene.on('loaded', () => {
}
})
.render();
/*scene.PointLayer({
zIndex: 2
})
.source(data)
.shape('2d:circle')
.size(2) // weight映射通道
.color('red')
.render();*/
});
});
</script>

View File

@ -36,8 +36,10 @@ export default class RenderPass {
}
render() {
this.renderer.setClearColor(this.clearColor, this.clearAlpha);
this.renderer.render(this.scene, this.camera, this.pass, true);
this.renderer.setRenderTarget(null);
this.renderer.setClearColor(this.originClearColor, this.originClearAlpha);
}
}

View File

@ -58,7 +58,7 @@ export default class HeatMapLayer extends Layer {
afterRender() {
if (this.shapeType !== 'grid' && this.shapeType !== 'hexagon') {
updateIntensityPass(this);
// updateIntensityPass(this);
}
}