Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-03-17View 3D: support for select passthrough when picking selected itemsCampbell Barton
Currently this isn't used in the key-map, it will eventually allow the 3D viewports tweak tool to match the behavior of other editors that support tweaking a selection without first de-selecting all other elements.
2022-03-16View 3D: move picking arguments into a struct & minor refactorCampbell Barton
- Add SelectPick_Params struct to make picking logic more straightforward and easier to extend. - Use `eSelectOp` instead of booleans (extend, deselect, toggle) which were used to represent 4 states (which wasn't obvious). - Handle deselect_all when pocking instead of view3d_select_exec, de-duplicate de-selection which was already needed in when replacing the selection in picking functions. - Handle outliner update & notifiers in the picking functions instead of view3d_select_exec. - Fix particle select deselect_all option which did nothing.
2022-02-11File headers: SPDX License migrationCampbell Barton
Use a shorter/simpler license convention, stops the header taking so much space. Follow the SPDX license specification: https://spdx.org/licenses - C/C++/objc/objc++ - Python - Shell Scripts - CMake, GNUmakefile While most of the source tree has been included - `./extern/` was left out. - `./intern/cycles` & `./intern/atomic` are also excluded because they use different header conventions. doc/license/SPDX-license-identifiers.txt has been added to list SPDX all used identifiers. See P2788 for the script that automated these edits. Reviewed By: brecht, mont29, sergey Ref D14069
2022-02-09Cleanup: move file descriptions into doxygen file sectionCampbell Barton
Continuation of 19100aa57d847699d17527b76c2fab1f4ab88885.
2022-01-31Cleanup: use struct for GPU the select bufferCampbell Barton
GPU_select originally used GL_SELECT which defined the format for storing the selection result. Now this is no longer the case, define our own struct - making the code easier to follow: - Avoid having to deal with arrays in both `uint*` and `uint(*)[4]` multiplying offsets by 4 in some cases & not others. - No magic numbers for the offsets of depth & selection-ID. - No need to allocate unused members to match GL_SELECT (halving the buffer size).
2021-12-10Cleanup: move public doc-strings into headers for various API'sCampbell Barton
Some doc-strings were skipped because of blank-lines between the doc-string and the symbol and needed to be moved manually. - Added space below non doc-string comments to make it clear these aren't comments for the symbols directly below them. - Use doxy sections for some headers. Ref T92709
2021-10-27WM: de-duplicate cursor motion checks for selection pickingCampbell Barton
Replace local static mouse coordinate storage with a single function. also resolve inconsistencies. - Edit-mesh selection used equality check (ignoring `U.move_threshold`). - Motion to clear tooltips checked the value without scaling by the DPI. Also prevent the unlikely case of the previous motion check matching a different area by resetting the value when the active region changes.
2021-07-03Cleanup: consistent use of tags: NOTE/TODO/FIXME/XXXCampbell Barton
Also use doxy style function reference `#` prefix chars when referencing identifiers.
2021-04-12UI: Use Consistent name for select mirrorAaron Carlisle
This commit cleans up the RNA names of select mirror operators so that they are all "Select mirror". This makes the select menu in edit/pose mode consistent regardless of object type. Differential Revision: https://developer.blender.org/D7356
2021-04-08Add ability to get a selection list of bonesSebastian Parborg
This adds the ability to get a selection list for both edit mode bones and pose mode bones. To do this the selection menu list logic had to be reworked a bit. Before it only stored the names of objects. This might work will of objects, however as stated in the code, it might fail for linked objects (so multiple object can have the same name in some corner cases). For bones it is a very common occurance where you can have multiple armature that has the same bone names. So now it also stores the object and bone pointers for this case. Reviewed By: Sybren Differential Revision: http://developer.blender.org/D10570 Fix T85796
2021-03-08Cleanup: use ofs instead of offs as an abbreviation for offsetCampbell Barton
Used for local structs/variables, since `ofs` is by far the most widely used abbreviation.
2020-11-06Cleanup: use ELEM macroCampbell Barton
2020-10-24UI: Capitalization CorrectionsYevgeny Makarov
Approximately 141 changes of capitalization to conform to MLA title style. Differential Revision: https://developer.blender.org/D8392 Reviewed by Julian Eisel
2020-10-19Spelling: It's Versus ItsHarley Acheson
Corrects incorrect usage of contraction for 'it is', when possessive 'its' was required. Differential Revision: https://developer.blender.org/D9250 Reviewed by Campbell Barton
2020-10-02Cleanup: Move `EditBone` structure definition from `ED` to `BKE` area.Bastien Montagne
Access to this structure will be needed in BKE's armature code.
2020-10-02Fix T81200: Crash on certain armature select operators when OpenGL DepthPhilipp Oeser
Picking is disabled Affected were (at least) - Select Linked pick - Select Shortest Path Was originally caused by rB8b347fc2cdc6 [which got improved in rBfc8a7a44b200 - but only partially]. After removal of BONESEL_NOSEL we have to filter out -1 from the hits for any bone picking it seems (since armature drawing uses this). In rBfc8a7a44b200, this was done for 'ED_armature_edit_select_pick' (or 'get_nearest_editbonepoint' precisely), now do this for 'ed_armature_pick_bone_impl' as well. Reviewers: campbellbarton Maniphest Tasks: T81200 Differential Revision: https://developer.blender.org/D9080
2020-09-09Cleanup: reduce variable scopeJacques Lucke
2020-07-03Cleanup: Editors/Armature, Clang-Tidy else-after-return fixesSybren A. Stüvel
This addresses warnings from Clang-Tidy's `readability-else-after-return` rule in the `source/blender/editors/armature` module. No functional changes.
2020-06-18Cleanup: redundant parenthesisCampbell Barton
2020-06-10Fix T77560: Bone selection crashesCampbell Barton
The was caused by 8b347fc2cdc67 as the old BONESEL_NOSEL flag handled the -1 case (used for none). Instead of checking for -1, remove these elements from the array as selection code makes decisions based on the number of hits detected.
2020-06-05CodeCleanup: Supressed warningJeroen Bakker
2020-06-05Cleanup: remove braces from previous commit (no functional changes)Campbell Barton
2020-06-05Armature: increase maximum delectable bones from 4096 to 8192Campbell Barton
Remove BONESEL_NOSEL which isn't needed. Addresses issue raised in T77378.
2020-04-10Cleanup: comment bone cycling & simplify logicCampbell Barton
2020-04-09Fix T75425: Bone selection cycling not workingCampbell Barton
Edit-mode bone selection now cycles on successive clicks. This now cycles through multiple edit-objects & bones.
2020-04-03Code Quality: Replace for loops with LISTBASE_FOREACHDalai Felinto
Note this only changes cases where the variable was declared inside the for loop. To handle it outside as well is a different challenge. Differential Revision: https://developer.blender.org/D7320
2020-04-03Cleanup: use abbreviated names for unsigned types in editorsCampbell Barton
2020-04-03Cleanup: bone cursor picking APICampbell Barton
There was one function to access both pose/edit bones, which returned a void pointer type. Split these into 3 functions which return EditBone, bPoseChannel or Bone types. Internally the logic is still shared, this just makes it clearer to callers which type is expected. Also use more conventional prefix for picking API: - ED_armature_pick_(ebone/pchan/bone) - ED_armature_pick_(ebone/pchan/bone)_from_selectbuffer
2020-04-03Fix T75330: Select linked crashes without a bone near the cursorCampbell Barton
Own error with recent improvements to select link.
2020-03-31Cleanup: remove duplicate functionCampbell Barton
2020-03-31Cleanup: use sections for armature-selectCampbell Barton
2020-03-31Armature: add Select Linked (Ctrl-L)Campbell Barton
This matches select linked for other modes (curve, mesh)
2020-03-30Fix armature edit-mode selected linkedCampbell Barton
Selecting linked would only select a single arbitrary chain. Now select linked follows all child-chains of the bone. Also add support for following all links, similar to how this would work if it were a mesh with connected edges instead of only child chains. Leave this off by default to match pose mode.
2020-03-29Cleanup: spelling, commentsCampbell Barton
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2020-03-11Fix T74516: Armature Crash on Select Similar GroupDalai Felinto
Select Similar Group and Select Similar Shape had this issue since they were added. Basically it assumes there is pose data which in some cases it does not.
2019-12-02Overlay Engine: Refactor & CleanupClément Foucault
This is the unification of all overlays into one overlay engine as described in T65347. I went over all the code making it more future proof with less hacks and removing old / not relevent parts. Goals / Acheivements: - Remove internal shader usage (only drw shaders) - Remove viewportSize and viewportSizeInv and put them in gloabl ubo - Fixed some drawing issues: Missing probe option and Missing Alt+B clipping of some shader - Remove old (legacy) shaders dependancy (not using view UBO). - Less shader variation (less compilation time at first load and less patching needed for vulkan) - removed some geom shaders when I could - Remove static e_data (except shaders storage where it is OK) - Clear the way to fix some anoying limitations (dithered transparency, background image compositing etc...) - Wireframe drawing now uses the same batching capabilities as workbench & eevee (indirect drawing). - Reduced complexity, removed ~3000 Lines of code in draw (also removed a lot of unused shader in GPU). - Post AA to avoid complexity and cost of MSAA. Remaining issues: - ~~Armature edits, overlay toggles, (... others?) are not refreshing viewport after AA is complete~~ - FXAA is not the best for wires, maybe investigate SMAA - Maybe do something more temporally stable for AA. - ~~Paint overlays are not working with AA.~~ - ~~infront objects are difficult to select.~~ - ~~the infront wires sometimes goes through they solid counterpart (missing clear maybe?) (toggle overlays on-off when using infront+wireframe overlay in solid shading)~~ Note: I made some decision to change slightly the appearance of some objects to simplify their drawing. Namely the empty arrows end (which is now hollow/wire) and distance points of the cameras/spots being done by lines. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D6296
2019-09-18Fix excessive dependency graph evaluation while painting strokesBrecht Van Lommel
Particularly noticeable when vertex painting with a subsurf modifier. In some cases every sculpt or paint stroke step would evaluate the dependency graph. This should only happen for redraws. Now more selectively choose if the dependency graph should be evaluated to initialize the view context. Doing it in the view context evaluation is somewhat hidden, now it's more explicit. Differential Revision: https://developer.blender.org/D5844
2019-08-16Outliner: Synced selection and active element highlightingNathan Craddock
Adds a toggle to the filter menu for outliner synced selection. Enabled by default, this ensures selection is synced between objects, bones, and sequences. An active outliner element theme color is added to indicate which element is active. Synced selection is controlled on the operator level. Each operator that modifies selection for objects, bones, sequences, or outliner elements needs to call the respective ED_outliner_select_sync_from.. function to tag outliners to be synced. Syncing is done lazily on outliner draw.
2019-05-09DepsGraph: Multi ViewLayer SelectionJeroen Bakker
When using multiple viewlayers and switching between them the selection gets buggy. The reason for this is that the select_id is updated based on the index in the viewlayer. This makes the select_id not unique as objects might be shared or not shared at all. This fix will update the select_id on all objects in main. This will be triggered in all the selection operators. Reviewed By: sergey, brecht Maniphest Tasks: T55617 Differential Revision: https://developer.blender.org/D4824
2019-04-29Cleanup: comments (long lines) in editorsCampbell Barton
2019-04-22Cleanup: style, use braces for editorsCampbell Barton
2019-04-17ClangFormat: apply to source, most of internCampbell Barton
Apply clang format as proposed in T53211. For details on usage and instructions for migrating branches without conflicts, see: https://wiki.blender.org/wiki/Tools/ClangFormat
2019-04-09Fix T62114: Wireframe mode selection: selects backside objects when clicking ↵Sebastian Parborg
frontside object in 3d-window Now the depth order of objects when trying to select them is only used when not in X-ray mode. Before, this was only the case in wireframe mode regardless of X-ray settings. I've also unified the usage of V3D_XRAY and XRAY_FLAG as they were basically copies of each other. Reviewed By: Clément Differential Revision: http://developer.blender.org/D4504
2019-03-263D View: move deselect all logic into an optionCampbell Barton
This removes `VIEW3D_OT_select_or_deselect_all`, adding a deselect_all option to the `VIEW3D_OT_select` operator. - Add utility functions to simplify de-selecting all. - Return true from selection functions when they change the selection to avoid redundant updates. - Use arrays of bases when passing objects between selection utility functions since some users require bases. - Fix logical error in box selection that updated all objects after the first hit.
2019-03-20Preferences: add threshold for cursor motionCampbell Barton
A hard coded threshold was used to ignore cursor motion, make this a preference since tablet users may want to increase it since a pen hovering isn't as easy to keep still as a mouse. Resolves T56278
2019-03-19UI: scale cursor motion threshold by DPICampbell Barton
This was using hard coded values of 2-3px. Move both drag and motion thresholds to defines.
2019-03-09Fix T62162: Bones set to unselectable can be fully selected through the ↵Sebastian Parborg
viewport in edit mode. Bone selectability in edit mode now matches the behavior of pose mode (can no longer be selected). Reviewed By: Brecht Differential Revision: http://developer.blender.org/D4469
2019-02-19DNA: rename select_color -> select_idCampbell Barton
The term color is misleading, it's an integer id that happens to be written to a color in some cases, then converted back to an integer.
2019-02-18doxygen: add newline after \fileCampbell Barton
While \file doesn't need an argument, it can't have another doxy command after it.