查看单个帖子
旧 2009-04-16, 05:21 PM   #1
yang686526
高级会员
 
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
yang686526 向着好的方向发展
默认 【转帖】[求助]请教acdbcurve::getpointatdist执行失败原因

[求助]请教acdbcurve::getpointatdist执行失败原因
[求助]请教acdbcurve::getpointatdist执行失败原因
我在代码里面使用下面语句:
acad::errorstatus espoly = acad::eok ;
espoly = m_ppolyline->getpointatdist( dlength, ptpos ) ; //m_ppolyline为acdb2dpolyline类型
执行后espoly的值是-858993460,但是如果我在执行getpointatdist前加上下面一句:
espoly = m_ppolyline->getfirstderiv( ptpos, vtzdir ) ;
则getpointatdist执行又是成功的,espoly值为acad::eok,请问这是什么原因?
另外,
double dlength = 0.0 ;
acgepoint3d ptend ;
m_ppolyline->getendpoint( ptend ) ;
m_ppolyline->getdistatpoint( ptend, dlength ) ;
acgepoint3d pt ;
acad::errorstatus espoly = m_ppolyline->getpointatdist( ptend, dlength ) ;
这里espoly 为什么返回的是acad::einvalidinput?是不是因为精度原因?
yang686526离线中   回复时引用此帖
GDT自动化论坛(仅游客可见)