Commit Graph

149090 Commits

Author SHA1 Message Date
ChengduLittleA
f47df7bc52 Fix #137792: Applying auto-keyframing when resetting property values.
When resetting a proprety with animation, auto-keyframing should also
record the changed value as a new keyframe.

Pull Request: https://projects.blender.org/blender/blender/pulls/137835
2025-04-25 16:41:18 +02:00
Sybren A. Stüvel
a956c34efd Fix #125696: Rigify: spline_tentacle fails to generate sometimes
Ensure the code doesn't delete items from the same collection it is
looping over.

This is done by copying the `self.artifact_reuse_table` dictionary items
and looping over that, making it possible to delete from the original
dictionary.

Co-authored-by: Gianluca Giampuzzo
2025-04-25 16:14:48 +02:00
Aras Pranckevicius
393a1d3d88 Cleanup: DURIAN_CAMERA_SWITCH is always on
The DURIAN_CAMERA_SWITCH feature has been always on since c3401eb5cb
(2009, Blender 2.51), remove the preprocessor option to turn it off.

Pull Request: https://projects.blender.org/blender/blender/pulls/137991
2025-04-25 14:20:52 +02:00
YimingWu
48f9212483 Fix #137700: Guard null lt.editlatt in DRW_cache_lattice_wire_get
Switching to lattice edit mode when it has an armature modifier can
crash if the armature modifier's `show_in_editmode` is turned on. Now
prevent null `editlatt` access.

Pull Request: https://projects.blender.org/blender/blender/pulls/137701
2025-04-25 13:07:54 +02:00
Campbell Barton
2312cc2d1e Fix: error in BVH export when the operator context becomes invalid
Re-check poll succeeds as it's possible (albeit unlikely) for the
context to become invalid after the file selector starts.
2025-04-25 16:25:25 +10:00
Campbell Barton
4f04f6f8af Docs: add warning regarding operators that use the file selector 2025-04-25 16:24:24 +10:00
Andrej730
e09d59f9de Fix duplicated dirpath in fileselect_add docs (0314f9318c)
Ref: !137985
2025-04-25 16:04:18 +10:00
Campbell Barton
93f5f57e64 Fix: correct type for wmWindow::event_queue_consecutive_gesture_type
The event type was stored in a char when event type values
require a larger range.

Also correct the doc-string location of `addmousemove`.
2025-04-25 04:24:10 +00:00
Alaska
3532a25966 Refactor: Factor out Blender API URL in bug fixes per release script 2025-04-25 15:52:09 +12:00
Alaska
4a2e918576 Cleanup: Make format 2025-04-25 15:46:33 +12:00
Campbell Barton
c50ae81c4d Fix: incorrect use of the last handled event
Recent commits ([0], [1]) referenced the last handled event
which is incorrect.

- It represents the previous event (not the event being handled).
- It's documented to only be used by the event queue logic.

Resolve using the current event instead of the last handled.

[0]: a043a0e74d
[1]: 5102880f51
2025-04-25 02:10:47 +00:00
ChengduLittleA
1f657cd38d Cleanup: Modeling: Don't show failed object conversion as incompatible
Previously in b795f09e22 the variable
`incompatible_count` was increased when object conversion failed, this
was not logically correct since the objects type combination is
acceptable compatible, but it's the conversion itself has failed. Do not
increase `incompatible_count` value when this happens, this makes it
consistent with the error message
2025-04-25 10:02:49 +08:00
Howard Trickey
5f57d9ac94 Modeling: fix face merging issue with manifold boolean.
The new manifold boolean operation would merge coplanar faces
even if they had different faceIDs. This doesn't fit user
expectations.
By using the manifold library's "OriginalID" mechanism, we can
prevent that from happening. However, it slows the code by
almost a factor of 2 on large examples.
The Manifold maintainers going to work on a better solution.
2025-04-24 21:32:52 -04:00
Campbell Barton
f09ca4d807 Fix #137940: 3D text cursor displays intermittently when zoomed out
Draw a wire quad along with the filled quad to ensure it's never
less than a pixel width wide.
2025-04-25 11:23:23 +10:00
Campbell Barton
b096066da5 Revert "Fix #137940: Wider Text Caret for Text Object Editing"
This reverts commit 4856cfa89c.

