Javascript Openlayers 3.5未定义的坐标

Javascript Openlayers 3.5未定义的坐标,javascript,openlayers-3,Javascript,Openlayers 3,我试图得到OL3.5中圆图的坐标。我使用evt.coordinate函数来获取坐标,但是我一直没有定义。这是我的一段代码: this.boundingCircle = new ol.interaction.Draw({ condition: ol.events.condition.always, source: source, style: new ol.style.Style({ fill: new ol.style.Fill({ c

我试图得到OL3.5中圆图的坐标。我使用evt.coordinate函数来获取坐标,但是我一直没有定义。这是我的一段代码:

this.boundingCircle = new ol.interaction.Draw({
    condition: ol.events.condition.always,
    source: source,
    style: new ol.style.Style({
        fill: new ol.style.Fill({
          color: [50,50,255,0.5]
        }),
          stroke: new ol.style.Stroke({
              color: [0,0,255,1]
          })
      }),
    type: 'Circle'
  });
  this.boundingCircle.on('drawstart', function(evt) {
    var coord = evt.coordinate;
    alert("coord " + coord);
  });
我没有办法解释为什么我的coord变量有一个未定义的值。我尝试在我的DragBox“boxstart”函数中使用相同的变量,它工作得很好,这意味着我能够获得初始单击的坐标。任何帮助都将不胜感激。

您可以通过以下方式获得:

this.boundingCircle.on('drawstart', function(evt) {
    var geometry = evt.feature.getGeometry();
    var coord = geometry.getCoordinates();
    alert("coord " + coord);
});