X-Ray selection experiments build

You can get all the latest details inside the blenderartists thread. The idea is to keep things the way they are, while giving you more options for:

Edges and Faces

  1. Box, lasso, and circle will select random unseen edges and faces in near select (X-Ray off) because the viewport is drawing some of them erroneously, since some of their verts are visible. With my build you can filter this out based on the direction of mesh normals relative to the viewport. It works with a high degree of success and customization.
  2. Blender selects edges in a hybrid fashion with box and lasso. If the box or lasso contains at least one edge with both of its verts inside, you will only select edges that are like that. If you are touching some edges, but none of them have both of their verts inside, you will select any edge that is touched by the box or lasso. With circle you select any edge that is touched by the circle regardless of other factors. With my build you can also use these options to select edges:
  • Touch will select anything the selection area touches
  • Enclose will select edges that have both ends inside the selection area
  1. Blender selects faces in a hybrid fashion with box, lasso, and circle. If X-Ray is off, you select any faces you touch, and if X-Ray is on you select them by their center. With my build you can also use these options to select faces:
  • Touch will select anything the selection area touches
  • Enclose will select a face if all their verts are inside the selection area
  • Center will select a face if the selection area touches their center


  1. Box, circle, and lasso always select through objects in Object mode, and never select through mesh in Edit mode. With my build you can do either thing in both Object and Edit mode.
  2. Automatic X-Ray can turn X-Ray on for you in Object and/or Edit mode while using box, circle, and/or lasso
  • Both of the above are implemented modularly. There are many ways to setup your shortcuts so you can dynamically or permanently decide which tools and modes will use Select Through and/or Automatic X-Ray. There are some optional operators with header buttons that can be shown and hidden as you see fit. They will intelligently handle the modular aspect of either X-Ray feature for you in an on/off fashion for whichever tool and mode you are currently using. The icons for these operators were made by Alexey Adamitsky.
  1. Can turn off facedots in X-Ray shading

Drag Direction

  • Blender lets you choose up to 8 directions to move in when click-dragging. If all you want are 2 directions (left vs right or up vs down) they aren’t implemented very intuitively, take a lot more keymap items to set everything up, and they are innaccurate. With my build you can restrict the directions to either left vs right or up vs down. It makes sense, is easy to setup your keymap, and has accurate calculation of your drag direction. Dragging in the Any direction is unaffected.

Selection Radius

  • Verts, edges, and facedots (X-Ray on) have a large radius for single-clicking them. Faces (X-Ray off) have zero radius, the hotspot of the mouse cursor needs to be on top of the face. With my build you can use a consistent selection radius for everything, and adjust how large the selection radius is.

Mouse Cursor

  • Now you can choose which mouse cursor to use in different tools and modes. I included some new ones as well.

Header Highlights

  • The top of the active window or panel gets brighter. This can be adjusted or disabled.

Header Buttons

  • Can combine the X-Ray and Shading buttons into one thing. Same X-Ray button, just changes icons to reflect what shading mode you’re in. You aren’t losing the shading buttons either, they are just moved inside the shading popover. Assuming you don’t click on the shading buttons to switch shading modes, this makes a lot of sense.

Camera Zoom

  • Can adjust how fast the camera zooms, as many different mappings as your keymap can handle.

Frame Selected

  • Can give an offset for the viewport camera when using Frame Selected

Repeat Last

  • A new operator called Invoke Last that will invoke the previous operation instead of executing everything exactly the same.


  • This build is only possible because of the knowledge and experience shared by the community. I want to mention some people that helped me figure things out like Chris Blackbourne, LazyDodo, Harley and Campbell. Everyone on devtalk and in the chat, thank you. Most of all, I want to thank kio. Select Through, Facedot visibility, and Touch select faces in X-Ray are from the work he did. Some of it is basically untouched, and I learned a lot by updating it and changing how it works.

Looks interesting.

Not sure about Show/Hide functionality and prefix, usually it is Show/Show Hide/Hide functionality with no prefix, when highlighing means “show”.

Do you have linux builds?

