Commit Graph

123308 Commits

Author SHA1 Message Date
Jacques Lucke
ee5e14e5fe Fix: Nodes: forbid muting Group Input nodes
This is already the case for Group Output nodes. It was an oversight
not to do the same for inputs.

Also see https://archive.blender.org/developer/D13364.
2025-09-27 22:52:29 +02:00
Jacques Lucke
221c16f2f0 Nodes: improve descriptions in menu switch node 2025-09-27 22:40:31 +02:00
Jacques Lucke
22fb036e46 Fix: Nodes: incorrect internal links in muted Menu Switch node
Previously, the new recently added boolean outputs were all
internally linked to the first input, but they should not have an
internal link at all.
2025-09-27 22:33:22 +02:00
Jacques Lucke
1fd6d9263c Nodes: menu switch labels in index switch nodes
The goal here is to simplify working with the common pattern where a Menu Switch
node is followed by an Index Switch node. This is achieved by detecting this
pattern and drawing the item names from the menu switch node in the index switch
node.

This slightly refactors the custom socket drawing callback to make it easier for
it indirectly call the default drawing function.

Pull Request: https://projects.blender.org/blender/blender/pulls/145710
2025-09-27 21:49:47 +02:00
Jacques Lucke
ce85d4cbaf Shader Nodes: improve preservation of repeat zones in shader nodes inlining
These are some cleanups and fixes extracted from #146068. Preserved repeat
zones are not used by any render engine yet.

Pull Request: https://projects.blender.org/blender/blender/pulls/146890
2025-09-27 21:02:29 +02:00
Hans Goudey
3bed61b33c Fix #146497: Geometry Nodes: Don't display deprecated "Texture" socket type
Ideally we'll remove this socket type at some point,
but for now we should make sure not to display it.

Pull Request: https://projects.blender.org/blender/blender/pulls/146502
2025-09-27 19:52:18 +02:00
Hans Goudey
eef9a1b9ae Geometry Nodes: UV tangent node
This node outputs tangent values for face corners. There are two methods:
- **Exact** is the same MikkTSpace calculation used elsewhere in Blender.
- **Fast** (from #131308) is over 4x faster, and useful in many of
  the same situations, though not necessarily tangential to the surface.

The reason to include both methods is that there are use cases where the
quality of the tangents don't matter (though the results are actually very
similar visually), we just need some continuous values across faces.

Pull Request: https://projects.blender.org/blender/blender/pulls/145813
2025-09-27 18:57:18 +02:00
Jacques Lucke
986219bf37 Geometry Nodes: support searching for string and data-block values
This extends the ctrl+F search to also support searching for some socket values.
The original motivation for this came from the need to search for a Warning node
by its warning (instead of node name or label). However, I found this to be more
generally useful as it can also be used to search for places where e.g. certain
attribute names are used or where e.g. some object is referenced in an input
socket.

Pull Request: https://projects.blender.org/blender/blender/pulls/146882
2025-09-27 17:21:25 +02:00
Jacques Lucke
25c84e90df Nodes: add button in switch nodes to add inputs
This is a small usability feature to simplify adding additional inputs in the
Index Switch and Menu Switch nodes without having to go to the sidebar.

Technically, something similar can be done for other extend-sockets. However,
here it works best, because one does not have to choose the socket type. For
other inputs we could use a quick popup when pressing the button, but that seems
outside of the scope of this patch.

Later we might also want add the ability to remove existing inputs. But just
adding an icon for that doesn't work so well for socket types that have an input
property.

Co-authored-by: Brady Johnston <36021261+BradyAJohnston@users.noreply.github.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/145915
2025-09-27 16:47:54 +02:00
W_Cloud
4762425e94 Spreadsheet: Improve tooltip of matrix column
Currently, matrix attributes in the spreadsheet are difficult to inspect.

This PR  improves the readability of matrix tooltip, formatting it into
a column-aligned grid. Display floats with 6 significant digits
(3 for abs(x)<1e-4).

