几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   DirectDWG (http://www.dimcax.com/hust/forumdisplay.php?f=89)
-   -   【转帖】problem with rotated dimension (http://www.dimcax.com/hust/showthread.php?t=18165)

yang686526 2009-05-06 11:33 PM

【转帖】problem with rotated dimension
 
problem with rotated dimension
problem with rotated dimension
dear forum,
i added in the method dbfiller::adddimensions, in the odwriteex\dbfiller.cpp file, the following code :
oddbrotateddimensionptr dwgdim = oddbrotateddimension::createobject() ;
dwgdim->setrotation(1.5707963267949) ;
dwgdim->setdimlinepoint(odgepoint3d(58.,21.,0.)) ;
dwgdim->setxline1point(odgepoint3d(75.,21.,0.)) ;
dwgdim->setxline2point(odgepoint3d(99.,36.,0.)) ;
dwgdim->usesettextposition();
dwgdim->settextposition(odgepoint3d(56.0,30.,0.)) ;
pblock->appendoddbentity(dwgdim);
i attached the generated writen.dwg.
when i load it in autocad 2004, the text of this new rotated dimension is "5.8409" which is wrong.
when i move this text, its content immediately changes to the right value of 15.
could you please explain me this strange phenomenon ?
my dwgdirect version is 1.14.1.0
thank you.
attached files
the correct dimlinepoint is odgepoint3d(56.,36.,0.) for your dimension.
the dwgdirect (as acad) corrects wrong value but now the right dimension may be got by call dwgdim->recomputedimblock() twice. we try to fix this problem in future.
best regards,
sergey z.


所有的时间均为北京时间。 现在的时间是 02:04 AM.