It is general problem of an industry standards implementation - it wasn’t run by people fluent in industry standard software solutions with experience of moving from ISS to Blender, only by people who are a bit familiar with them.
As a result blender has got an imitation of ISS even without solving famous ISS issues, like avoiding cycling between selection modes you mentioned there, and at the cost of heavy unnecessary damage.
(the same thing happens when linux tries to imitate windows interface without understanding the ideas behind it)

For example, the display of facedots in solid mode was broken and remained useless for a year.
As a result of such kind of damage of different functionality our company was completely bulldozered from blender.

I appreciate you looking into issues before offering solutions.

That’s funny, the two buttons do the same thing and are right next to each other, but I didn’t think about how they work opposite from each other. I was looking at it from what is in normal blender, and trying to be more specific about what is different in this build so it was more clear what would happen. But that makes no sense, setting on should = button visible and just say what button it affects.

Just a windows build but the DIFF should work the same if you want to make one. The link has the diff itself with the icon, alt cursor, and a readme. Doing a make icons might be different in linux if there’s no inkscape for linux, but if that’s the case it should be really similar. That or just change the diff a little to use a different icon. There’s like 1 or 2 things keeping me in windows for now, but that may easilly change.

We were close to an acceptable solution but unfortunately it once again turned into a button adding competition :frowning:

There’s two different things being done here by me. This custom build is not intended for real blender. This more complex build is for me, and anyone who wants to use it. The other one, that is simpler, is what we are waiting for some further response on. I just explained how and why I did what I did when I sent that diff off for review. Go read my posts from 10 or 11 days ago if you really didn’t know or just forgot.

Feel free to ask around for more input from the devs if you want, but I think we’re meant to wait for people to have less important things to do and get back to us. I wouldn’t exactly hold my breath though, it is something that was already rejected for what I would call philosophical reasons. Which is understandable, and not a big deal. Otherwise I guess you could discuss, or implement, what could be done to align the concepts of select through with how real blender does things.

Or just use this select through (and other stuff) build, and see what weird or wrong stuff you can find with it.

Tested win version (on my work).
I would like to provide some feedback in case if it is interesting.

  1. Facedots displayed in wire/xray when they are off, but solid mode facedots are on.

So it is not “xray facedots” checkbox, what can be recognized as “display xray facedots”.
It better be named as “select faces by area” checkbox with inverted functionality, since it control only selection type, with no visual impact.

  1. “select faces by area” checkbox should be represented in select through custom setup as well, so you can control selection style by switching SThrough button, the same way it works with with “safety edges” which enforces “All edges” checkbox.

  1. In tweak mode AutoXray and Sthrough buttons are unaccessible, but functionality works if they was turned on in other mode.
  2. Autoxray jammes if selection border has no area.

Hope it was interesting. What do you think about that?


Always interested in feedback and bugs, thanks

  1. X-Ray facedots is named that way to make it shorter but it’s shortness is outweighed by being confusing. Not sure what to do about it but I had a couple different ideas.

At the moment I put it under the “Drag Select” heading to imply that it means “drag select by xray facedots” and gave it a tooltip. But it has the issue where it is easilly mistaken for toggling facedot visibility.

One solution is like you say, just call it “select face area” or similar. Now that there is also an “enclosed faces” option there’s a problem with this being two checkboxes and one has to have priority over the other. Already have this problem with “xray facedots” having priority over “enclosed face”, but at least it is sortof isolated in a specific context of needing to be in xray with facedots visible. A “face area” and “enclosed face” checkbox both existing and being on is a little worse since they both work in either mode regardless of facedot visibility.

To fix that I thought I’d make an operator for each one that will just toggle the other one off when needed, but I can’t put an operator in tool settings. It formats it all weird by putting the operator in that left side area where the headings are, and in the toolsettings panel (not the viewport one) it isn’t even clickable.

So I am thinking I will have a look at some of the other properties like the viewport shading buttons (wire solid material render) and emulating how that works. I could also expand this into some further properties. Have a “solid face” and “xray face” text label that looks like the “tool synchronization” label but with a gear next to it. If you click on the gear it expands and you can choose between area/enclosed in solid, and area/enclosed/facedot in xray.

  1. The feedback I got from having the ability to select through by facedot was negative, but I don’t see any reason not to have the option. It makes it more clear what will happen as well.

  2. Besides hiding header buttons I didn’t see any other functionality that would occur outside of box/lasso/circle select. So I put the button visibility stuff inside the viewport->view menu beneath “alternate header”. Is there anything you’ve noticed as far as autoxray, select through, enclosed faces, xray facedot select, or all edges select with tweak?

  3. Fixed this. Finally did it right by having autoxray happen only in gesture_ops instead of also inside view3d_select. This led me to actually checking that additional exit case where the seleciton box isn’t valid. Also cleaned it up by sending a handful of copy-pasted stuff that was spread out among box/lasso/circle into one thing

  1. I am not sure that enclosed faces require attention at this step, since implementing directional selection differentiation mechanics can fix this problem in a better way.
    At the moment it looks like an attempt to add manual selection differentiation mechanics, but in not centralized (dissolved across build) way.

  2. In my opinion adding such an option to select through controls will help to customize select through behaviour in a more flexible way. Select through is usually used with area selection (because occlude geometry covers facedots), while non-select through with manual/auto xray switching mechanics provide facedots acessibility and can be used with facedots selection. I think it is logical to have the ability to force area selection for select through mode.

  3. I think that AX and ST buttons should be active and work in tweak mode the same way they are active in other modes, because you have access to box circle and lasso selections in that mode via hotkeys.
    (Btw, the point of using hotkeys is immediate access, which allow you to quickly alternate them carving complex selections without selection modes switching or cycling - in BCBBC way, where LMB is for selecting and MMB is for deselecting. Such a mechanics also allow to not interrupt your attention from a model)
    This way, I dont see any differentiations between tweak mode and other (box circle lasso) modes that are needed to be hardcoded.

  4. Okay) By the way, I forgot to test that python copypasted stuff, maybe next time.

Thank you for attention.

  1. I am interested in directional control but for now I prefer a property toggle. Even if the (anti)clockwise thing gets figured out by somebody, I’d want a toggle as an option to avoid needing to draw my selection areas a certain way. Enclosed face is the only thing that is fully functional besides. Facedots not available in near select, and face area breaks in through/xray when doing intersect selection mode, with enclosed face being done as a fallback.

  2. It works this way already, where select facedots only cares about 3 things: Are you in xray? Are facedots visible in xray? Is xray facedots toolsetting enabled? AX as implemented will satisfy the being in xray, just for clarity’s sake. But yeah, I will just add the ability to do facedot select in ST mode. It might be useful for some reason but I don’t forsee what right now. It would be the same as safety edge where you could “turn the safety off” so to speak and do something that isn’t exactly expected, but potentially wanted for some reason.

  3. I did it this way to show what isn’t available in circle and also tidy things up in the toolsettings when these options aren’t applicable. Didn’t think about the direct keymap stuff, so I’ll probably just add tweak to the list of things it shows up for. I will say that calling BLC directly isn’t fully realized (header buttons won’t reliably reflect the ST or AX status if they are checking a non-select or non-select-fallback tool that is calling them) but supported because it will work fine despite potentially inaccurate header feedback.

  4. I was just talking about how autoxray is implemented. Gesture_ops calls xray to turn it on/off as needed but it isn’t just a single line you have to set up pointers and other stuff like this:

wmOperatorType *ot = WM_operatortype_find("VIEW3D_OT_toggle_xray", true);
PointerRNA ptr;
WM_operator_properties_create_ptr(&ptr, ot);
WM_operator_name_call_ptr(C, ot, WM_OP_INVOKE_DEFAULT, &ptr, NULL);

So having that copy-pasted 6 times wasn’t the right way to do it, but going back and checking stuff got me to do it better.

As far as python, the gizmo tweak stuff seems alright. Box-lasso toggle I made works ok for what I want it for which is just edit mode. Works fine for uv edit as well, just don’t assign to something like image editor where it will warn you that it doesn’t know what a box or lasso select is. Might work on a filter to eliminate that.

  1. I will just add the ability to do facedot select in ST mode

Hm, wait, thats weird…
From my experience during testing build, ST does not force face area selection, and respects “X ray facedots” checkbox, so there is already the ability to do facedot selection in ST mode if this checkbox is on. Isnt it?
Or am I missing someting?

  1. I will try to explain the issue without making it even more confusing.
    In short, there is no way to
  • make ST mode always use area selection in both Xray and Solid modes, according to classic ST behaviour
  • and make noST mode use facedots selection in Xray, and area selection in Solid, according to Blender defaults behaviour

so switching ST button you always have to switch Xray facedot checkbox as well to achieve such a differentiation, in case if user want to keep Blender default behaviour extended by classic ST mechanics.

If there will be ability to force face area selection for ST (simultaneously, both in Xray and Solid modes), such a differentiation can be achieved, and it will be possible to switch between (and indicate) those modes via single button.
Hope it sounds more clear.

I get what you are saying, and it works that way already, it’s just a little unclear what select through means. ST only happens if you are not in xray to begin with, and that’s the way it has always been. I get the confusion, based on how the 3.1 build had xray “modes” to designate which of the 3 things (default xray, auto xray, or select through header button/keymap) would make use of the space where the default xray header button is. Now in 3.2 the header situation is similar, but different. You can get the same ability to hide buttons you don’t need, but it isn’t all or nothing. It is however you want it where you could have 1, 2, or all 3 of the xray, AX, and ST buttons up there.

If you want ST to use face area all you need to do is not turn on “enclosed face”.
If you want nonST to use facedots you just have keep xray facedots visible, go into xray shading, and leave “xray facedots” enabled.
This is also the default behaviour.

I am going to alter this slightly though in an update that I will put up in about a week. Going give things a little more time to be discovered and posted here if there’s anything else people find.

It will be more of a clear and absolute choice which mesh elements will be used, instead of having to understand that enclosed faces only happen in xray if “xray facedots” is off. Also I just thought about it, I am going to get rid of the “safe edge/face” idea and just give ST its own mesh element section

Aw, so it is supposed that ST influence only Solid mode? That explains a lot.
So it looks like I am missing Xray mode support for ST then, to obtain complete classic ST mechanics…
(In software where ST mechanics is presented, it influence both solid and wire/xray modes, allowing selecting faces in both modes by area)

No, it is just something that is still being confused. Fixing that right now. Kio’s build made it where you had to have ST on to get face area select in x-ray. I have removed this requirement since very early on, if not right away. Same goes for x-ray facedot visibility, if ST was on, xray facedots would disappear. I made both of those things “decoupled” from ST.

You can select by face area in x-ray however you wish. AX, ST, both, or neither. That is why that tool setting “x-ray facedots” exists. Turn it off, you get face area select unless “enclosed faces” is on. That is the only thing that influences face selection other than ST forcing non-facedots when in solid shading, or xray facedots not being visible, or simply not being in xray.

Right now it is not obvious without reading the tooltips, but here is how it works:
If Select X-ray facedots ON, X-ray Facedots VISIBLE, Xray Shading ON - only way to get facedot selection

Then, reagardless of near/through select it checks if “enclosed face” is on, and will do either face area or fully enclosed faces. The one exception to this is face area is broken in through/xray if doing intersect selection and the workaround for making it at least do something requires a swap in/out of edges mode, which means the end result will only be fully enclosed faces.

Going to make this much more clear though, almost done and will show a screenshot later or tomorrow.


Thanks for making a build for 3.2, now I can use it for my daily work.

Also I found a bug - using auto x-ray on a curve objects turns on x-ray shading permanently instead of just while making a selection.

Should have this fixed now, checking it out led to finding this bug
It isn’t something that would be noticed unless you are in a debug build, but pretty neat.

Preview build for 3.21. Its a Lite build of RC, will upload the real thing once release probably. I’d appreciate one more check over things if anybody wants to do it.
[PREVIEW BUILD] 321RC Lite Sthru

Autoxray issues should be cleared up, and changed the way mesh element options are presented. Not as straightforward as 3 checkboxes, but it shouldn’t require as much guessing to figure out what to expect.