The change only slightly mitigated the issue, revert in favor
of an alternative fix.
2025-04-25 01:23:13 +00:00
Campbell Barton
2ef03e08b3 WM: warn when file selector properties don't match expected types 2025-04-25 10:53:20 +10:00
Campbell Barton
575600d540 Docs: correct use of FILE_PATH for directories
Also correct own error in recent doc-update regarding the expected
return value for fileselect_add.
2025-04-25 10:27:30 +10:00
Campbell Barton
5e61fbe1c1 Cleanup: correct subtype for extensions operators
Use DIR_PATH for directories.
2025-04-25 10:25:42 +10:00
Andrej730
e9c0029316 Docs: add the WindowManager.fileselect_add check_existing property
Ref: !137416
2025-04-25 10:20:08 +10:00
Campbell Barton
0314f9318c Docs: move WindowManager.fileselect_add descriptions into an example
- Allow for formatting and expanded descriptions.
- Clarify the expected types of each property.
2025-04-25 10:18:36 +10:00
Campbell Barton
2d4290f285 Cleanup: spelling in comments (make check_spelling_*)
Also inconsistent capitalization.
2025-04-24 22:45:22 +00:00
Campbell Barton
500509a789 check_spelling: allow variables with an 'th suffix (for indices) 2025-04-25 08:37:11 +10:00
Harley Acheson
4856cfa89c Fix #137940: Wider Text Caret for Text Object Editing
While editing text objects a vertical bar is used as a text caret to
indicate the current cursor position within the string. This is drawn
by the overlay engine with a specific shader that changes size with the
object. Unfortunately this is currently too narrow and will become
subpixel and not display while the text is still readable. This PR just
increases the text caret width so that it is still visible at very
small sizes.

Pull Request: https://projects.blender.org/blender/blender/pulls/137975
2025-04-25 00:13:44 +02:00
Jonas Holzman
19fe66c940 Cleanup: Wandering semicolon in screen_ops.cc 2025-04-24 23:58:53 +02:00
Harley Acheson
587a7f877c UI: Path Line Breaking Characters
This PR adds more line breaking opportunities when breaking file paths.
This adds ".-%?&". Some, like "." are moved to the subsequent line, to
keep period with the extension.

Pull Request: https://projects.blender.org/blender/blender/pulls/137972
2025-04-24 22:23:22 +02:00
Harley Acheson
9dd4e90136 UI: Line Break on Conditional Punctuation
This PR adds new typographical line breaking opportunities, characters
that break depending on what follows. For example comma if not followed
by a space or a number. Period if not followed by a space or another
period. Along with related non-Latin equivalents, like Greek question
mark, full width punctuation, Hebrew, Arabic, etc.

Pull Request: https://projects.blender.org/blender/blender/pulls/137934
2025-04-24 20:42:32 +02:00
Hans Goudey
eb2ce222f5 Fix: Convert attribute operator can change active attribute
Part of #137964.
2025-04-24 14:30:53 -04:00
Pablo Vazquez
f4c31b75ba UI: Rename "Tris to Quads" to "Triangles to Quads"
Rename the operator label to `Triangles to Quads`. This way, when
searching it will show up both when looking for `Triangles` or `Tris`.
Instead of having to always search for `Tris` which is less intuitive.

This also matches the manual, which has been calling this operator
`Triangles to Quads` for several years now.

This does not rename any API or operator name.
2025-04-24 19:00:48 +02:00
Julian Eisel
a8b031dcc6 UI: Use two lines for Asset/File Browser file names under previews
Part of #134755 / #134766

Makes asset and file browser use up to two lines to display the name of the asset or file under
preview images. Lines are wrapped using our existing wrapping algorithm at characters like spaces,
hyphens, under-scores, etc.

This leads to much less information loss because of clipped labels in common cases. When displaying
assets or files as previews the labels would become rather useless in many cases. Especially with
smaller preview sizes.

When there's still not enough space to display the full asset or file name, the second line is
truncated in the middle, leaving the beginning, and some of the end of the label visible. This
produced best results in testing.