Pull Request: https://projects.blender.org/blender/blender/pulls/146207
2025-09-27 16:39:06 +02:00
Jacques Lucke
60a416bea4 Geometry Nodes: improve socket shapes for bundle and closure nodes
Previously, the closure and bundle nodes were a bit restrictive when it comes to
socket shapes. Especially the bundle nodes did not support customizing the
socket shape at all, so they always worked with dynamic values. This was
problematic, because it meant that e.g. the outputs of the Separate Bundle node
looked like they couldn't be used as single values, and other similar issues.

With this patch, the following is supported (a few aspects were supported before
but now it all fits better together): * Support manually selecting socket shapes
in Combine Bundle, Separate Bundle, Closure Input, Closure Output and Evaluate
Closure nodes. * Automatic inferencing of shapes in all these nodes, as long as
the socket shape is set to "auto". * A new "Define Signature" option can be
enabled in the nodes. If enabled, linked nodes will also sync the socket shapes
from that node. In the future, we also want to add support for naming the
signature.

Pull Request: https://projects.blender.org/blender/blender/pulls/145550
2025-09-27 14:58:43 +02:00
Nika Kutsniashvili
3e51b449be UI: Per-camera composition guide colors
Currently cameras composition guide colors are defined in theme, and not even by an individual
property. They follow 3D Viewport -> View Overlay color, which also defines many other things,
such as world origin cursor. By default it's black and it's difficult to change, because then other
things stand out. But using default black for composition guides is impossible.

This PR, instead, adds new Composition Guide Color property on camera, and uses it in camera view.
This not only fixes the issue mentioned above, but also allows different cameras in one scene to
have different overlay colors. This is very handy when you have, for example, two cameras, one of
which looks at the black corner, and another at the lit-up white one. Using a single black or white color
in this case makes the other one more difficult to see. Now, each camera can have its own color.

This PR only changes color for Composition Guides, and NOT for Safe Areas and sensor. Reasons are:
- It's important to differentiate between different concepts, having everything one color is distracting
- Safe areas are per-scene and shared with Sequencer preview. The camera shouldn't dictate color there.
I have separate plans about handling safe areas in the future.

Images in the PR.

Pull Request: https://projects.blender.org/blender/blender/pulls/143788
2025-09-27 13:25:34 +02:00
Jacques Lucke
65f41c4119 Fix #146462: crash when shader output node is in zone 2025-09-27 13:13:22 +02:00
Jacques Lucke
22cdd58ad0 Fix: Geometry Nodes: assert when trying to view extend socket
This happened when e.g. ctrl+shift+clicking on the extend socket of the Group Input node.
2025-09-27 13:05:52 +02:00
Jacques Lucke
f9b993b977 Fix #146870: crash when trying to view non-existant data 2025-09-27 13:05:02 +02:00
Jacques Lucke
b186e60759 Nodes: support node output visibility inferencing
Currently, only the visibility of input sockets can be changed dynamically based
on other menu inputs. However, under some circumstances, it can also be useful
to hide certain outputs. For example, the built-in Curve Arc primitive node does
that.

This patch adds support for automatic detection of unused outputs. How to detect
unused outputs is less straight forward compared to inputs. This patch uses the
rule that an output is unused if it always outputs a "fallback value" (typically
0) irrespective of the currently used inputs. If the output is independent of
all inputs, it stays visible though.

There is a new small utility node called "Enable Output". It replaces a value
with it's fallback value unless it is disabled. This simplifies setting up
unused outputs. In theory, a normal switch node can also be used, but that is
less usable and the user will have to hardcode the fallback value for each type
which is not something that is explicitly exposed yet.

Supporting dynamic output visibility is also a prerequisite for exposing some
menu node options as sockets (e.g. in the Arc node).

Pull Request: https://projects.blender.org/blender/blender/pulls/140856
2025-09-27 10:09:48 +02:00
Jesse Yurkovich
4bb6513b7d Fix #146822: Ensure safe names are used for custom Alembic attributes
We did not sanitize the names used for UV maps or Color attributes when
exporting to Alembic. Names containing characters like ':' or '/' would
cause an unhandled exception from Alembic.

Pull Request: https://projects.blender.org/blender/blender/pulls/146867
2025-09-27 01:23:05 +02:00
Jesse Yurkovich
fd3da2004c Cleanup: Alembic: Remove some unused utility APIs
These have long been unused and they will not be used in the future
either.

