This script/plugin does ray tracing through a rectangle "drawn" in the3d view window. The advantage it has over the older point edit based object selection scripts is that it doesn't start a pe mode to get the selection and it respects the locking of items.
The disadvantage is that the rectangle can't be seen while making the selection. To select small items in a large rectangle takes more rays which takes longer to perform. If there is not enough rays the small items can be missed.
http://clintons3d.com/plugins/truespace ... idget.html
requires the latest Clintons3dPlugin.rsx v.1638419
Widget based rectangle selection
- clintonman
- Captain
- Posts: 5422
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
- clintonman
- Captain
- Posts: 5422
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Widget based rectangle selection
Update: I realized I forgot to make the button unique. Made that change and updated the icon as well.
Re: Widget based rectangle selection
Been testing this again.
If I rectangle select as shown, the small cube does not get selected. But if I brush over the objects as shown, the small cube does get selected.
If I rectangle select as shown, the small cube does not get selected. But if I brush over the objects as shown, the small cube does get selected.
- clintonman
- Captain
- Posts: 5422
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Widget based rectangle selection
This is likely what is happening. The rectangle select sends out rays shown in blue and yellow for the 2 different selections. The small cube is not seen by the large selection because it is not under the ray in blue. The smaller selection ends on the small cube so it gets selected. The actual rectangle select sends out more than 5x5 but still things can be missed if they're small enough to fit in between the rays.
Re: Widget based rectangle selection
Thank you for the explanation
Suggestion:
Exchange the command to:
Add
Close Widget Command That way you can continue using the rectangle select widget until you RMB click in 3D Space
Suggestion:
Exchange the command to:
Code: Select all
//Widgets.ReplaceWidget('{5C9008D4-B6B3-4359-9E63-18D2FC228A6E}','/Widgets/Tools/Rect select widget','Default','','')
Widgets.ActivateViewToolWidget('/Widgets/Tools/Rect select widget','Default');
Close Widget Command That way you can continue using the rectangle select widget until you RMB click in 3D Space
Re: Widget based rectangle selection
LOL, I got your Invisible Rectangle Select Widget to work.
Well sort of.
Add your Rectangle Select Widget to the Rect zoom/Rect select node Edit: Almost perfect (Undo the Zoom) by adding two RsApp.Undo() lines to the data script
Comparing your Rectangle Select Widget with the Rectangle Zoom...
Your Rectangle Select Widget has an Enable check box that gets Checked/Unchecked in use.
The Rectangle Zoom has an Active checkbox that does not seem to get Checked/Unchecked in use.
Both are hooked up to the Render rect's Visible attribute
This may be why your Render rect does not work.
Well sort of.
Add your Rectangle Select Widget to the Rect zoom/Rect select node Edit: Almost perfect (Undo the Zoom) by adding two RsApp.Undo() lines to the data script
Code: Select all
RsApp.Undo()
RsApp.Undo()
//System.Trace(sel)
Space.Select(sel);
Your Rectangle Select Widget has an Enable check box that gets Checked/Unchecked in use.
The Rectangle Zoom has an Active checkbox that does not seem to get Checked/Unchecked in use.
Both are hooked up to the Render rect's Visible attribute
This may be why your Render rect does not work.
- clintonman
- Captain
- Posts: 5422
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Widget based rectangle selection
Update September 6 2021
Uses new visible rectangle and keep active behavior both supplied by trueBlue
new rsx plugin version 1638430 required
Rewritten to handle selections inside the plugin code and enable standard trueSpace Ctrl and Shift modifiers to add and subtract from the selection.
New frustum bounding box selection mode that works with small items that may be missed using the ray tracing method. Also enables the ability to select through to objects hidden behind other objects.
I have a note that 2D encapulated objects don't work with the ray tracing mode, but they do work with the new frustum mode of operation.
The bounding boxes of objects can be visualized using the Unofficial update cage widgets. The bounding box not the geometry is used for the frustum based selection.
Uses new visible rectangle and keep active behavior both supplied by trueBlue
new rsx plugin version 1638430 required
Rewritten to handle selections inside the plugin code and enable standard trueSpace Ctrl and Shift modifiers to add and subtract from the selection.
New frustum bounding box selection mode that works with small items that may be missed using the ray tracing method. Also enables the ability to select through to objects hidden behind other objects.
I have a note that 2D encapulated objects don't work with the ray tracing mode, but they do work with the new frustum mode of operation.
The bounding boxes of objects can be visualized using the Unofficial update cage widgets. The bounding box not the geometry is used for the frustum based selection.
- clintonman
- Captain
- Posts: 5422
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Widget based rectangle selection
Fixed a bug in the script caused by empty selection.
- clintonman
- Captain
- Posts: 5422
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Widget based rectangle selection
Sept 8
Fixed a bug causing all invisible items in the scene to become visible.
Fixed a bug causing all invisible items in the scene to become visible.