Pull Request: https://projects.blender.org/blender/blender/pulls/136907
2025-04-24 18:03:26 +02:00
Christoph Lendenfeld
9663d287fc Anim: merge keyframe jump operators
This merges the `GRAPH_OT_keyframe_jump` operator into the more generic
`SCREEN_OT_keyframe_jump` operator. (the former introduced with #108549)

The functionality of both operators is retained by running
a `switch/case` based on the editor type.
Doing so, we can filter out the Dope Sheet as well which fixes #93944
The `GRAPH_OT_keyframe_jump` is preserved, but when it is called,
it generates a warning stating it should not be used anymore.
It then calls directly into the `SCREEN_OT_keyframe_jump` to
ensure functionality doesn't drift apart.

Fixes #136176
Fixes #93944

Pull Request: https://projects.blender.org/blender/blender/pulls/137542
2025-04-24 18:01:05 +02:00
Julian Eisel
dd3f2ef36b Fix #137939: Collection Exporter properties no longer respond to Undo
The collection exporter UI template uses operator property drawing to
add buttons in the Properties editor. It creates a sort of mock operator
to be able to do that.

This isn't something we usually do. In all other cases where operator
properties are drawn, we don't want them to send undo pushes. Think it's
fine to make that an option of the template. It's opt in though, since
it's an unusual need.
2025-04-24 17:51:24 +02:00
Guillermo Venegas
9887f2290e Refactor: UI: Rename uiItem properties with trailing underscore
This adds a trailing underscore to uiItem member variables
to distinguish them as private.

Continuation of 7002f16992

Pull Request: https://projects.blender.org/blender/blender/pulls/137914
2025-04-24 17:22:28 +02:00
Brecht Van Lommel
a00885666b Fix #98339: Spreadsheet does not immediately report mesh subdiv info
Pull Request: https://projects.blender.org/blender/blender/pulls/137959
2025-04-24 16:07:52 +02:00
Brecht Van Lommel
e21924d0ff Cleanup: Fix kdtree node warnings with GCC
Alternative fix to 50023eab75.

Pull Request: https://projects.blender.org/blender/blender/pulls/137962
2025-04-24 16:00:44 +02:00
Brecht Van Lommel
b23aaa4641 Fix #137821: Crash with grease pencil render, compositor and render region
When using the compositor, the parent scene overrides the render resolution
and region of the child scene. Unlike workbench and EEVEE, the grease pencil
engine was reading this information from the child scene.

Pull Request: https://projects.blender.org/blender/blender/pulls/137923
2025-04-24 16:00:10 +02:00
Brecht Van Lommel
3ee7750fe1 Fix #137869, #105665, #98339: Wrong or delayed mesh subdivision stats
* Fix CPU subdivided meshes not being counted
* Fix wrong check for GPU subdivision
* Draw status bar last so stats reflect latest 3D viewport drawing

Pull Request: https://projects.blender.org/blender/blender/pulls/137959
2025-04-24 15:59:58 +02:00
Clément Foucault
84210efde8 Fix: Vulkan: Avoid warning about enum value not handled in switch 2025-04-24 15:53:21 +02:00
Clément Foucault
551b659c6f Fix: Overlay: Shader error because of implicit cast 2025-04-24 15:52:38 +02:00
Clément Foucault
438f8930cc Fix #137958: Overlay: Lines are too thick
Caused by b8f591c348.
The copy pasted code was not the same everywere.
Invert the result only for the grid shader as it
used to be.
2025-04-24 15:20:33 +02:00
Hans Goudey
0f72fffac3 UI: Clarify Boolean solver descriptions/names and make consistent
Use the same solver names and descriptions for the geometry node,
the modifier, the sculpt trim tool, and the edit mesh intersect operator.
Also clarify the descriptions, some of which used to say that the float
solver had the best performance which isn't true anymore.

Pull Request: https://projects.blender.org/blender/blender/pulls/137922
2025-04-24 15:06:26 +02:00
Clément Foucault
06e642a9a1 Fix: Overlay: Broken shader compilation due to implicit cast 2025-04-24 14:58:37 +02:00
Hans Goudey
13e0e8bd6d Viewport: Fix quadratic runtime for object box selection
Replace a linear search through all objects for every single selection
result with a Map from select ID to object base. This makes the runtime
linear instead of quadratic, resulting in a 100x performance improvement
from 6s to 60ms when selecting about half of 60k objects in a scene.

Pull Request: https://projects.blender.org/blender/blender/pulls/137832
2025-04-24 14:53:06 +02:00
Clément Foucault
59df50c326 GPU: Refactor Qualifier and ImageType
This allow to use types closer to GLSL in resource
declaration.

These are aliased for clarity in the GPU
module (i.e. `isampler2D` is shortened to `Int2D`).

Rel #137446

Pull Request: https://projects.blender.org/blender/blender/pulls/137954
2025-04-24 14:38:13 +02:00
Pablo Vazquez
3d5eda688d UI: Theme: Fix inconsistencies in Light theme
Just small tweaks that should have been addressed when the editor
border theme setting was introduced.

* Fix: Match Top Bar and Status Bar headers with editor border.
* Fix: Properties Editor navigation bar and tabs outline tweak for
  readability.
* Use light color for editor outline/active.

Pull Request: https://projects.blender.org/blender/blender/pulls/137955
2025-04-24 13:59:06 +02:00
Clément Foucault
b8f591c348 Cleanup: Overlay: Share line width macros
Pull Request: https://projects.blender.org/blender/blender/pulls/137953
2025-04-24 13:48:51 +02:00
Clément Foucault
77ed9359dc Cleanup: Overlay: Share vertex enum values 2025-04-24 13:48:51 +02:00
Clément Foucault
d2373cf5d5 Cleanup: Overlay: Use enums instead of defines 2025-04-24 13:48:51 +02:00
Christoph Lendenfeld
09df710eff Refactor: pose select enum to enum class
No functional changes.

This patch converts the `ePose_SelectSame_Mode` enum to an enum class
called `SelectRelatedMode`.
This is done in preparation of adding more modes to the operator.

Pull Request: https://projects.blender.org/blender/blender/pulls/137952
2025-04-24 13:26:56 +02:00
Weizhen Huang
23c762e388 Fix: Cycles: Do not count volume bounds bounce as transparent
In forward path tracing, when we pass volume bounding meshes, we
accumulate `volume_bounds_bounce`. We should match this behaviour in NEE
instead of accumulating `transparent_bounce`.

Pull Request: https://projects.blender.org/blender/blender/pulls/137556
2025-04-24 13:10:33 +02:00
Pablo Vazquez
1cd2b34685 UI: Theme: Update missing properties in Light theme
Save over the light theme so new/removed properties get updated.

No major visual changes expected.
2025-04-24 13:02:13 +02:00