applying texture to dxf file

applying texture to dxf file

Anonymous
Not applicable
1,766 Views
2 Replies
Message 1 of 3

applying texture to dxf file

Anonymous
Not applicable

Hi, I want applying a texture to a dxf file which actually is triangulation network of terrain, I have no idea how to implement this. any suggestions will be appreciated.

0 Likes
Accepted solutions (1)
1,767 Views
2 Replies
Replies (2)
Message 2 of 3

tbrammer
Advisor
Advisor
Accepted solution

Basically I would suggest to load the DXF into a new AcDbDatabase with AcDbDatabase::dxfIn().

Than iterate over the enties in the modelspace and use AcDbEntity::setMaterial() to assign an AcDbMaterial material with a texture to the entities you want. You can set the texture mapping with AcDbEntity::setMaterialMapper().

When you are done, save with AcDbDatabase::dxfOut().

Does this make sense to you?


Thomas Brammer ● Software Developer ● imos AGLinkedIn
If an answer solves your problem please [ACCEPT SOLUTION]. Otherwise explain why not.

0 Likes
Message 3 of 3

Anonymous
Not applicable

sorry for late reply, I got it. thanks.

0 Likes