renderTiffMap(tif) {
            if (this.tiffLayer) {
                this.map.removeLayer(this.tiffLayer);
                this.tiffLayer = null
            }
            plotty.addColorScale(
                "customScale",
                [
                    "#A6D533",
                    "#B5FF8F",
                    "#FFE033",
                    "#F35C6F",
                ],
                [0, 0.3, 0.6, 0.8,]
            );
            this.activeTiff.filename = tif;
            this.tiffLayer = this.$L
                .leafletGeotiff(`${this.$baseIP}gziamsp/file/` + this.activeTiff.filename, {
                    band: 0,
                    renderer: this.$L.LeafletGeotiff.plotty({
                        displayMin: 0,
                        displayMax: 10000,
                        colorScale: "customScale",
                        clampLow: false,
                        clampHigh: false,
                    }),
                })
                .addTo(this.map);
        },

 

posted on 2025-03-04 15:49  shihongbo  阅读(87)  评论(0)    收藏  举报