Skip to main content

BIMViewer Marquee Selection Tool

· 2 min read

We have added a new marquee selection tool to xeokit's bundled BIMViewer application. This tool enables users to interactively select objects that intersect a rectangular region created by dragging the mouse.

If the rectangle is created by dragging from left to right, it will select objects that are fully contained within the rectangle. If the rectangle is created by dragging from right to left, it will select objects that are either fully inside the rectangle or just intersecting with it.

Internally, the marquee tool uses a kd-tree to find intersections with object boundaries. In practice, this works very efficiently, even with the largest models.

The screen capture below shows how to use this new tool. To activate it, click the Marquee button in the toolbar, then drag to select objects. Notice how the marquee outline is dashed when dragging right-to-left, to indicate that it will select any object that at least partially intersects it, and solid when dragging in the other direction, to indicate that it will only selects that lie fully inside it.

Run this example