![]() |
【转帖】extures
textures
textures hi to all, i am trying to find a functionality in the dwg library for assigning a texture to an object. i have explored the odavematerial class, but it is used only for materials. any ideas? thanks in advance hi, odavematerial class can keep an image as well. you can attach a material to object by odavematerial::attachtoobject() method. to define how material is mapped onto object (texture mapping) acad uses ave_entity_material xdata of object. at the moment dd does not provide separate interface for mapping xdata. as workaround you can use oddbobject::xdata()/setxdata() methods (with "ave_entity_material" as regapp name) to define mapping attributes. regards, sergey vishnevetsky quote: originally posted by sergey vishnevetsky hi, odavematerial class can keep an image as well. you can attach a material to object by odavematerial::attachtoobject() method. to define how material is mapped onto object (texture mapping) acad uses ave_entity_material xdata of object. at the moment dd does not provide separate interface for mapping xdata. as workaround you can use oddbobject::xdata()/setxdata() methods (with "ave_entity_material" as regapp name) to define mapping attributes. thank you for the reply. is there any documentation on what needs to go into the xdata i.e. how do i define/what is the syntax for the mapping attributes? i just need a simple planar mapping to stretch a texture over a surface. |
所有的时间均为北京时间。 现在的时间是 03:26 AM. |