## CoppeliaSim crashes when using the distance calculation module

Report crashes, strange behaviour, or apparent bugs
mthor13
Posts: 44
Joined: 03 Jul 2017, 08:32
Contact:

### CoppeliaSim crashes when using the distance calculation module

Dear CoppeliaSim,

First of all thanks for the new and fantastic update to CoppeliaSim!

I am, unfortunately, experiencing a problem with the new update whenever I try to use the distance calculation module.
After starting the simulation with an active distance object, it instantly crashes with the following error code:

Code: Select all

/home/mat/vrep_workers/VREP1/coppeliaSim: symbol lookup error: /home/mat/vrep_workers/VREP1/libsimExtGeometric.so: undefined symbol: _ZN10CCalcUtils36isApproxDistanceSmaller_box_tri_fastERK10C4X4MatrixRK8C3VectorS5_S5_S5_Rf
Do you know of any solution for this?

Best Regards,
Mathias Thor

fferri
Posts: 532
Joined: 09 Sep 2013, 19:28

### Re: CoppeliaSim crashes when using the distance calculation module

Does this happen with the scene scenes/minimumDistanceCalculationDemo.ttt?

mthor13
Posts: 44
Joined: 03 Jul 2017, 08:32
Contact:

### Re: CoppeliaSim crashes when using the distance calculation module

No, it does not happen with that scene.
But if I make a simple scene with only two primitives and create a distance object for them, then it crashes right away.

Like to scene: https://drive.google.com/file/d/17UdkzP ... sp=sharing

Addition: If I add a sphere primitive to the minimumDistanceCalculationDemo scene then it cashes whenever calculating the distance to the shape object (not when calculating to the dummy)

fferri
Posts: 532
Joined: 09 Sep 2013, 19:28

### Re: CoppeliaSim crashes when using the distance calculation module

mthor13 wrote:
12 Dec 2019, 14:11
Like to scene: https://drive.google.com/file/d/17UdkzP ... sp=sharing
Not crashing here (CoppeliaSim 4.0.0rev1 on macOS). But I don't have the vortex engine, so I changed that to Bullet 2.78. Does it make a difference?

mthor13
Posts: 44
Joined: 03 Jul 2017, 08:32
Contact:

### Re: CoppeliaSim crashes when using the distance calculation module

Hi fferri,

Thanks for checking - it also crashes on me with the bullet 2.78.

For the record, I am running:
- Ubuntu 18.04.3 LTS
- CoppeliaSim Edu V4.0.0. (rev. 1)

coppelia
Posts: 7691
Joined: 14 Dec 2012, 00:25

### Re: CoppeliaSim crashes when using the distance calculation module

Hello Mathias,

yes, I can confirm that there is a bug. We'll look into this asap.

Cheers

coppelia
Posts: 7691
Joined: 14 Dec 2012, 00:25

### Re: CoppeliaSim crashes when using the distance calculation module

Hello again,

the bug was corrected. You can either re-download the whole package, or only the incriminated library:
ubuntu16_04
ubuntu18_04

Cheers

mthor13
Posts: 44
Joined: 03 Jul 2017, 08:32
Contact:

### Re: CoppeliaSim crashes when using the distance calculation module

That was fast - thank you very much!

mthor13
Posts: 44
Joined: 03 Jul 2017, 08:32
Contact:

### Re: CoppeliaSim crashes when using the distance calculation module

Hello again Coppella,

I am once again experiencing problems with the distance calculation module. Your fix worked for a while - but now I get the following error message:

Code: Select all

Error: signal 11:

/home/mat/vrep_workers/VREP1/libcoppeliaSim.so(_Z11_segHandleri+0x2b)[0x7f17009bfeab]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ef20)[0x7f1704911f20]
/home/mat/vrep_workers/VREP1/libsimExtGeometric.so(_ZN10CCalcUtils11getDjb2HashEPKcm+0x10)[0x7f16d2937b50]
/home/mat/vrep_workers/VREP1/libsimExtGeometric.so(_ZN10CObbStructC2EPKfiPKiifi+0x1db)[0x7f16d2957d0b]
/home/mat/vrep_workers/VREP1/libsimExtGeometric.so(_Z15geom_createMeshPKfiPKiiPK8C7Vectorfi+0x1ce)[0x7f16d29366de]
/home/mat/vrep_workers/VREP1/libsimExtGeometric.so(geomPlugin_createMesh+0xbb)[0x7f16d28f1c5b]
/home/mat/vrep_workers/VREP1/libcoppeliaSim.so(_ZN16CPluginContainer21geomPlugin_createMeshEPKfiPKiiPK8C7Vectorfi+0x89)[0x7f1700bc7819]
/home/mat/vrep_workers/VREP1/libcoppeliaSim.so(_ZN10CGeomProxy38initializeCalculationStructureIfNeededEv+0x140)[0x7f17008bce90]
/home/mat/vrep_workers/VREP1/libcoppeliaSim.so(_ZN16CDistanceRoutine31_getShapeShapeDistanceIfSmallerEP6CShapeS1_RfPfPiS4_bb+0xc8)[0x7f17007f3358]
/home/mat/vrep_workers/VREP1/libcoppeliaSim.so(_ZN16CDistanceRoutine32_getObjectPairsDistanceIfSmallerERKSt6vectorIP9C3DObjectSaIS2_EERfPfPiS9_bb+0x127)[0x7f17007f64d7]
QObject::~QObject: Timers cannot be stopped from another thread
QMutex: destroying locked mutex

I recently redownloaded coppeliaSim and also updated some packages in my Linux system (but not something that would expect to crash the distance calculation module). Do you know what could cause this error?

coppelia