Illustrate using ray casting with multiple viewports


When using overlapping viewports with different layer filters,
the picking code has no idea about those filters and which
objects are selected for rendering. This means objects which
are rendered in one view port can be picked in another viewport
even though they are not visible.

To work around this, we use one ScreenRayCaster per viewport and
make sure it can only pick the objects selected by the same
layer as that viewport.

Change-Id: Iedca97f7649b2637cdad6c64e0e9dd94ba244667
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
commitce07b25223fa4066642138aaf149054b823940b8
parentedb127ffe239d7e6d6d6d8bffde588b3ab4837c5
authorMike Krus <mike.krus@kdab.com>
committerMike Krus <mike.krus@kdab.com>
commit timeWed, 3 Jun 2026 14:53:05 +0000