高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】extracting properties of entities
extracting properties of entities
(**case closed**) extracting properties of entities
i have managed to get to and iterate through the list of entities in a block and i can print out their classnames and which layer they belong to. these are mostly acdbxxx entities (acdbline, acdbtext, etc) but when i searched in header files for those words i did not find anything. can someone help me how to read attributes (startpoint, endpoint, radius, thickness, color, etc.) of acdbxxx entities?
thanks
-----------
i was reading the names of the entities returned from pent->isa()->name() which returned strings like "acdbline" etc. and thought that the entity is actually an instance of acdbline c++ class. but the entity is actually an oddbline, etc. replacing ac with od does the job.
sorry for bothering.
- jaydutt shuklafff">
last edited by jaydutt; 18th january 2006 at 01:56 pmfff">. reason: found the solution
hi,
the analogues of acdbline is oddbline, acdbcircle is oddbcircle, etc.
in dwgdirect there are no acdb c++ classes.
i guess the isa()->name() function returns the name of the class as found in the dxf specification (acdb- prefix), in order to keep consistency with acad. in this case this is only a string description and not a c++ class.
so use the oddb classes and you'll get the results you need.
btw same with acge and odge, acgs and odgs, etc
hope this helps.
best regards
chudomir
|