Commit Graph

146386 Commits

Author SHA1 Message Date
Brecht Van Lommel
cfca7ac952 Fix #133943: Unnecessary image full update mark on file open
This would be done when the frame, layer, pass or view changes compared to
the previous value. But for cases like old files without these members or
loading the image datablock into a different scene, this considered the image
to be always be changed on file load.

Now always reset this state on file load, and don't consider the initial
state as an image update.

This could also happen in the middle of GPU rendering, causing the GPU
texture to be freed while still in use.

Pull Request: https://projects.blender.org/blender/blender/pulls/134198
2025-02-07 21:23:48 +01:00
Sebastian Parborg
78ff230257 Revert "Libs: Update to 4.4 Linux libs"
This reverts commit 924cb219d8.
2025-02-07 20:33:46 +01:00
Sebastian Parborg
924cb219d8 Libs: Update to 4.4 Linux libs
See #128577 for more information
2025-02-07 18:55:36 +01:00
Falk David
971f3e0699 Fix #132826: Grease Pencil: Missing "Paste by Layer" option
The Grease Pencil `Clipboard` only stored a single `CurvesGeometry`. This meant
that the `Paste by Layer` operation (from 4.2 LTS) couldn't be implemented.

This PR adds an `Array` of `ClipboardLayer`s to the  `Clipboard`. Each layer stores
the name of the Grease Pencil layer that it was copied from and the `CurvesGeometry`.

The `grease_pencil.paste` operator has a new property `type` (`ACTIVE` or `LAYER`)
that decides how to paste the strokes.

Using the `ACTIVE` type, the strokes of all the `ClipboardLayer`s get merged and then
pasted to the active layer.
Using the `LAYER` type, we first try to find layers to paste the `ClipboardLayer`s into.
We just look for matching layer names. If no matching layer is found, the strokes are
pasted into the active layer instead.

This should be consistent with how Grease Pencil used to behave in 4.2. LTS.

Pull Request: https://projects.blender.org/blender/blender/pulls/134168
2025-02-07 16:17:16 +01:00
Falk David
a0548950a0 Fix: Compiler warning after recent commit
Caused by 2d18046bbc.
The function should be `static`.
2025-02-07 15:08:17 +01:00
Janne Nylander
bf5a8ab8b9 Fix #133318: Extruding bezier curve with handles selected didn't deselect old handles
Previously bezier curve handle selections were not processed. This would lead to the handles
of the previously selected handles also being dragged around if they were selected before
the extrusion operation.

This pull request will use the control point selection attribute to override the handle
selections. This will lead to both handles always being selected on extrusion.

Pull Request: https://projects.blender.org/blender/blender/pulls/134192
2025-02-07 14:31:57 +01:00
Pratik Borhade
2d18046bbc Fix: Grease Pencil: Missing operator to delete breakdown keyframes
Operation to delete keys generated from interpolate sequence.

Resolves #134081

Pull Request: https://projects.blender.org/blender/blender/pulls/134091
2025-02-07 13:36:38 +01:00
Jacques Lucke
3baac1992a Fix: Nodes: handle undefined nodes more gracefully
Found while checking #134193.
2025-02-07 13:26:24 +01:00
Alaska
3791001b1c Fix: Object info random on lights do not work in Cycles OSL
This commit adds the `light:random` attribute to OSL, allowing the
object info node to now match between SVM and OSL when using the
random output on a light.

Pull Request: https://projects.blender.org/blender/blender/pulls/134095
2025-02-07 13:23:51 +01:00
Campbell Barton
e9dd4853f6 Fix #131947: Error closing prefs while installing extensions on WIN32
Using `signal.SIGINT` to send a signal to a sub-process isn't supported
on WIN32, replace with `signal.CTRL_BREAK_EVENT`.
2025-02-07 23:07:30 +11:00
Bastien Montagne
2f8021775c Animation: Allow overriding transform locks on posed bones.
The reason why this was not enabled is unclear, but has likely to do
with the idea that if this is defined by the rigging department, the
animation department should not tamper with it.

However, preventing animators to lock some transform themselves is
likely a worse limitation here.

Pull Request: https://projects.blender.org/blender/blender/pulls/134169
2025-02-07 12:53:26 +01:00
Bastien Montagne
3cbfd26bad Fix #134212: Crash when appending into an Excluded collection.
Would only happen in some specific cases. Essentially, do not consider
an excluded collection as 'editable'.

Also refactored `BKE_collection_parent_editable_find_recursive` on the
way, as it was applying the same checks twice to all but the initial
processed collections.
2025-02-07 12:45:12 +01:00
Falk David
8c01a59411 Fix: Grease Pencil: Use ensure_selection_attribute in vgroup_select_verts
This was implemented in the kernel but it shouldn't have been.
Since the function operates at the editor level and doesn't
only work at the low-level, it should be in the `object_vgroup.cc` file
in the `editor` context.

This also means that we can use `ensure_selection_attribute` which
fixes a crash when the selection attribute is on the wrong domain.

Pull Request: https://projects.blender.org/blender/blender/pulls/134060
2025-02-07 12:22:29 +01:00
Pratik Borhade
e58b6a3279 Fix #134152: Grease Pencil: Keyframe color missing in viewport text overlays
Use `TH_TIME_GP_KEYFRAME` theme to color the object name in viewport
when there are any keyframes on any layer.

Pull Request: https://projects.blender.org/blender/blender/pulls/134161
2025-02-07 10:56:32 +01:00
Campbell Barton
198d07e240 Extensions: resolve unhandled exceptions when wheel extraction fails
Setting up wheels wasn't handling errors if extraction failed.

Addresses the error in #132924.
2025-02-07 20:30:08 +11:00
Campbell Barton
fb3fe458bf Extensions: forward any errors setting up wheels to reports
When actions on extensions failed setup extensions, errors weren't
forwarded to the user and were only visible in the terminal.
2025-02-07 20:30:02 +11:00
Campbell Barton
466eecf909 Fix potential memory leak file_browse_exec 2025-02-07 16:05:58 +11:00
Campbell Barton
fed8ecdaaf Fix use of MEM_callocN for a struct containing a PointerRNA 2025-02-07 16:05:58 +11:00
Richard Antalik
69b2f603de Fix: VSE duplicate snapping values
Enums `SEQ_SNAP_TO_RETIMING` and `SEQ_SNAP_TO_PREVIEW_BORDERS` were mistakenly
assigned same value.

Pull Request: https://projects.blender.org/blender/blender/pulls/134140
2025-02-07 01:29:03 +01:00
Campbell Barton
7bdffe124a Fix #134201: Invalid doc-string for Scene.ray_cast 2025-02-07 11:17:57 +11:00
Hans Goudey
69b5124e09 Fix: Link error from missing include
Back ported from:
3b4ead2ecc
2025-02-07 10:39:45 +11:00
Campbell Barton
b113e848ef NDOF: implement new methods to pick the orbit-center
Note: this is a back-port from `main`, details below,
Original message:

Add support for dynamic NDOF orbit center calculation.

- When "Auto" NDOF preference is enabled:
  All visible objects in the viewport are used to calculate a
  bounding box center, if the bounds are outside the view or the center
  is behind the viewport, use a Z-Buffer test to calculate the depth in
  the middle of the region.

- When "Use Selected Items" NDOF preferences is enabled,
  calculating the bounds from the selection.

- An option to show the orbit center as a guide has also been added.

Ref !129594

Co-authored-by: Kamil Galik <kgalik@3dconnexion.com>

Back-ported as this change as this only missed the 4.4 branch by hours
and is considered an important feature for 4.4 by 3dconnexion.

This includes the following commits from main:

1a14d69498
30399fd165
3a8658958f
da8d9d989e
2a0ce11104
fb539baa89
2025-02-07 10:23:45 +11:00
Harley Acheson
fd97a8f578 Fix #134166: Show Context Menus as "Options" on Status Bar
The Status Bar often shows context menu items as the name of that menu,
which is confusing in this context. For example in Object mode it shows
"Object" as the right-click operation. In Grease Pencil it shows this
as "Draw" even though you don't draw with it. In "Sculpt" mode you see
two items as "Sculpt", one on left click and the other on right click.
This PR makes all these show as "Options" instead. This seems like a
very succinct description of what is available on right-click.

Pull Request: https://projects.blender.org/blender/blender/pulls/134191
2025-02-06 20:15:44 +01:00
Clément Foucault
59db8d427f Fix #132663: Selection: Object selection is broken on Intel Macs
Copy the fix that is used by EEVEE shadow code.
2025-02-06 19:30:41 +01:00
weizhen
0f8eed340e Fix: Cycles: Compilation issue with OSL on GPU 2025-02-06 18:42:46 +01:00
Sybren A. Stüvel
f9a45702fa Anim: remove ActionLayer.mix_mode and .influence from RNA
Remove the `ActionLayer.mix_mode` and `ActionLayer.influence` properties
from RNA. The animation evaluation already takes these into account, but
there is no guarantee that the mixing that is currently implemented is
going to be mathematically identical to the eventual implementation. So
better to not expose the properties quite yet.

Pull Request: https://projects.blender.org/blender/blender/pulls/134186
2025-02-06 17:49:45 +01:00
Weizhen Huang
b26221a06a Fix #74979: Cycles: Support Normal texture for bump mapping on triangles
The derivatives of the normal were simply not computed.

The offsetted normals are computed by perturbating the barycentric
coordinates. At triangle boundaries, the normals are extrapolated,
so discontinuities might be visible.

Currently only supported on triangles.

Pull Request: https://projects.blender.org/blender/blender/pulls/133769
2025-02-06 16:22:19 +01:00
YimingWu
fc43f4e1e8 Fix #134035: Grease Pencil: Correct index for multistroke modifier
The stroke index was wrong when a influence filter is active in the
modifier, this would lead to crashes. Now corrected this by only
iterating duplicated strokes in front of the curves geometry.

Pull Request: https://projects.blender.org/blender/blender/pulls/134038
2025-02-06 15:08:07 +01:00
Patrick Mours
3b0742ea7c Build: Add Blackwell to OIDN GPU architectures
Pretty straight forward modification to OIDN to increase the max
SM version check and include binaries for the Blackwell GPU
architecture.

Requires CUDA toolkit 12.8+.

Co-authored-by: Brecht Van Lommel <brecht@blender.org>
Co-authored-by: Ray Molenkamp <github@lazydodo.com>

Pull Request: https://projects.blender.org/blender/blender/pulls/134115
2025-02-06 15:04:18 +01:00
Ray Molenkamp
1540817576 For VFX platform 2025 and more.
Boost (removed!)
Cython 3.0.11
Expat 2.6.4
GMP 6.3.0
MaterialX 1.39.2
Nanobind 2.1.0 (new, for OpenVDB)
NumPy 1.26.4
OpenColorIO 2.4.1
OpenEXR 3.3.2
OpenImageIO 3.0.3.1
OpenVDB 12.0.0
OSL 1.14.3-beta
Python 3.11.11
Robinmap 1.3.0
TBB 2021.13.0
TIFF 4.7.0
USD 25.02
libxml2 2.13.5
zlib 1.3.1

Co-authored-by: Brecht Van Lommel <brecht@blender.org>
Co-authored-by: Jonas Holzman <jonas@holzman.fr>
Co-authored-by: Sebastian Parborg <sebastian@blender.org>

Ref #128577

Pull Request: https://projects.blender.org/blender/blender/pulls/134178
2025-02-06 14:57:02 +01:00
Brecht Van Lommel
d5823ad895 Fix: MaterialX 1.39 subsurface not exporting correctly
Pull Request: https://projects.blender.org/blender/blender/pulls/134139
2025-02-06 14:29:42 +01:00
Brecht Van Lommel
7b3fa03e56 Math: Work around Windows math::is_negative build failures
Don't template size for matrix is_negative. These are causing random
build failures on the Windows buildbot.

Note that these already have the assumption of 3D coordinates baked
in. For 2D or 4D coordinates the implementation would have to be
different. So templating these for arbitrary dimensions does not
make much sense.

Pull Request: https://projects.blender.org/blender/blender/pulls/134137
2025-02-06 14:29:09 +01:00
YimingWu
6cf73b052e Fix #134159: Grease Pencil: Use "Blank" for the entry name in add menu
When adding an empty grease pencil object, the menu entry should be
"Blank" instead of "Empty" to be consistent with 4.2x and previous
versions.

Pull Request: https://projects.blender.org/blender/blender/pulls/134175
2025-02-06 13:38:36 +01:00
YimingWu
981f9f767d Fix #134082: Clarify description for subsurface scattering radius
User may think of the `radius` vector value as RGB color, however it's
meant to be the depth of scattering for R/G/B channels. Now clarified in
the desctiption.

Pull Request: https://projects.blender.org/blender/blender/pulls/134088
2025-02-06 12:23:23 +01:00
Jacques Lucke
3b49b5b587 Fix: Geometry Nodes: Instance on Points ignores Grease Pencil layer transform
It already doesn't work in a very fairly simple case when the Grease Pencil
geometry is transformed. This simple case used to work before we changed
the Transform Geometry node to transform layers instead of points.

Pull Request: https://projects.blender.org/blender/blender/pulls/134131
2025-02-06 11:34:58 +01:00
Falk David
8af27ce27e Fix #133969: Crazyspace broken with bezier curves and armature modifier
The issue was that the topology of the drawing changes when the bezier
curves get resampled to poly curves in the armature modifier.
This means that the crazyspace code fails to find deformed positions
with the same length as the original positions.

The fix does multiple things:
* First, we make sure that we create an `GeometryComponentEditData` in
  weight paint mode.
* When the armature modifier runs, we remember the current positions in
  this component.
* Then, we store the curve offsets and weights _before_ converting the
   bezier curves.
* Finally we deform the positions stored in the edit hint component
   (which have the same length as the original positions).

Since the resampling just adds new points, there might be a way to
avoid running the armature deformation a second time on the edit
hints, but I'll leave that for another day as a performance improvement.
In any case, this is only done when we actually need the deformation
(e.g. in weight paint mode when we paint the weights).

Pull Request: https://projects.blender.org/blender/blender/pulls/134030
2025-02-06 11:15:32 +01:00
Bastien Montagne
734af8206c Fix #134162: Crash when opening a file with a compositor image node.
Yet another remaining case of non-trivial data created with C-style
allocation.

While 4.4 and previous did not exhibit the crash, the invalid code
responsible for this crash is present here as well, and it would be
dangerous not to fix it.
2025-02-06 11:07:04 +01:00
Christoph Lendenfeld
ca65379d70 Fix: Indicate that creating a pose asset opens a pop up
As indicated by pablovazquez , operators that open a pop up should end with `...`.

I decided to change the operator name instead of doing it in python with `text=`
This seemed more reasonable to me because it can't be forgotten when adding this operator
somewhere else, but I am not sure if this is the right way to do it.

Pull Request: https://projects.blender.org/blender/blender/pulls/134062
2025-02-06 10:51:04 +01:00
Omar Emara
0a066c11ea Fix #134151: Crash when appending Bloom node
Blender crashes when appending a Bloom node. This is because the scene
is needed to infer the render size while versioning, and the scene
doesn't exist while appending, so we need to fallback to a default
render size in those cases.
2025-02-06 09:47:31 +02:00
Campbell Barton
8e122ccc72 Cleanup: correct spelling in comments (check_spelling_*) 2025-02-06 12:37:32 +11:00
Campbell Barton
f62e7c2ef5 Cleanup: add license header & minor changes
- Relocate header text to be the modules doc-string.
- Add `__all__` so linters can detect unused functions.
2025-02-06 12:34:33 +11:00
Harley Acheson
b39c637d63 Fix #134061: Consider 2D Zoom in Event Icon Text Sizing
Most event icons shown on the status bar are made up of an icon with
text inside of it. The icon sizing used 2D zoom aspect value, but the
text does not. I had not noticed any use of these outside of Status Bar
so this wasn't tested. Using aspect requires much more precise
measurement and placement of the text using calculated margin values.

