SGsortcollVLFLBB

by Tim C. Lueth, SG-Lib Toolbox: SolidGeometry 5.6 - Surfaces
Introduced first in SolidGeometry 4.9, Creation date: 2020-01-21, Last change: 2025-09-14

returns a collision index list of all SG in the SG cell list but considers the BB of VLFL

Description

In contrast to SGsortcollBB, which consideres only the Bounding Box of the Solids, this function checks in case of a potential collision also the Bounding Boxes of all Facets of two solids. I includes the code of
SGsortcollBB to save time. Next step would be SGintersectFacetPoints.

See Also: SGsortfitinBB , SGsortcollBB , SGsortisinsideBB , SGintersectFacetPoints

Example Illustration

 missing image of SGsortcollVLFLBB(BBL)

Syntax

[ELcoll,CIL,SG]=SGsortcollVLFLBB(BBL)

Input Parameter

BBL: Bounding Box List or Solid Geometry cell list with n entries

Output Parameter

ELcoll: Collision pair list | It is an undirected graph
CIL: logical collision index list, size n
SG: Solid Geometry list

Examples


A=SGbox; B=SGsphere(4); SGfigure; C={A,B}; SGsurfaces(C); SGsortcollVLFLBB(C)
BB=rounddiv(randminv(20,3,[1 10]),2) % Create 10 Bounding boxes
SGbox(BB,30,'randxy'); SG=ans % Create 10 Boxes in random distance
SGsortcollBB(SG) % Collision pair list
[a,b]=SGsortcollBB(SG)




Copyright 2020-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth

Last html export of this page out of FM database by TL: 2025-09-21