【解决办法】对需要拉伸的图层设置类型为 'type': 'fill-extrusion',再设置拉伸字段。参考代码:map.addLayer({
"id": "chengdu",
"source": "chengdu_3857",
"source-layer": "chengdu_3857@3d_demo_source",
'type': 'fill-extrusion',
"paint": {
'fill-extrusion-color': '#aaa',
'fill-extrusion-height': [
'interpolate',
['linear'],
['zoom'],
15,
0,
15.05,
['get', 'height']
],
'fill-extrusion-opacity': 0.6
}
});