Box selection, tool or B key, doesn't select more than 5K objects #102485

Closed
opened 2022-11-13 23:42:09 +01:00 by Sidney Moraes Jr · 25 comments

System Information
Operating system: Windows 10
Graphics card: GTX 970

Blender Version
Broken: 3.3.1

Short description of error
Hello. The box selection tool (W key) and the B key tool don't select more than 5k objects. If one of them is already a deselected active object, it will work for only 4999.
Some tests I did here:

  • I've got the same behavior for orthographic and perspective; I've tried to change the clip Start and End, and focal length and I still got the same results;
  • Doesn't matter the area, it is always the object number;

It is probably related to https://developer.blender.org/T102487

Exact steps for others to reproduce the error
Selection_+5K_objects_doesn't work.blend
With Object A active:

  • Selecting the 4999 objects + B giving a total of 5k objects will work;
  • Selecting the 4999 objects + B + C won't select;

With Object B Active:

  • Selecting the 4999 objects works;
  • Selecting the 4999 objects + B won't select;

Selection_5k_objects.webm

**System Information** Operating system: Windows 10 Graphics card: GTX 970 **Blender Version** Broken: 3.3.1 **Short description of error** Hello. The box selection tool (W key) and the B key tool don't select more than 5k objects. If one of them is already a deselected active object, it will work for only 4999. Some tests I did here: - I've got the same behavior for orthographic and perspective; I've tried to change the clip Start and End, and focal length and I still got the same results; - Doesn't matter the area, it is always the object number; It is probably related to https://developer.blender.org/T102487 **Exact steps for others to reproduce the error** [Selection_+5K_objects_doesn't work.blend](https://archive.blender.org/developer/F13905363/Selection__5K_objects_doesn_t_work.blend) With Object A active: - Selecting the 4999 objects + B giving a total of 5k objects will work; - Selecting the 4999 objects + B + C won't select; With Object B Active: - Selecting the 4999 objects works; - Selecting the 4999 objects + B won't select; [Selection_5k_objects.webm](https://archive.blender.org/developer/F13905422/Selection_5k_objects.webm)

Added subscriber: @SidneyMoraesJr

Added subscriber: @SidneyMoraesJr

#103309 was marked as duplicate of this issue

#103309 was marked as duplicate of this issue

blender/blender#102487 was marked as duplicate of this issue

blender/blender#102487 was marked as duplicate of this issue

Added subscriber: @mod_moder

Added subscriber: @mod_moder

I can confirm that selecting does indeed start to work in a very strange and unreliable way.

I can confirm that selecting does indeed start to work in a very strange and unreliable way.

Added subscriber: @deadpin

Added subscriber: @deadpin

Changed status from 'Needs Triage' to: 'Needs Developer To Reproduce'

Changed status from 'Needs Triage' to: 'Needs Developer To Reproduce'

The 2500 limit was introduced many years ago as part of blender/blender@50e9868abe

It's hardcoded right now. The particular usage of this value during selection is roughly 2 * MAXPICKELEMS as seen in:
https://developer.blender.org/diffusion/B/browse/master/source/blender/editors/space_view3d/view3d_select.cc$3740

/**
 * The default value for the maximum number of elements that can be selected at once
 * using view-port selection.
 *
 * \note in many cases this defines the size of fixed-size stack buffers,
 * so take care increasing this value.
 */
#define MAXPICKELEMS 2500
The 2500 limit was introduced many years ago as part of blender/blender@50e9868abe It's hardcoded right now. The particular usage of this value during selection is roughly 2 * MAXPICKELEMS as seen in: https://developer.blender.org/diffusion/B/browse/master/source/blender/editors/space_view3d/view3d_select.cc$3740 ``` /** * The default value for the maximum number of elements that can be selected at once * using view-port selection. * * \note in many cases this defines the size of fixed-size stack buffers, * so take care increasing this value. */ #define MAXPICKELEMS 2500 ```

Added subscriber: @TestPilot02

Added subscriber: @TestPilot02
Member

Added subscriber: @Jeroen-Bakker

Added subscriber: @Jeroen-Bakker
Member

This is a limitation of GL depth picking. If you want to be able to select, select a different method in your user preferences.

image.png

I expected a better description of this limitation as this case isn't described well.

https://docs.blender.org/manual/en/latest/troubleshooting/3d_view.html?highlight=gpu+depth+picking#slow-selection
https://docs.blender.org/manual/en/latest/editors/preferences/viewport.html#selection

