$dxf = new \DXFighter\DXFighter();
$shield = new \DXFighter\lib\Polyline();
$shield->setFlag(0,1);
//$list 为存储的东坐标、北坐标的数组
foreach($list as $k => $l)
{
$i=$k+1;
if($i<count($list)){
$line = new \DXFighter\lib\Line(array($l['east'],$l['north'],0),array($list[$i]['east'],$list[$i]['north'],0));
$line->setColor(50);
$dxf->addEntity($line);
$dxf->addEntity(new \DXFighter\lib\Text("PT".$i, array($l['east'],$l['north'],0), 0.5));
}else{
$dxf->addEntity(new \DXFighter\lib\Text("PT".$i, array($l['east'],$l['north'],0), 0.5));
}
}
输出的dxf 文件是为 多点之间连线 并在点处 标记PTn (例:PT1 PT2 )
需要DXFighter包 可以联系我QQ 357577995