CONTENTS DELETED
The author has deleted this message.
|
I don't think there is an easy way to do that.
To efficiently detect identical entities: 1, implement hash code for all entities; 2, implement an equal() member function for all, to be used to handle hash collisions; sounds like an interesting small project.
|
Administrator
|
Sounds like a java solution :) I guess would also consider entities that are near identical? For example lines where start/end point's of each line are close to within a specific distance? Ries
|
Not really, because duplicated should mean exact copies generated by copying.
It's hard to define "similar" cleanly. say, you have tolerance of 0.5 (ridiculously large to show the idea), and the 1D points are: 0 0.25 0.5 0.75 1. 1.25 1.5 so, 0.25 is a duplicate of 0, and 0.5 is a duplicate of 0.25. it's hard to tell which ones to remove then.
|
Administrator
|
Dxli, I guess both methods would be helpfull in different situations... Ries
|
Hi
Thanks Dxli and Ries for your answers. Somehow I managed to delete my first post by mistake .... anyway AutoCAD and QCAD and most other CAD programs have this option to select and delete duplicate entities, so it is something which is very normal to have in a CAD tool set! It would be great if this could be added to LibreCAD also. TLW |
Free forum by Nabble | Edit this page |