Cesium 可视化深度纹理
// 创建纹理辅助器图元const textureHelper = new TextureHelperPrimitive(viewer.scene)viewer.scene.primitives.add(textureHelper)viewer.scene.postRender.addEventListener(function () {const framebuffer = viewer.scene.view.pickDepths[0]?.framebuffer;if (framebuffer) {// 指定需要绘制的纹理textureHelper.drawTexture = framebuffer.getColorTexture(0)}});
效果:
在这里插入图片描述