[Gmsh] How to do Coherence; through the library API?
Takuya OSHIMA
oshima at eng.niigata-u.ac.jp
Mon Aug 22 03:33:01 CEST 2011
Hi,
I am using Gmsh 2.5.0 thgough the C++ API and am not able to figure
out how to do the equivalent operation of Coherence; directive of Gmsh
scripting language. Since It seemed to me that ReplaceAllDuplicates();
(the function that seemed to do the actual job of Coherence;) did not
update the corresponding GModel, I had to destroy the GModel once and
re-import the internal structure by
GModel *m = new GModel;
m->addVertex(...)
...
ReplaceAllDuplicates();
m->destroy();
m->importGEOInternals();
which is obviously not efficient and discards some internal
attributes. Besides I had to modify the Gmsh source as attached in
order to deal with embedded entities. Do I have to do this way, or am
I overlooking something?
Takuya
Takuya OSHIMA, Ph.D.
Faculty of Engineering, Niigata University
8050 Ikarashi-Ninocho, Nishi-ku, Niigata, 950-2181, JAPAN
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Fixed-corresponding-GEO_Internal-structure-not-updat.patch
Type: text/x-patch
Size: 2790 bytes
Desc: not available
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20110822/2b77739a/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-Fixed-broken-coherence-of-embedded-vertices-edges-wh.patch
Type: text/x-patch
Size: 1592 bytes
Desc: not available
URL: <http://www.geuz.org/pipermail/gmsh/attachments/20110822/2b77739a/attachment-0001.patch>