[cgma-dev] Seg fault when loading OCC geometry with associations

Jed Brown jed at 59A2.org
Tue Mar 31 05:43:42 CDT 2009


On Mon 2009-03-30 16:43, Tim Tautges wrote:
> To re-iterate, iRel/Lasso currently isn't able to re-associate based on  
> the relations saved on tags on the mesh/geometry.  It's necessary to  
> create GEOM_DIMENSION sets in the mesh and assign appropriate mesh  
> entities to those sets.

I roughly understood this from before.  I had the appropriate sets, but
was not tagging them with GEOM_DIMENSION and GLOBAL_ID correctly.  My
confusion is that it related *something*.  I would much prefer that it
just doesn't find a relation than that it picks up the wrong relations.
Any guess, at least without expensive heuristics, is likely to be wrong.
The updated test case (attached) works correctly, which is enough for
me.  It would be convenient to have an iRel_extensions.h with a function
to encode a relation as permanent tags on the mesh?

> Eventually we do need the ability to save and restore the relations tag  
> directly, since this will save some time in cases where you're matching  
> multiple tags in the infer function.  This is a bit trickier than it  
> looks, since the EntityHandle tag type won't make sense across different  
> interfaces (i.e. the entity handle for a geom entity can't be saved to a  
> file from the mesh interface, since that's just a pointer to the  
> RefEntity in CGM, which won't come back the same way).

GLOBAL_ID on the geometry is currently immutable
(cf. CGMTagManager::setPresetTagData).  This means that in practice, a
relation is encoded using tags on the mesh.  With the current
convention, only one relation can be placed on the mesh.  A more
symmetric alternative is to set GLOBAL_ID on the entire mesh,
independent of any relation and separately save the relations (as mesh
GLOBAL_ID -> geom GLOBAL_ID or vice versa).  This could be a separate
file or lumped into the mesh file.

Jed
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cube.tar.gz
Type: application/octet-stream
Size: 5458 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/cgma-dev/attachments/20090331/23c39eb0/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/cgma-dev/attachments/20090331/23c39eb0/attachment-0001.pgp>


More information about the cgma-dev mailing list