Pull Request: https://projects.blender.org/blender/blender/pulls/146863
2025-09-27 00:08:46 +02:00
Brecht Van Lommel
ea43fa08e1 Cleanup: Improve formating of OCIO environment variable in the manual 2025-09-26 18:06:26 +02:00
Brecht Van Lommel
24ef6a3776 Cleanup: Improve formatting of command line argument in the user manual 2025-09-26 17:52:53 +02:00
Nick Alberelli
f7e7a5d09e Logging: Add argument to list all available categories
New `--log-list-categories` command line argument to list all available
logging categories. This improves documentation of logging, allowing
users to understand what logging categories are available for use. It is
also useful for developers to understand what logging categories already
exist before making a change.

Implemented using static initializers to register all logrefs on startup.

Ref  #141754

Pull Request: https://projects.blender.org/blender/blender/pulls/146456
2025-09-26 17:33:26 +02:00
Brecht Van Lommel
fff8d35e3f Color Management: Add option to control display emulation
In Render properties > Color Management > Display.

* Off: Directly output image as produced by OpenColorIO. This is not correct
  in general, but may be used when the system configuration and actual display
  device is known to match the chosen display.
* Automatic: Display images consistent with most other applications, to preview
  images and video for export. A best effort is made to emulate the chosen
  display on the actual display device.

The option is grayed out when the current OpenColorIO config and display/view
does not support emulation.

Ref #145022, #144911

Pull Request: https://projects.blender.org/blender/blender/pulls/146808
2025-09-26 17:05:18 +02:00
Sean Kim
9b5f23c7a3 BKE: Update default smooth curve preset
Updates the `CurveMapping` `CURVE_PRESET_SMOOTH` curve to more closely
approximate the smoothstep function (y = 3x^2 - 2x^3). This has the
implication of changing what happens when the curve is reset, but does
not change any existing curves already stored in blendfiles.

Notably, this change primarily affects three operators:
* brush.curve_preset (Mesh Sculpting)
* brush.sculpt_curves_falloff_preset (Curves Sculpting)
* render.shutter_curve_preset (Motion Blur)

Pull Request: https://projects.blender.org/blender/blender/pulls/146710
2025-09-26 16:43:22 +02:00
Sean Kim
0e2316c2bc Paint: Disable pressure sensitivity for certain brushes
A subset of brushes behave as "anchored" brushes, in that they do not
apply to the surface continually underneath the cursor, but have a
starting point and then are influenced by the mouse movement. These
brushes behave oddly with tablet pressure sensitivity, as they cannot
modulate over the course of the stroke without causing odd behavior.

Currently, the pressure is only sampled at the very beginning of the
stroke, which makes it difficult to control intuitively. Further work
can be done to improve this behavior (e.g. D6603).

The full list of brush types affected is below:
* Grab
* Snake Hook
* Elastic Deform
* Pose
* Boundary
* Thumb
* Rotate
* Cloth with Grab deformation

Resolves #83697

Pull Request: https://projects.blender.org/blender/blender/pulls/146825
2025-09-26 16:41:01 +02:00
Sean Kim
9c7ace059a Refactor: Add name for curve map slope preset enum
Names the formerly anonymous enum as `CurveMapSlopeType`, converts it to
`enum class` and adds a specific backing type for the variable.

Pull Request: https://projects.blender.org/blender/blender/pulls/146840
2025-09-26 16:40:16 +02:00
Pratik Borhade
8e2efa554a Fix: Redraw anim side region when sliding shape key value
Sliding shape key value in dopesheet editor generates keymap but side
panel isn't updated unless we move mouse over it. It has been mentioned
in last Animation module meeting. Fix is to send a notifier from "value"
property whenever edited, this will be listened by `action_region_listener`
to redraw the side region

Pull Request: https://projects.blender.org/blender/blender/pulls/146835
2025-09-26 16:27:14 +02:00
Sebastian Parborg
fcc1502146 Cleanup: Remove the now unused lzma and lzo libraries from extern
LZO and LZMA has been unused in Blender since #141461