This is a limitation of GL depth picking. If you want to be able to select, select a different method in your user preferences. ![image.png](https://archive.blender.org/developer/F14068862/image.png) I expected a better description of this limitation as this case isn't described well. https://docs.blender.org/manual/en/latest/troubleshooting/3d_view.html?highlight=gpu+depth+picking#slow-selection https://docs.blender.org/manual/en/latest/editors/preferences/viewport.html#selection
Member

Changed status from 'Needs Developer To Reproduce' to: 'Confirmed'

Changed status from 'Needs Developer To Reproduce' to: 'Confirmed'
Member

Solution is changing the manual to update the limitations and possible work-arounds to the manual. Perhaps the text in the error message could be adjusted afterwards to be more user-oriented.

Solution is changing the manual to update the limitations and possible work-arounds to the manual. Perhaps the text in the error message could be adjusted afterwards to be more user-oriented.
Member

Added subscriber: @Blendify

Added subscriber: @Blendify
Member

The issue does not go away when disabling "GPU Depth Selection" and by the commit @deadpin posted also shows that it is unrelated. AFAIK there are no limitations in this case. Perhaps the limitation can be fixed, or at least increased from the prior limit? I have not looked at the code deeply but why is this only a limitation for object selection? edit mode selection works fine.

The issue does not go away when disabling "GPU Depth Selection" and by the commit @deadpin posted also shows that it is unrelated. AFAIK there are no limitations in this case. Perhaps the limitation can be fixed, or at least increased from the prior limit? I have not looked at the code deeply but why is this only a limitation for object selection? edit mode selection works fine.

Added subscriber: @Renderbicks

Added subscriber: @Renderbicks

Lasso Select works as intended with an unlimited number.

Lasso Select works as intended with an unlimited number.

In #102485#1462889, @Jeroen-Bakker wrote:
This is a limitation of GL depth picking. If you want to be able to select, select a different method in your user preferences.

image.png

I expected a better description of this limitation as this case isn't described well.

https://docs.blender.org/manual/en/latest/troubleshooting/3d_view.html?highlight=gpu+depth+picking#slow-selection
https://docs.blender.org/manual/en/latest/editors/preferences/viewport.html#selection

What is the technical difference between Lasso and Box select? Lasso Select seems to work with an unlimited number of models.

> In #102485#1462889, @Jeroen-Bakker wrote: > This is a limitation of GL depth picking. If you want to be able to select, select a different method in your user preferences. > > ![image.png](https://archive.blender.org/developer/F14068862/image.png) > > I expected a better description of this limitation as this case isn't described well. > > https://docs.blender.org/manual/en/latest/troubleshooting/3d_view.html?highlight=gpu+depth+picking#slow-selection > https://docs.blender.org/manual/en/latest/editors/preferences/viewport.html#selection What is the technical difference between Lasso and Box select? Lasso Select seems to work with an unlimited number of models.

Added subscriber: @SteffenD

Added subscriber: @SteffenD
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

@Jeroen-Bakker : can you comment on the MAXPICKELEMS thingie?

@Jeroen-Bakker : can you comment on the `MAXPICKELEMS` thingie?

Added subscriber: @filippo_f

Added subscriber: @filippo_f

I've been testing different values for MAXPICKELEMS and it does work fine for the range I've tried (2500-50000, my hardware won't handle more objects at once).

50000.PNG

I can't find any documentation about OpenGL depth picking limitations.

Looking at blender/blender#43785 diff buffer size has been changed from 40000 to 10000.

By providing max 50000 MAXPICKELEMS I get a buffer size of 200000 and it's still working.

At this point might this problem be related to a specific os? I see that the author of the issue was using Ubuntu.

I've been testing different values for MAXPICKELEMS and it does work fine for the range I've tried (2500-50000, my hardware won't handle more objects at once). ![50000.PNG](https://archive.blender.org/developer/F14206259/50000.PNG) I can't find any documentation about OpenGL depth picking limitations. Looking at [blender/blender#43785 diff ](https://developer.blender.org/rB50e9868abe11bd2ed0173b7a51cf129d77e4389e) buffer size has been changed from 40000 to 10000. By providing max 50000 MAXPICKELEMS I get a buffer size of 200000 and it's still working. At this point might this problem be related to a specific os? I see that the author of the issue was using Ubuntu.

In #102485#1480793, @filippo_f wrote:
I've been testing different values for MAXPICKELEMS and it does work fine for the range I've tried (2500-50000, my hardware won't handle more objects at once).

50000.PNG

I can't find any documentation about OpenGL depth picking limitations.

Looking at blender/blender#43785 diff buffer size has been changed from 40000 to 10000.

By providing max 50000 MAXPICKELEMS I get a buffer size of 200000 and it's still working.

At this point might this problem be related to a specific os? I see that the author of the issue was using Ubuntu.

I am using right now an addon by Yain Rodrigo Vieyra from Argentina. This saves actually my project but doesn't solve the corrupted data management when exceeding 65K objects in a Blender file.

I asked him to sign up and join the conversation.

> In #102485#1480793, @filippo_f wrote: > I've been testing different values for MAXPICKELEMS and it does work fine for the range I've tried (2500-50000, my hardware won't handle more objects at once). > > ![50000.PNG](https://archive.blender.org/developer/F14206259/50000.PNG) > > I can't find any documentation about OpenGL depth picking limitations. > > Looking at [blender/blender#43785 diff ](https://developer.blender.org/rB50e9868abe11bd2ed0173b7a51cf129d77e4389e) buffer size has been changed from 40000 to 10000. > > By providing max 50000 MAXPICKELEMS I get a buffer size of 200000 and it's still working. > > At this point might this problem be related to a specific os? I see that the author of the issue was using Ubuntu. I am using right now an addon by Yain Rodrigo Vieyra from Argentina. This saves actually my project but doesn't solve the corrupted data management when exceeding 65K objects in a Blender file. I asked him to sign up and join the conversation.
Aaron Carlisle removed the
Meta
Good First Issue
Module
Eevee & Viewport
labels 2023-02-08 04:15:12 +01:00
Aaron Carlisle added the
Module
Eevee & Viewport
label 2023-08-13 15:15:50 +02:00

This scenario should now work in recent 4.1 alpha builds (fixed by abf59eb23a)

This scenario should now work in recent 4.1 alpha builds (fixed by https://projects.blender.org/blender/blender/commit/abf59eb23ab645d5209adec634d0133110e53987)
Blender Bot added
Status
Archived
and removed
Status
Confirmed
labels 2023-12-02 05:23:53 +01:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
10 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-manual#102485
No description provided.