I just want to draw rectangle for style.
if I do this
image: new ol.style.RegularShape({
fill: fill,
//stroke: stroke,
// offsetY: -25,
points: 4,
radius1: 30,
//radius2:20,
angle: Math.PI / 4
})
else if i do this
image: new ol.style.RegularShape({
fill: fill,
//stroke: stroke,
// offsetY: -25,
points: 4,
radius1: 30,
radius2:10,
angle: Math.PI / 4
})
How can I draw a rectangle?
Best Answer
The OpenLayers website has lots of examples that you may find helpful. This link goes into details on how to draw shapes. http://openlayers.org/en/latest/examples/draw-shapes.html?q=draw
Checkout more on the examples page.