Pull Request: https://projects.blender.org/blender/blender/pulls/146842
2025-09-26 15:55:47 +02:00
Lukas Tönne
9aade6bd61 Fix #145762: Ensure a valid background value before pruning SDF grid
OpenVDB will throw an exception when trying to prune a SDF/Level-Set grid with a
negative background value.

The geometry nodes in this case are constructing a nominal SDF grid from a
generic "density" volume cube. The negative background value results from
processing the background value the same way as all other grid values in the new
field+grid math feature (`blender::nodes::process_background`).

Since any grid can be constructed with a negative background value we have to
check and correct this before calling the OpenVDB prune function.

Pull Request: https://projects.blender.org/blender/blender/pulls/146837
2025-09-26 15:26:22 +02:00
Sebastian Parborg
d86de2cde2 Fix #146640: Freeze when force cancelling a CLI render
When we directly call `exit()` from `sig_handle_blender_esc`, the
program will try to free up all static variables and terminate all
threads (and do some file handle cleanup).

The destuctor of the static sound `GlobalState` will hang if
`delayed_close_cv` is in use by other threads as it will wait for them
to let go of it before the destructor finishes.

To make sure that it can finish, the destructor now notifies all
potential threads that they should exit.

Pull Request: https://projects.blender.org/blender/blender/pulls/146665
2025-09-26 14:36:35 +02:00
Campbell Barton
9ebc02fc99 Cleanup: spelling, repeated words (make check_spelling_*) 2025-09-26 22:00:27 +10:00
Campbell Barton
c5d7d58209 Cleanup: correct terminating macro
Harmless but the begin/end macros didn't match.
2025-09-26 21:58:34 +10:00
Campbell Barton
03d85d3779 Fix: logical errors where changes were always detected 2025-09-26 21:58:34 +10:00
Pablo Vazquez
916f0afd45 UI: Nodes: Add Node Group Indicator and minor style tweaks
Nodes have many indicators in their header: whether they have a
preview, warnings, whether they are a node group, plus potentially
more such as if the library is linked/overriden or packed data.

Of all indicators, whether the node is a node group or not is often not
so relevant (especially when many nodes will be just node group assets)
so having an icon takes away precious real estate for other indicators.

Draw the node shape slightly different. A subtle "stack" of nodes
behind Node Groups indicate this is more than just one node.
The stack is only drawn at a certain zoom.

It is now possible to double-click a node group to enter.

It also makes some more room for the node label, since the node group
icon in the header is no longer needed.

Plus a few visual tweaks and fixes for broken/non-valid nodes.

See PR for details and screenshots.

Pull Request: https://projects.blender.org/blender/blender/pulls/145674
2025-09-26 13:29:45 +02:00
Christoph Lendenfeld
b2653be057 Anim: Place Pose Bone Gizmo at Custom Transform
This PR adds an option "Affect Gizmo" for custom shape transforms to affect
the transform gizmos. If enabled, this will place the gizmo at the
location and orientation of the "Override Transform" (i.e. in its local space).

For Orientations: The gizmo mode *is* respected. I.e. global mode is aligned to the world etc.
There is a special case for "Gimbal" where it will not follow the orientation of the
"Override Transform" bone. I think it makes sense to keep it that way since this
is about the channels of the bone you are actually manipulating.

The other option is "Use as Pivot" with which the bone is actually rotated
around the override bone. This can be useful for rigs in which shapekeys and
armature deformation is combined

Taken over from #136468
For design task #135429

Co-authored-by: Wayde Moss <wbmoss_dev@yahoo.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/142847
2025-09-26 13:25:01 +02:00
Pratik Borhade
8e992a15e8 UI: Outliner: Remove empty ID types from listing in Blender File view
Empty idtypes are already handled to be excluded. Still empty group
elements are generated When IDs are linked from other file. This is due
to missing `id->lib` check. Without this, group element of respective ID
is generated even when ID doesn't belong to that library.
If `id->lib` isn't matching, skip creating group tree element for them.

Resolves #145720

Pull Request: https://projects.blender.org/blender/blender/pulls/145779
2025-09-26 13:11:33 +02:00
Nika Kutsniashvili
eca7056cfe UI: Remove paint curve theme colors, use gizmo colors instead
3D Viewport and Image Editor had theme colors for paint curve handle and pivot.
Paint curves are one of the stroke methods for brushes, and are generally not
widely used. To simplify theming it's best to remove those four properties and
use other shared colors instead.

