We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
方型的polgon显示成了梯形
https://codesandbox.io/p/sandbox/l7-demo-forked-fntqmt?workspaceId=ws_SquWjKnX9ZtaqtASempSjf
import { Scene, LineLayer, RasterLayer, PolygonLayer } from "@antv/l7"; import { Map } from "@antv/l7-maps";
function initMap() { const scene = new Scene({ id: "map", map: new Map({ zoom: 10, minZoom: 5, maxZoom: 20, }), }); scene.on("loaded", () => { const layer0 = new RasterLayer(); layer0.source( "https://webrd0{1-3}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", { parser: { type: "rasterTile", tileSize: 256, minZoom: 2, maxZoom: 18, }, } ); scene.addLayer(layer0);
const mydata = { type: "FeatureCollection", features: [ { type: "Feature", id: "01", properties: { name: "Alabama", density: 94.65, }, geometry: { type: "Polygon", coordinates: [ [ [116.47835134, 40.00333684], [116.47835333, 40.00330714], [116.4783333, 40.00330639], [116.47833131, 40.0033359], [116.47835134, 40.00333684], ], ], }, }, ], }; const layer = new PolygonLayer({}) .source(mydata) .color("#2ca02c") .shape("fill") .size(1) .style({ opacity: 0.5, }) .active(true); const layer2 = new LineLayer({ zIndex: 2, }) .source(mydata) .color("#2ca02c") .active(true) .size(1) .style({ opacity: 1, // 设置线的透明度 }); scene.addLayer(layer); scene.addLayer(layer2); layer.fitBounds();
}); } initMap();
应该是方型
No response
The text was updated successfully, but these errors were encountered:
lvisei
No branches or pull requests
问题描述
方型的polgon显示成了梯形
重现链接
https://codesandbox.io/p/sandbox/l7-demo-forked-fntqmt?workspaceId=ws_SquWjKnX9ZtaqtASempSjf
重现步骤
import { Scene, LineLayer, RasterLayer, PolygonLayer } from "@antv/l7";
import { Map } from "@antv/l7-maps";
function initMap() {
const scene = new Scene({
id: "map",
map: new Map({
zoom: 10,
minZoom: 5,
maxZoom: 20,
}),
});
scene.on("loaded", () => {
const layer0 = new RasterLayer();
layer0.source(
"https://webrd0{1-3}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}",
{
parser: {
type: "rasterTile",
tileSize: 256,
minZoom: 2,
maxZoom: 18,
},
}
);
scene.addLayer(layer0);
});
}
initMap();
预期行为
应该是方型
平台
屏幕截图或视频(可选)
No response
补充说明(可选)
No response
The text was updated successfully, but these errors were encountered: