UI: Automatic X-Ray #109318

Open
Lukas Sneyd wants to merge 20 commits from lcas/blender:automatic-xray into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
First-time contributor

Optional Automatic X-Ray feature turns on while selecting.


Convenience extension for xray. You can use box, circle, and lasso to select through mesh without manually turning on xray. When you start to select with one of these tools, it turns on xray. Once the selection is completed, xray will turn off again.

I put the controls for auto xray in a new popover next to the xray header button. Now that xray has its own popover, the xray settings are in there instead of the Shading popover. I also decided that since solid and wireframe have separate xray properties, it should be more obvious. I extended their names to "X-Ray Solid" and "X-Ray Wireframe" inside of the xray popover.

image

I was asked whether this feature had any relevance to object mode, so I made it work in both edit and object mode. It doesn't do much in object mode since blender always selects through objects, but maybe it's desired for visual purposes. No reason to make people who only want auto xray in edit mode, but not object mode, to have to turn auto xray on and off all the time. So you can decide which modes use it inside the popover. The same idea applies to the box, circle, and lasso tools themselves. It's better if you can decide which tools use auto xray. That way you don't have turn it on and off when you switch between tools, assuming you want it on for one of them, and off for the others.

The following covers some optional features that I either excluded, or separated, from this PR. You can see more details about it in my custom build #109150 and at 2:38 of this youtube video. I didn't want to combine 2 features into a single PR, so I kept select through #109319 separate from auto xray. But it makes sense to have both. They don't conflict, and can even complement each other.

My build includes an operator to have a more direct and intuitive control over this modular style of using auto xray. Having a header button also makes it more clear when auto xray is enabled. It seemed less likely to be approved if I am adding header buttons, so I didn't do any of that for this PR. The operator checks what tool and mode you're in. If everything is enabled, meaning the main bool and whichever tool and mode is currently in use, the operator will disable the main bool to turn the feature off. Otherwise, it will turn on any of the bools (main, tool, mode) that aren't enabled. An on/off switch that doesn't compromise individual control and gives visual feedback in the header.

To reduce unwanted clutter in the viewport header, I made it where the header buttons for xray, auto xray, and select through are hideable. It is controlled from inside the xray popover. If all of the header buttons are disabled, the xray button will still be visible. Otherwise, any combination of the three buttons are visible in the header.

Optional Automatic X-Ray feature turns on while selecting. --- Convenience extension for xray. You can use box, circle, and lasso to select through mesh without manually turning on xray. When you start to select with one of these tools, it turns on xray. Once the selection is completed, xray will turn off again. I put the controls for auto xray in a new popover next to the xray header button. Now that xray has its own popover, the xray settings are in there instead of the Shading popover. I also decided that since solid and wireframe have separate xray properties, it should be more obvious. I extended their names to "X-Ray Solid" and "X-Ray Wireframe" inside of the xray popover. ![image](/attachments/09aa4669-78d7-4898-8b3d-d64e6af3684e) I was asked whether this feature had any relevance to object mode, so I made it work in both edit and object mode. It doesn't do much in object mode since blender always selects through objects, but maybe it's desired for visual purposes. No reason to make people who only want auto xray in edit mode, but not object mode, to have to turn auto xray on and off all the time. So you can decide which modes use it inside the popover. The same idea applies to the box, circle, and lasso tools themselves. It's better if you can decide which tools use auto xray. That way you don't have turn it on and off when you switch between tools, assuming you want it on for one of them, and off for the others. The following covers some optional features that I either excluded, or separated, from this PR. You can see more details about it in my [custom build](https://blenderartists.org/t/blender-with-better-selection-and-more/1471220) #109150 and at 2:38 of this [youtube video.](https://www.youtube.com/watch?v=HVrFCOa7RO8&t=158s) I didn't want to combine 2 features into a single PR, so I kept select through #109319 separate from auto xray. But it makes sense to have both. They don't conflict, and can even complement each other. My build includes an operator to have a more direct and intuitive control over this modular style of using auto xray. Having a header button also makes it more clear when auto xray is enabled. It seemed less likely to be approved if I am adding header buttons, so I didn't do any of that for this PR. The operator checks what tool and mode you're in. If everything is enabled, meaning the main bool and whichever tool and mode is currently in use, the operator will disable the main bool to turn the feature off. Otherwise, it will turn on any of the bools (main, tool, mode) that aren't enabled. An on/off switch that doesn't compromise individual control and gives visual feedback in the header. To reduce unwanted clutter in the viewport header, I made it where the header buttons for xray, auto xray, and select through are hideable. It is controlled from inside the xray popover. If all of the header buttons are disabled, the xray button will still be visible. Otherwise, any combination of the three buttons are visible in the header.
Lukas Sneyd added 1 commit 2023-06-24 10:18:16 +02:00
Lukas Sneyd added 1 commit 2023-07-05 12:19:04 +02:00
Lukas Sneyd added 1 commit 2023-07-05 12:20:07 +02:00
Lukas Sneyd added 1 commit 2023-07-05 12:31:12 +02:00
Lukas Sneyd added 1 commit 2023-07-11 08:48:55 +02:00
Lukas Sneyd added 1 commit 2023-07-15 23:44:38 +02:00
Lukas Sneyd changed title from WIP: Automatic X-Ray to Automatic X-Ray 2023-07-15 23:47:29 +02:00
Author
First-time contributor

I was told to tag you guys. I don't know what I'm supposed to do, but I will try this. Thanks for your time
@ideasman42 @harley

I was told to tag you guys. I don't know what I'm supposed to do, but I will try this. Thanks for your time @ideasman42 @harley
Member

Could you flesh this out a bit more? For example with the new popover please take a capture and include that in the comment so that people viewing this topic can see it without building it. Similarly you want to "sell" this PR as much as you can by explaining as much as possible in the first comment. Could you explain how the "automatic xray feature" as well as the "some operators that deal with the modular control style automatically" operate? Why is this less "robust" than your custom build? You are writing this while being very familiar with your own custom build but assume reviewers are seeing this for the first time. I can offer help and assistance with this if you like. This also applies to:

Could you flesh this out a bit more? For example with the new popover please take a capture and include that in the comment so that people viewing this topic can see it without building it. Similarly you want to "sell" this PR as much as you can by explaining as much as possible in the first comment. Could you explain how the "automatic xray feature" as well as the "some operators that deal with the modular control style automatically" operate? Why is this less "robust" than your custom build? You are writing this while being very familiar with your own custom build but assume reviewers are seeing this for the first time. I can offer help and assistance with this if you like. This also applies to: * https://projects.blender.org/blender/blender/pulls/109309 * https://projects.blender.org/blender/blender/pulls/109318 * https://projects.blender.org/blender/blender/pulls/109357 * https://projects.blender.org/blender/blender/pulls/109726
Author
First-time contributor

Could you flesh this out a bit more? For example with the new popover please take a capture and include that in the comment so that people viewing this topic can see it without building it. Similarly you want to "sell" this PR as much as you can by explaining as much as possible in the first comment. Could you explain how the "automatic xray feature" as well as the "some operators that deal with the modular control style automatically" operate? Why is this less "robust" than your custom build? You are writing this while being very familiar with your own custom build but assume reviewers are seeing this for the first time. I can offer help and assistance with this if you like. This also applies to:

Sorry, I thought I was supposed to leave these in WIP until something was okayed (and refined if needed) in a design task. The design task here #109075 has some more info in it and timestamps for a youtube video, but no screenshots because I read about not adding too many pictures etc on here, and with a video I figured just save space. Yesterday people told me to take any of the PR's out of WIP if they're done and tag you.

As I was working on these things, I was told a few times that I shouldn't combine different features in one PR, so I didn't do that. I guess you could consider moving the xray settings from Shading to this new xray popover, and giving them a more specific name, a feature. Pretty insignificant on its own so I figured who cares about separating that.

Also been told more than once that it would be less likely to get anything in if I do more unorthodox stuff like make the X-Ray header button hideable, or add a header button, so I didn't do that either. I made an operator that acts like an on/off toggle without sacrificing individual control, and has a hideable header button. If there's no problem with some or all of that, I can change this PR.

I'll try to think of some good descriptions for all of these and add screenshots, thanks again.

> Could you flesh this out a bit more? For example with the new popover please take a capture and include that in the comment so that people viewing this topic can see it without building it. Similarly you want to "sell" this PR as much as you can by explaining as much as possible in the first comment. Could you explain how the "automatic xray feature" as well as the "some operators that deal with the modular control style automatically" operate? Why is this less "robust" than your custom build? You are writing this while being very familiar with your own custom build but assume reviewers are seeing this for the first time. I can offer help and assistance with this if you like. This also applies to: > * https://projects.blender.org/blender/blender/pulls/109309 > * https://projects.blender.org/blender/blender/pulls/109318 > * https://projects.blender.org/blender/blender/pulls/109357 > * https://projects.blender.org/blender/blender/pulls/109726 Sorry, I thought I was supposed to leave these in WIP until something was okayed (and refined if needed) in a design task. The design task here #109075 has some more info in it and timestamps for a youtube video, but no screenshots because I read about not adding too many pictures etc on here, and with a video I figured just save space. Yesterday people told me to take any of the PR's out of WIP if they're done and tag you. As I was working on these things, I was told a few times that I shouldn't combine different features in one PR, so I didn't do that. I guess you could consider moving the xray settings from Shading to this new xray popover, and giving them a more specific name, a feature. Pretty insignificant on its own so I figured who cares about separating that. Also been told more than once that it would be less likely to get anything in if I do more unorthodox stuff like make the X-Ray header button hideable, or add a header button, so I didn't do that either. I made an operator that acts like an on/off toggle without sacrificing individual control, and has a hideable header button. If there's no problem with some or all of that, I can change this PR. I'll try to think of some good descriptions for all of these and add screenshots, thanks again.
Harley Acheson changed title from Automatic X-Ray to UI: Automatic X-Ray 2023-07-17 21:56:24 +02:00
Harley Acheson added this to the User Interface project 2023-07-17 22:41:21 +02:00
Lukas Sneyd added 1 commit 2023-07-23 16:43:04 +02:00
Lukas Sneyd added 1 commit 2023-07-23 16:45:00 +02:00
Lukas Sneyd added 1 commit 2023-07-23 17:54:39 +02:00
1638436dc9 Revert "add newline to remove final gesture ops conflict"
This reverts commit 255a71dd76.

1 of 2 reverts to attempt to fix missing fork info
Lukas Sneyd added 1 commit 2023-07-23 18:19:20 +02:00
Lukas Sneyd added 1 commit 2023-08-01 10:09:25 +02:00
Lukas Sneyd added 2 commits 2023-08-06 08:03:41 +02:00
Lukas Sneyd added 1 commit 2023-08-06 08:17:04 +02:00
Lukas Sneyd added 1 commit 2023-08-06 08:18:32 +02:00
d89746164e Revert "add deconflicted stuff back to gesture ops"
This reverts commit 4221838e11.

forgot to update by merge first
Lukas Sneyd added 1 commit 2023-08-06 08:19:15 +02:00
Lukas Sneyd added 1 commit 2023-08-06 08:32:39 +02:00
Lukas Sneyd added 1 commit 2023-08-13 10:03:39 +02:00
Lukas Sneyd added 1 commit 2023-08-21 06:31:09 +02:00
First-time contributor

This would be very useful! any news?

This would be very useful! any news?
This pull request has changes conflicting with the target branch.
  • scripts/startup/bl_ui/space_view3d.py
  • source/blender/blenloader/intern/versioning_defaults.cc
  • source/blender/makesdna/DNA_scene_types.h

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u automatic-xray:lcas-automatic-xray
git checkout lcas-automatic-xray
Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 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#109318
No description provided.