We could use common curve colors for them, but they don't have point color
and handle point color is black, so we would need to add one more property
anyway and it would look bad as well.

Instead, use gizmo primary and secondary colors. Technically, paint curves
can be treated as gizmos, because they're interactive widgets in the viewport.

Pull Request: https://projects.blender.org/blender/blender/pulls/146777
2025-09-26 13:03:55 +02:00
Brecht Van Lommel
712c507519 Logging: Do not print Python API errors that will throw an exception
Python API functions would both report an error through CLOG and throw an
exception. However this is a problem when --debug-exit-on-error is used,
as tests and other scripts will not have the opportunity to catch the exception
before Blender exits.

Now don't print such reports through CLOG. Note that these usages of
BKE_reports_init have their print level set to error, so were already not
printing info and warning reports (which is not something we generally
want Python API calls to do, they should be silent).

Ref #146256

Pull Request: https://projects.blender.org/blender/blender/pulls/146801
2025-09-26 12:57:39 +02:00
Sean Kim
6375b10039 Cleanup: Remove unnecessary conditional when restoring the mesh
The `SCULPT_BRUSH_TYPE_GRAB` and `SCULPT_BRUSH_TYPE_ELASTIC_DEFORM`
types are already handled above the removed lines, generically, without
checking for size pressure. This check of the if statement was
effectively always false as it would never be encountered.

Pull Request: https://projects.blender.org/blender/blender/pulls/146826
2025-09-26 12:24:30 +02:00
Weizhen Huang
2b0a1cae06 Cycles: Add an option to use ray marching for volume rendering
Null Scattering currently has performance and noise issues, and it will
take time to address them. For now add the previous Ray Marching back as
an option.

Co-authored-by: Brecht Van Lommel <brecht@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/146317
2025-09-26 12:14:45 +02:00
Raiko
1aee66bfa4 Fix: Partially Fix #146759 by Adding Missing Library Include to Radial Tiling Node
Node code was missing and include directive.

Pull Request: https://projects.blender.org/blender/blender/pulls/146810
2025-09-26 11:59:57 +02:00
Brady Johnston
75c2dd5e3a Cleanup: Geometry Nodes: use node_geo_exec_with_missing_openvdb
Use `node_geo_exec_with_missing_openvdb` in final location for Grid Info.

Pull Request: https://projects.blender.org/blender/blender/pulls/146827
2025-09-26 11:50:22 +02:00
Julian Eisel
90f723bdd4 UI: Follow HIG for view item selecting/activating
Makes selecting/activating view items (tree and grid view items) behave
as wanted by the guidelines, consistent with many other editors:
https://developer.blender.org/docs/features/interface/human_interface_guidelines/selection/#select-tweaking

Noteworthy:
- View items activate on press again, not on release
- Pose library still only activates poses on click (releasing mouse
  before moving cursor), so dragging can be used to blend poses
- New: Clicking on empty space in a view deselects all
- Redundant activation in interface handlers code is removed

Pull Request: https://projects.blender.org/blender/blender/pulls/146569
2025-09-26 11:26:34 +02:00
Wayne Dixon
ebb843846d Fix: Camera marker selection logic in animation editors
Fix camera marker selection logic in the Dope Sheet (and other editors
that show camera markers).

It is now once again possible to select the camera that is bound to a
marker by CTRL-clicking the marker. SHIFT CTRL will extend this
selection.

(SHIFT+) click still (range-)selects the markers, but not the cameras
themselves. This hasn't changed.

Pull Request: https://projects.blender.org/blender/blender/pulls/145324
2025-09-26 11:25:45 +02:00
luz paz
e3fdc6e408 Cleanup: Fix typo in blender/blendthumb/src/thumbnail_provider.mm
Fixes user-facing typo

Pull Request: https://projects.blender.org/blender/blender/pulls/146765
2025-09-26 11:15:04 +02:00
Hans Goudey
ae56ac2cea UI: Nodes: Indicate packed status in node editor context path
Ref:
- e6a3328da7
- 4e4976804e
2025-09-26 11:11:22 +02:00
Jacques Lucke
4e4976804e Core: Add packed linked data-blocks
This adds support for packed linked data. This is a key part of an improved
asset workflow in Blender.