Planning on putting these options in a popover next to the vert/edge/face button. I had it all finished and setup inside of toolsettings but theres an issue with that for reasons I don’t understand. The viewport TS works fine, but the side panel one doesn’t work. You can make it show up in there fine, but it has no affect on selection. It has to be defined somewhat differently in python to show up, which may have something to do with it. Either way it isn’t there, but I left it in the viewport TS panel just to show what it could work like. Not much difference whether it is in TS or the popover next to the VEF buttons, so feel free to convince me to keep it in the viewport TS. Being in viewport means there’s no rightclick->reset to default, because for whatever reason that isn’t possible.

So, how does it work? It can be as simple as this:

Or as complex as this:

Near Face will change how near faces are selected by box and lasso. Meaning not in X-Ray, and not Select Through, that’s it. This also means circle will never use this because it only has options for “center” or “touch”

“Touch” means the same thing as what has been reffered to as “area” but I changed the wording so it is the same for face and edge (edges are 1-dimensional and don’t have area). It’s also about as simple as it could be described, touch face or edge with the selection area, and it will select the face or edge. Face “area” is less intuitive.

Enclose means you only select faces that are fully inside the selection area.

X-Ray face is the same as near, but for X-Ray shading. It has a “Center” option, which means select any faces whose center is inside the selection area. It does not care if facedots are visible or not. This goes the same for Select Through. I decided to leave it in your hands what the selection will do. If you want to select by invisible facedots, go for it. If you want to have facedot visibility act as your selection toggle, you can set up a python maco to keep them synced up. Shouldn’t be an issue for you guys though, I don’t think anybody who wants to turn facedots off will want to be selecting by them in any context.

Edge works for edges at all times, with and without X-Ray. “Enclose” is the default way blender does it, meaning adaptive, where it will give you only enclosed edges, or if you don’t fully enclose any edges it will give you any edges you touch with the selection area. “Touch” will give you any edges you touch with the selection area.

By default, “Select Through Filter” will be on. This means you can set a separate filter for select through while maintaining X-Ray Face/Edge. If you turn this off, it will just use X-Ray Face and Edge.

“Circle” and “Circle Select Through FIlter” are both off by default, but are there if you want them. It is like the select through filter but for circle. You can have one or both of them, they are separate things. Circle select options are very limited, face only, and you can select by either Touch or Center in X-Ray and/or Select Through. Otherwise it will use either X-Ray (Enclose will fallback to Touch) or Select Through (Enclose will fallback to Touch) depending on what is applicable.

If you are in X-Ray shading, and have Select Through on, both the filter and have it on (header button is lit up) you will get the Select Through filter behaviour despite select through not actually happening (xray is on there’s nothing in the way to select through anymore).

That is a lot of explanation for something that is meant to be simple to understand, but I wanted to make it as simple or complex as is reasonable. All of that while also maintaining default behaviour of both vanilla blender and select through as it was originally designed. Otherwise you’d be forced to use something more complex than you want, maybe you don’t care if select through or circle has it’s own filter. Or you’d have to deal with whatever decision I make for you regarding what I think you might want, maybe you want circle to use face center and box/lasso to use enclosed faces.


It’s amazing to see everyone in this thread trying hard to solve that issue, everyone that spends his/her free time on improving Blender should be applauded!

But to me, this looks like a nightmare, sorry.
This looks like the most complex solution to a pretty simple problem and would require way too much effort for users to figure out.


Lord have mercy… maybe this is the best way, but it certainly frightens me a bit ! I’d rather have a single way of dealing with this stuff, hardcoded but thought-through all the way, as uncomplicated as it is right now in vanilla, only better


@ManuelGrad @Hadriscus What do you have in mind/ how would you change it? If it’s so simple, then you should be able to make a suggestion ey. :smiley:

But, I think it’s not that difficult. If you want more options, you would have to enable them manually anyways and you’d know what you are looking for. Otherwise, they’d be the same as the short options menu. Most people would leave these at their defaults anyways.


Are these stored in preferences ? I wonder if that’s not source of problems for pipeline (sharing of blend files in the same department) if these are defined in the scene. They should be user-level preferences, not tool settings, right ?

1 Like