Commit Graph

122792 Commits

Author SHA1 Message Date
Campbell Barton
d1e0e32769 Cleanup: use more common abbreviation for ToolSettings 2025-09-03 20:10:49 +10:00
Julian Eisel
1b2401cdc3 Fix #142670: Crash when opening search menu after file save
Menus listing assets (which the search menu covers) rely on notifiers to
know when their chached asset catalog tree is invalid and needs
rebuilding. The 3D view notifier listener would not check for the
notifier that is sent when the asset storage was cleared after a file
save.

Pull Request: https://projects.blender.org/blender/blender/pulls/145583
2025-09-03 11:37:22 +02:00
Eitan Traurig
72cbe7adad UI: Add descriptions for UV Select Similar options
Pull Request: https://projects.blender.org/blender/blender/pulls/145486
2025-09-03 10:53:03 +02:00
Omar Emara
3d3f0d1b64 Fix #145498: Cryptomatte assets are not selectable by name
Cryptomatte assets are not selectable by name in the Cryptomatte node
due to missing metadata. This patch adds he necessary meta-data to make
this work.

Pull Request: https://projects.blender.org/blender/blender/pulls/145643
2025-09-03 10:48:00 +02:00
Omar Emara
180accfbaa Fix #145439: Artifacts in Movie Distortion with half precision
The Movie Distortion node produces artifacts when used with half
precision context. This is because distortion grids require full
precision for high quality results, which this patch does.

Pull Request: https://projects.blender.org/blender/blender/pulls/145640
2025-09-03 10:46:33 +02:00
Aras Pranckevicius
37b1886769 Fix #145244: FBX importer does not import textures from some files
Some FBX files contain somewhat incorrect relative paths for their
material textures. The old Python importer was "working" only as a side
effect that it was exhaustively searching the subfolder hierarchy.

Try to do a smaller version of that here too: if referenced image
is still not found after trying the regular relative/absolute paths,
try taking longer path parent chains from the absolute path coming
from FBX file, and using that as relative path wrt the FBX file itself.

Pull Request: https://projects.blender.org/blender/blender/pulls/145641
2025-09-03 10:26:10 +02:00
Campbell Barton
59949b04b3 Cleanup: sort file lists in CMake 2025-09-03 17:54:04 +10:00
Campbell Barton
d77aac594f Fix #145590: translations causing driver expressions to fail
Resolve regression in [0] where name was translated for the name but
not the Python expressions, it's possible to translate both but this
doesn't seem so simple as these functions don't necessarily run at
the same time.

[0]: 6926596174
2025-09-03 17:40:29 +10:00
Omar Emara
6384bb34bd Fix #145607: Stabilize 2D node has no clip selector
The Stabilize 2D node has no clip selector, which was accidentally
removed in a previous commit. This patch adds it back.

Pull Request: https://projects.blender.org/blender/blender/pulls/145634
2025-09-03 09:02:33 +02:00
tariqsulley
4fe13c70cf Fix #126909: checker deselect fails with cyclic topologies
Checker deselect on circular vertex selections or loops produced
irregular patterns instead of a consistent checker pattern.

Resolve by handling cyclic chains as a special case.

Ref !145465
2025-09-03 17:01:49 +10:00
Eitan Traurig
d0740846f4 Modeling: "Auto Merge" support for Symmetrize
Ref !142412
2025-09-03 16:00:57 +10:00
Sean Kim
3c0f8b0def Refactor: Move paint cursor fields to runtime struct
* Moves the paint cursor pointer to `PaintRuntime`
* Removed the stored runtime color value - this was effectively
  hardcoded to a shade of red (255, 100, 100) with an alpha of 128.

The red color was only used for the smooth stroke overlay (the trailing
line) and the alpha value was only ever used for the *Line* stroke type.

Pull Request: https://projects.blender.org/blender/blender/pulls/145371
2025-09-03 07:13:11 +02:00
Toby Yang
5f8311f596 Paint: Add pressure mapping curves for size, jitter, and strength
This commit adds support for users to customize individual pressure
mapping curves for size, strength, and position jitter on a per-brush
basis to improve expression when using drawing tablets. This feature is
already implemented in Grease Pencil, and this PR adds the same
functionality to Texture/Image paint, Vertex/Weight paint, and Sculpt
modes.

The UI and functionality are the same as those in Grease Pencil.

Co-authored-by: Sean Kim <SeanCTKim@protonmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/144428
2025-09-03 05:34:38 +02:00
Hans Goudey
848ced8fe6 Curves: Parallelize nurbs custom knots offsets cache calculation
Build the size for each curve in parallel, then accumulate the sizes
to offsets afterwards. This way it's easy to parallel. Also only count
custom knots for NURBS.

