Page 1 of 1

Selection bounding box extension

Posted: Fri Oct 26, 2018 8:11 pm
by claudiocordara
Ogre Version: 1.11.2 (Rhagorthua)
Operating System: Windows 10
Render System: Direct3D 9

Hello,

Here is my problem, I need to extend the bounding box of an entity (or of the node
that contains that entity) used by the RaySceneQuery procedure to implement the selection
of an object on the screen.
What I need is the possibility to select an object even if the click is not in its bounding
box but in prossimity of the bounding box (within a given tolerance).
I have searched many times for a possible solution to this problem even in this forum
without success.
Any suggestion will be much appreciated

Thank You
Claudio Cordara

Re: Selection bounding box extension

Posted: Sun Dec 09, 2018 2:46 pm
by saintnick
One solution might be to use a volume query instead. This could select a unit 'around' where you clicked.

http://wiki.ogre3d.org/Intermediate+Tut ... _Selection

Re: Selection bounding box extension

Posted: Mon Dec 10, 2018 7:29 pm
by saintnick
My previous post increases the area you select. After rereading your original post I realized you want to increase the area around your object that will select your object. You could create a square or rectangle object scaled to your needs and create a child scene node to your object. Then when your box is selected select the object it is a child of and ignore the box.