Packed IDs remain considered as linked data (i.e. they cannot be edited),
but they are stored in the current blendfile. This means that they:
* Are not lost in case the library data becomes unavailable.
* Are not changed in case the library data is updated.

These packed IDs are de-duplicated across blend-files, so e.g. if a shot
file and several of its dependencies all use the same util geometry node,
there will be a single copy of that geometry node in the shot file.

In case there are several versions of a same ID (e.g. linked at different
moments from a same library, which has been modified in-between), there
will be several packed IDs.

Name collisions are averted by storing these packed IDs into a new type of
'archive' libraries (and their namespaces). These libraries:
* Only contain packed IDs.
* Are owned and managed by their 'real' library data-block, called an
  'archive parent'.

For more in-depth, technical design: #132167
UI/UX design: #140870

Co-authored-by: Bastien Montagne <bastien@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/133801
2025-09-26 10:53:40 +02:00
Jeroen Bakker
be4a34d103 Refactor: Vulkan: Move memory allocator ownership to GHOST.
This PR moves the ownership of vulkan memory allocator from gpu/device
to GHOST/context/device. This will allow in the future a cleaner control
flow between OpenXR and Vulkan. Currently as the ownership is in the gpu
module many objects would need to pass from GHOST to the GPU module to be
shared between the 2 allocators. Moving both (OpenXR/Context) allocator
to GHOST would reduce the complexity.

Pull Request: https://projects.blender.org/blender/blender/pulls/146819
2025-09-26 09:34:48 +02:00
Omar Emara
73fcbaf7c4 VSE: Add Compositor modifier
This patch adds a new Compositor modifier that applies a compositing
node group on a sequencer strip. This patch also introduces the concept
of a compositor node tree space subtype, where we now have a Scene and a
Sequencer subtypes. Practically, this just means that node like the
Render Layers node will not be available in the node editor in the
Sequencer subtype.

Future improvements includes:

- The compositor context is recreated on every modifier application,
  while it should ideally be persistent somehow to make use of the
  compositor static cache. This might require work from the compositor
  side by moving the static cache outside of the context and make it
  thread safe if needed. See `Render.compositor` for an example on
  persistent context.
- GPU execution is not supported. This just needs a GPU context to be
  bound before execution, but the tricky part is getting a GPU context.
  See `render::Compositor::execute` for an example on bounding a GPU
  context and why it is less straight forward.
- Node inputs are not exposed on the sequencer modifier interface. An
  approach similar to Geometry Nodes modifier could be used, look at
  `update_input_properties_from_node_tree` for reference, but notice
  that Geometry Nodes naturally exempt the main Geometry socket because
  Geometry inputs can't be exposed, but for the compositor, we will have
  to exempt the main Color and Mask sockets manually. !145971

Co-authored-by: Aras Pranckevicius <aras@nesnausk.org>
Co-authored-by: Falk David <falk@blender.org>
Pull Request: https://projects.blender.org/blender/blender/pulls/139634
2025-09-26 08:40:42 +02:00
tariqsulley
0cf6c32ffd Fix #121129: Crash in bmesh.ops.create_uvsphere if U/V unspecified
Prevent zero U/V segments which caused a crash in
sin_cos_from_fraction from integer divide-by-zero.

Ref !146811
2025-09-26 13:45:14 +10:00
Pablo Vazquez
06b13c8fb4 UI: Splash: Adjust layout and add icons
Small layout and links adjustments to the splash screen.

- Extend list of templates to fit the new Storyboarding template.
- Extend the list of recent files by one row, so it matches templates.
- Add icons to templates.
- Rename `Donate` to `Donate to Blender`.
- Move donate link down so it's more prominent.
- Make separator visible.
- Add "Get Involved" link.
- Remove "Tutorials" link. The Support link already provides help, and
it's been a while since we no longer promote tutorials on blender.org.

See PR for details and screenshots.

Pull Request: https://projects.blender.org/blender/blender/pulls/146730
2025-09-26 00:45:10 +02:00