Pull Request: https://projects.blender.org/blender/blender/pulls/134146
2025-02-05 22:29:48 +01:00
Clément Foucault
0f9c2e47e5 Fix #133576: EEVEE: 'offscreen.draw_view3d' projection matrix broken
This was caused by the input matrix not being used.
Instead EEVEE was trying to derive the projection matrix
again based on the actual viewport state. But this state
was not reflecting the input matrix.

To fix this, we remove any camera setup from the rv3d during
the offscreen drawing and set the lens param to 0.
This ensure EEVEE loads the input projection matrix.
2025-02-05 19:37:05 +01:00
Julian Eisel
9a9e2e19a9 Fix #130007: Invalid current file asset catalogs after saving file
Second part to fix #130007, after 50f7666785.

When saving a new file with the current file asset library loaded, the
library wasn't converted properly to an on-disk library. While the
library was loaded again as on-disk library, the previous runtime
version of it wasn't cleared, so catalog definitions could be duplicated
across available libraries.

Make sure the runtime only library is destructed properly, and the UI
refreshed.

There seem to be more issues with converting the runtime current file library to
a on-disk current file library, but these can be addressed after the crashes and
hangs are fixed, see report.

Pull Request: https://projects.blender.org/blender/blender/pulls/133341
2025-02-05 18:40:04 +01:00
Hans Goudey
4e873487dc Fix: Potential crash in curves attribute set operator
Similar to #134108.
Caused by 0089a90625dd425803e8921a6573e17719b4bf9f..
2025-02-05 11:50:53 -05:00
Harley Acheson
a7178e69f4 Fix: Stop View3D FPS Overlay from Jiggling
If "Playback Frame Rate" is enabled (Preferences / ViewPort / Display)
and showing the "Text Info" viewport overlay, then "fps" is shown in
the place of the View Name while the animation is played. Every time
this starts there is a jiggle where the Object Info line is drawn at
the first line instead. This is because the FPS can early exit and not
update the vertical line position. This PR fixes that.

Pull Request: https://projects.blender.org/blender/blender/pulls/134074
2025-02-05 17:30:17 +01:00
Harley Acheson
3f4a1cabbf UI: On Win11 Use WM Window Decoration Styles API
On Windows 11 use the new WM Window Decoration Styles API, introduced
in ce42d92503. This will match the OS Title bar color to  that of the
main window top bar and also do similar color matching with content
in separate windows like Preferences. Note that this will not have any
effect on versions of Windows prior to 11.

Pull Request: https://projects.blender.org/blender/blender/pulls/134054
2025-02-05 17:15:35 +01:00
Philipp Oeser
b7ce997574 Fix #134104: Curves: handles miss recalc after snapping/randomize/warp
actually mentioned in !133548 already but forgot to include

Pull Request: https://projects.blender.org/blender/blender/pulls/134105
2025-02-05 15:14:13 +01:00
Philipp Oeser
eecf5787c1 Fix #119932: Weight paint loop selection fails when bones are rotated
Previous approach was using non-evaluated meshes to find the closest edge from a face index retrieved from the selection buffer.
This can fail though if the mesh is deformed or even altered to not have the same indices anymore (e.g. generating/masking modifiers).

In order to make this work, added `ED_mesh_pick_edge` which switches the selection context to edges directly
and picks from those. No need to map anything back and forth between original and evaluated, the selection buffer contains the original indices already.

Further logic (following the face loop) is untouched (and happens on the original geometry which is fine)

Should go into 4.2 LTS as well

Pull Request: https://projects.blender.org/blender/blender/pulls/132803
2025-02-05 15:13:48 +01:00
Nikita Sirgienko
bee534eea5 Build: Upgrade Intel Graphics Compiler to 2.1.14 on Linux
This corresponds the latest rolling 2448.13 release:
https://dgpu-docs.intel.com/releases/packages.html?release=Rolling+2448.13&os=Ubuntu+24.04

Graphics compiler upgrades require increasing the minimum required
driver (compute-runtime) version to the corresponding one to guarantee
compatibility, which is XX.XX.31740.15 in this release, so we bump this
requirement accordingly.

Co-authored-by: Xavier Hallade <me@ph0b.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/134051
2025-02-05 15:00:04 +01:00