var bufferSource = new ol.source.Vector({
features: (new ol.format.GeoJSON()).readFeatures(serviceResult.result.resultGeometry)
});
var resultLayer = new ol.layer.Vector({
source: bufferSource,
style: new ol.style.Style({
stroke: new ol.style.Stroke({ //这个是图层边线,也可将color 设置 rgba颜色
color: 'blue',
width: 1
}),
fill: new ol.style.Fill({
color: 'rgba(255, 0, 0, 0.1)' //这个参数是可以进行调节透明度的 ,rgba a这个是透明度取值 0-1
})
})
});
map.addLayer(resultLayer);