Pull Request: https://projects.blender.org/blender/blender/pulls/145581
2025-09-03 04:29:08 +02:00
Campbell Barton
623f3c2585 Docs: clarify intended use of build defines regarding --help 2025-09-03 10:52:27 +10:00
Campbell Barton
c129ea1b9a Revert "CLI: only show "--qos" on WIN32"
This reverts commit 30837eca7c.

Restore the previous behavior as this argument is handled on other
platforms (it's just not used).
2025-09-03 10:43:18 +10:00
Campbell Barton
2ee1b0fa84 Cleanup: minor changes to target_project_edge error checking
- Move divide-by-zero check earlier.
- Operate on int before float conversion.
- Use float literals.
- Use const variables.
2025-09-03 10:40:06 +10:00
Sean Kim
709286ecc9 UV: Add forwards compatibility conversion for brush size
The prior change missed that `UvSculpt` brushes have their own isolated
`size` value stored at the `ToolSetting` level and not stored as either
brush assets or on the `UnifiedPaintSettings` struct

Similar to #139813

Pull Request: https://projects.blender.org/blender/blender/pulls/144837
2025-09-03 00:23:22 +02:00
Julian Eisel
8bbefda3fc Fix: Last row in file browser showing sometimes clipped out of view
In the vertical list display mode, if only the top part of a file was
scrolled into view, the file wouldn't actually draw. So while scrolling
down the list, the last item would visibly pop up. This wasn't intended,
not drawing these items is just an optimization.

Issue was the offset for the table header (reading something like "Name
| Modified | Size") wasn't accounted for.
2025-09-02 18:47:38 +02:00
Julian Eisel
18b54085b9 Fix #145427: Last entry in file browser may not be displayed
Calculations for the amount of visible items incorrectly substracted the
top list padding.
2025-09-02 18:40:57 +02:00
Falk David
73530b4bff Cleanup: VSE: Rename uses of "sequence" with "strip" 2025-09-02 18:26:14 +02:00
Hans Goudey
bb3bf5fca0 Fix #145560: Invalid curve flag set in legacy curve pen tool
Instead of just disabling the cyclic bit of the flag, the code
reset the whole flag to -2 which doesn't really make sense.
It cause a problem because the "custom knots" bit was set
but there weren't any allocated custom knots.

Pull Request: https://projects.blender.org/blender/blender/pulls/145580
2025-09-02 18:08:28 +02:00
Hans Goudey
dbf777569b Fix #145133: Invalid node link node pointer in certain file
Somehow the file in this report ended up with a node pointer that
disagreed with the socket pointer. Since we use the latter for drawing,
that's a better source of truth. This commit adds a versioning step
that corrects the node pointer. If this happens again we may need
to run the versioning again at some point, but that's not clear.

Pull Request: https://projects.blender.org/blender/blender/pulls/145409
2025-09-02 16:24:26 +02:00
Sybren A. Stüvel
15922bec71 Anim: fix crash when loading F-Curve with unknown modifier
When loading a blend file that has an F-Curve with an unknown modifier
on it, this should be gracefully handled.

Pull Request: https://projects.blender.org/blender/blender/pulls/145574
2025-09-02 16:08:38 +02:00
Jeroen Bakker
8b220fa4cf Cleanup: String formatting
Pull Request: https://projects.blender.org/blender/blender/pulls/145575
2025-09-02 15:11:16 +02:00
Campbell Barton
68c1e2fe31 Fix #71593: Changes to PropertyGroup in add-on preferences aren't saved
Use AncestorPointerRNA to detect when property groups from an add-on
or key-map preference are edited so the preferences are marked as dirty
and saved on exit.
2025-09-02 22:58:26 +10:00
Julian Eisel
287550f759 UI: Allow renaming view items in popups
Fixes #145447.

Previously it wasn't possible to rename view (tree view, grid view)
items in popup regions. Before 450f428434, the popup would close, after
it, it would crash.

Pull Request: https://projects.blender.org/blender/blender/pulls/145567
2025-09-02 14:32:14 +02:00
Bastien Montagne
329112c4d3 NodeTree: Add 'real' custom properties to Nodes.
Add back custom properties to nodes, and properly expose them in the UI
as such (new 'Custom Properties' panel for nodes in the the Node
Editor).

This shows like any other custom property panel in the UI, in the Node editor:

<img width="424" alt="image.png" src="attachments/adb50815-0db0-447f-ac3b-7860d9a3e3fc">

Although not initially intended for this, nodes 'mixed' IDProperties
were quite widely used by py/extensions developers to store per-node
data.

During the initial IDProperties split between User-defined (aka custom
data) and system-defined (runtime RNA properties), this was not known,
so decision was made to only keep system properties for Nodes. The fact
that these properties were not exposed at all in UI also played a role
in that decision. See also discussions in #141042.

This commit instead splits system properties out into their own new
storage, and keep existing ones for user-defined/custom properties
(as done for other IDProperty owners, like IDs, bones, etc.).

Pull Request: https://projects.blender.org/blender/blender/pulls/145424
2025-09-02 14:13:28 +02:00
Brecht Van Lommel
f59446624d Fix #145182: Bone custom shape mesh does not have subdivision
This uses a special delayed extraction code path that is not used by
any other drawing code. Ensure we have the subdivided mesh when GPU
subdivision is off similar to the other code paths.

Pull Request: https://projects.blender.org/blender/blender/pulls/145268
2025-09-02 13:16:39 +02:00
Bastien Montagne
5cdc506750 Hotfix #145562: Crash when passing null value to RNA_property_string_set
Regression from today's heavy get/set refactor commit (469f54f484).

Unclear however if this `RNA_property_string_set` function is expected
to accept nullptr value, as reading code before the breaking commit, it
seems like it would call `strlen` or `BLI_strncpy` on a nullptr then,
which should also fail dramatically?
2025-09-02 12:46:44 +02:00
Jeroen Bakker
fc17013cf3 Cleanup: EEVEE: Remove Metal/AMD workaround
This PR removes an unused workaround.
AMD GPUs aren't supported on Metal since Blender 5.0.

Pull Request: https://projects.blender.org/blender/blender/pulls/145564
2025-09-02 12:41:41 +02:00
Bastien Montagne
469f54f484 BPY: Implement get_transform and set_transform for runtime-defined RNA properties.
Improve handling of runtime defined python RNA properties. Mainly:
* Add `get_transform` and `set_transform` new callbacks.
  These allow to edit the value, while still using the default
  (IDProperty-based) storage system.
* Read-only properties should now be defined using a new `options` flag,
  `READ_ONLY`.
* `get`/`set` should only be used when storing data outside of the
  default system now.
  * Having a `get` without a `set` defined forces property to be
    read-only (same behavior as before).
  * Having a `set` without a `get` is now an error.
* Just like with existing `get/set` callbacks, `get_/set_transform`
  callbacks must always generate values matching the constraints defined
  by their `bpy.props` property definition (same type, within required
  range, same dimensions/sizes for the `Vector` properties, etc.).
* To simplify handling of non-statically sized strings, the relevant
  RNA API has been modified, to use `std::string` instead of
  (allocated) char arrays.

Relevant unittests and benchmarking have been added or updated as part
of this project.

Note: From initial benchmarking, 'transform' versions of get/set are
several times faster than 'real' get/set.

Implements #141042.

Pull Request: https://projects.blender.org/blender/blender/pulls/141303
2025-09-02 11:30:09 +02:00
Jeroen Bakker
75c66158aa Vulkan: Precheck max allowed buffer size
Maintenance4 contains the maxBufferSize property that contains the
maximum allowed buffer allocation.

This PR uses this property to precheck if allocations will fail. It
was an attempt to improve the reliability of failing allocations but
currently they fail at the driver side.

Pull Request: https://projects.blender.org/blender/blender/pulls/145555
2025-09-02 10:57:24 +02:00
Christoph Lendenfeld
ec6dfeb806 Refactor: Remove unused function from UI_view_2d.hh
No functional changes intended.

This removes the unused function `UI_view2d_draw_scale_y__block`
and renames the functions that are `static` to follow the conventions.

Pull Request: https://projects.blender.org/blender/blender/pulls/145342
2025-09-02 09:54:04 +02:00
Jacques Lucke
97ee147f60 Fix: Nodes: wrong structure type inference in Blur Attribute node
The output of this node is always a field, regardless of whether the inputs are fields.
Therefore, using `dependent_field()` is wrong.

Pull Request: https://projects.blender.org/blender/blender/pulls/145548
2025-09-02 09:25:55 +02:00
Jacques Lucke
73b3107168 Fix: Nodes: incorrect structure types in Random Value node
This node is really just a function node. The main thing that's somewhat special about
it is the implicit input for the id, but that's supported for function nodes.

Pull Request: https://projects.blender.org/blender/blender/pulls/145549
2025-09-02 09:22:21 +02:00
Jeroen Bakker
42a8c695bf Fix #144636: EEVEE Invalid hit during raytracing
Raytracing pipeline in EEVEE interpolates in time for better results.
But depending on the interpolation could try to load a sample that isn't
available.

This PR fixies this for planar probes and screen tracing. In screen
tracing the issue wasn't visible as it the background samples are
always cleared.

This has an expected performance penalty but it could require an
overhaul of EEVEE raytracing for a more efficient solution.

Pull Request: https://projects.blender.org/blender/blender/pulls/145508
2025-09-02 07:49:16 +02:00
Brad Smith
c114a1f660 Build: resolve linking error on *BSD systems
Ref !144247
2025-09-02 04:04:20 +00:00
Campbell Barton
30837eca7c CLI: only show "--qos" on WIN32 2025-09-02 11:06:31 +10:00
Campbell Barton
c0aa455389 Correct define check for command line file-type registration
Mistake in [0] caused extension registration to be deferred on all
platforms, instead of non WIN32/APPLE systems.

[0]: 9cb3a17352
2025-09-02 11:01:01 +10:00
Campbell Barton
f3f50b2a4c Build: unbreak lite builds 2025-09-02 00:49:57 +00:00
Harley Acheson
4fccca3e45 Fix #145485: Don't Draw Panels When Hidden or Minimized
Don't draw panel contents when below a threshold, especially when
minimized to show only category tabs.

Pull Request: https://projects.blender.org/blender/blender/pulls/145543
2025-09-02 02:35:09 +02:00
Jacques Lucke
c51eb5b233 Refactor: Nodes: improve InferenceValue abstraction to better support non-primitive values
Currently, `InferenceValue` contains either a primitive value or is in the
"unknown" state. Previously, all code had the assumption that when the value is
not unknown, it is a primitive value. However, that may not be true anymore when
we support inferencing through e.g. bundles and closures as those are not
"primitive". This assumption is removed now, non-primitive values have not been
added yet though.

Pull Request: https://projects.blender.org/blender/blender/pulls/145532
2025-09-01 22:42:57 +02:00
Jacques Lucke
16a9bb1be7 UI: Nodes: gray out sockets in non-editable linked node trees
The goal is to make it more obvious when a node tree is linked (or packed in the future).

Pull Request: https://projects.blender.org/blender/blender/pulls/145387
2025-09-01 22:20:33 +02:00
Howard Trickey
38cb4ba232 Fix #145349: Manifold Boolean kills sharp on edge-vertex intersection.
The code to find output-to-input edge matching missed a case where
both vertices of the output edge existed in the input, but were in
different input meshes.
2025-09-01 16:07:14 -04:00
Jacques Lucke
d685fdbf99 Refactor: Nodes: extract socket value inferencer from usage inferencer
Value and usage inferencing can be done independently. Usage-inferencing uses
the value-inferencing but not the other way around. Extracting value-inferencing
makes the separation more clear and also simplifies potentially reusing the
value-inferencing code later on.

Pull Request: https://projects.blender.org/blender/blender/pulls/145492
2025-09-01 21:07:10 +02:00
Aras Pranckevicius
eb96ef2dff Fix #145116: new FBX importer does not handle geometry transform + instancing properly
When instanced meshes were using FBX geometric transforms, the code
was not telling ufbx to create proper adjustment helper nodes due to
UFBX_GEOMETRY_TRANSFORM_HANDLING_MODIFY_GEOMETRY_NO_FALLBACK flag.
That flag was put in earlier, before import of armatures was solidified,
turns out using the proper flag (UFBX_GEOMETRY_TRANSFORM_HANDLING_MODIFY_GEOMETRY)
is not a problem anymore.

Pull Request: https://projects.blender.org/blender/blender/pulls/145527
2025-09-01 19:39:54 +02:00
Bastien Montagne
2c42ca0657 Readfile: Assert given BHead _is_ an ID one in some util functions. 2025-09-01 19:19:44 +02:00
Philipp Oeser
113f3ae131 Fix #112936: Asset shelf breaks when changing preview size
Underlying reason here is just that whenever a region gets too large to
still be displayed in an area, it simply gets hidden.
This is expected (but also reported elsewhere, see #122277).

It has seen some reports though and it seems we can actually prevent the
AssetShelf from getting too high (and thus being hidden) in case many
rows are used and preview size is increased by automatically decreasing
row count.

Pull Request: https://projects.blender.org/blender/blender/pulls/145117
2025-09-01 18:34:02 +02:00
Brecht Van Lommel
2eaa8dc7d5 Compositor: Add Convert to Display node
This applies an OpenColorIO display, view and look transform on a color
in the scene_linear colorspace.

In general, OpenColorIO configurations do not contain a colorspace for
every view + display, especially if they are modern configs using the
display colorspace and shared view mechanisms. Nor do they include looks.
So the Convert Colorspace node is not sufficient.

Additionally, we would like to avoid making the colorspace list too long
in the default config, as we are adding many new views and transforms.

Exposure, gamma curves and white point functionality are not included
in this node, as there are native ways of doing that in the compositor.
These settings are marked non-editable in the Python API.

Pull Request: https://projects.blender.org/blender/blender/pulls/145069
2025-09-01 16:28:07 +02:00