高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】some Fundamental Questions
some fundamental questions
some fundamental questions
hi
i have some very fundamental/naive questions:
1. why are functions like
oddbcircle::getendpoint(odgepoint3d& pt)
made virtual? there are no classes that derive these.
are the clients of the library expected to derive these classes?
2. what is the meaning of the function *dwginfields*.
the dwgdirect.chm help file says that it reads in the dwg data for this object. but for reading a dwg file, i just create the database pointer and then through the object ids i access various entities.
then why is this function required?
3. in the help file, what do the numbers in the brackets signify?
e.g alignment - gets the alignment value for this entity (dxf 72). what does dxf 72 signify here?
any help would be appreciated.
thanks
alex.
quote:
originally posted by alex30
1. why are functions like
oddbcircle::getendpoint(odgepoint3d& pt)
made virtual? there are no classes that derive these.
are the clients of the library expected to derive these classes?
2. what is the meaning of the function *dwginfields*.
the dwgdirect.chm help file says that it reads in the dwg data for this object. but for reading a dwg file, i just create the database pointer and then through the object ids i access various entities.
then why is this function required?
3. in the help file, what do the numbers in the brackets signify?
e.g alignment - gets the alignment value for this entity (dxf 72). what does dxf 72 signify here?
1. oddbcircle is oddbcurve inheritant. getendpoint is made virtual there, to be able to operate with oddbcircle just like with oddbcurve in common case.
2. when dwgdirect reads database from dwg, every object reads its own data using dwginfields. if you create your custom object, you probably need to override dwginfields\dwgoutfields, to be able store custom data.
3. dxf groupcode 72 (see autocad dxf reference)
sincerely yours,
george udov
|