Commit Graph

120055 Commits

Author SHA1 Message Date
Campbell Barton
9e587ce9c7 Merge branch 'blender-v4.3-release' 2024-10-11 11:27:11 +11:00
Campbell Barton
6fe7203d1a Cleanup: suppress dangling-reference warning 2024-10-11 11:24:39 +11:00
Sean Kim
07f298c1e5 Merge branch 'blender-v4.3-release' 2024-10-10 13:49:51 -07:00
Sean Kim
5c855bd6bf Fix: Sculpt: Reduce clay strips z-axis influence
This commit changes the Clay Strips brush in the following ways:
* Removes hardcoded displacement and scaling of brush matrix
* Applies a falloff to the factor based on the distance to the point in
  the brush-local z-axis

This change has the effect of reducing the brush influence on nearby or
other back-facing planes, reducing overall unwanted deformations.

Pull Request: https://projects.blender.org/blender/blender/pulls/128775
2024-10-10 22:49:12 +02:00
Sean Kim
8cf9115fbb Merge branch 'blender-v4.3-release' 2024-10-10 13:42:27 -07:00
Sean Kim
57c4e9dd2c Fix #128820: Mask filter behaves incorrectly with hidden faces
The usage of `hide::node_visible_verts` in this function does not work
as intended, as the resulting span is misaligned with the sliced
per-node mask data. To fix this issue, this commit adds a similar helper
function to copy all hidden vert data and applies changes to all of the
node vertices.

Pull Request: https://projects.blender.org/blender/blender/pulls/128828
2024-10-10 22:40:38 +02:00
Ray Molenkamp
de5ac7395e Merge remote-tracking branch 'origin/blender-v4.3-release' 2024-10-10 12:09:25 -06:00
Omar Emara
c55edd1310 Compositor: Implement previews for new CPU compositor
This patch moves the preview computation code to its own algorithm and
implements it on the CPU as well to support the new CPU compositor.
2024-10-10 18:28:34 +03:00
Clément Foucault
bc3fdc3293 Fix: EEVEE: Object wihtout volume probe visibility don't cast shadow
Object without lightprobe visibility should still
cast shadows during baking. They should only not
bounce indirect lighting.

This is more visible now that shadow linking is supported.

Fix #128812
2024-10-10 16:25:59 +02:00
Clément Foucault
5b70445460 Merge branch 'blender-v4.3-release'
# Conflicts:
#	scripts/addons_core/bl_pkg/bl_extension_ops.py
2024-10-10 16:21:51 +02:00
Clément Foucault
b78354152e Revert "Fix #128407: EEVEE: Cannot allocate volume pool on Intel ARC/OpenGL"
Reverted as it breaks render test on some configs (AMD+Mesa+Linux).
This reverts commit 7d5712be9b.
2024-10-10 16:20:44 +02:00
Clément Foucault
d8b295bfae EEVEE: Add TODO about code going against design 2024-10-10 16:19:14 +02:00
Julian Eisel
10ef436c8f UI: Include asset description in asset shelf tooltip
Tooltips for assets in the asset shelf now don't only display the name,
but also the description saved in the asset's metadata. This is what we
usually do when assets are displayed, for example in the asset browser
or in add menus. Here it was just a small bit of polish that was never
done.
2024-10-10 16:10:34 +02:00
Sybren A. Stüvel
d261a881b1 Anim: change Action.id_root RNA definition to be more like v4.2
Change the `Action.id_root` RNA definition such that
`Action.bl_rna.properties["id_root"].enum_items` returns all valid
values for that property. This was the Blender 4.2 (and older) behaviour
as well.

The only difference now is that v4.3 adds a new `UNSPECIFIED` enum item,
which is not a valid ID type, but is a valid value for `Action.id_root`.

Some more context:

In Blender 4.2 the `Action.id_root` property was a hard-coded list of
all ID types. To add the `UNSPECIFIED` item in v4.3, this was replaced
by an 'items' callback. The way Blender deals with this by default is
such that querying `Action.bl_rna.properties["id_root"].enum_items`
returns its hard-coded default list, and not the result of that 'items'
callback function.

For Action Slots (which will be released in v4.4 but are already in the
sources as experimental feature), there is a similar property that is
implemented in a way such that its `.enum_items` always returns the
proper list. This commit updates the `Action.id_root` RNA property
definition so that it shares code with `ActionSlot.id_root`, fixing the
reported issue.

Note that the `ActionSlot` type is not exposed to RNA in Blender 4.3,
it's just some internal code that is now shared.

Pull Request: https://projects.blender.org/blender/blender/pulls/128834
2024-10-10 14:33:33 +02:00
Clément Foucault
27963d652b EEVEE: Update the GGX LUTs
Pull Request: https://projects.blender.org/blender/blender/pulls/128821
2024-10-10 13:56:13 +02:00
Weizhen Huang
313a7d6236 Fix: EEVEE BXDF LUT generation
Fixes:
1. Mixed use of `sample_reflection` and `sample_refraction`.
`sample_reflection` is intended for when only reflection is required.
For refraction, `sample_vndf` or `sample_refraction` should be used.
2. Wrong weight when accumulating the contribution. Previously
`brdf * NV / (fresnel * pdf)` always evaluates to `GL`, but with the new
technique of bounded VNDF sampling this is not true anymore. Fixed by
adding a field `weight` in the struct `BsdfEval`.
3. Schlick's approximation of the fresnel factor is
`F + (1 - F) * (1 - cos(theta))^5`, but BSDF LUT was using
`cos^2(theta)`, which was incorrect.
2024-10-10 13:56:11 +02:00
Weizhen Huang
0cf7484817 Refactor: EEVEE: separate ggx reflection and transmission functions
They use different techniques, separating them helps with commenting and
readability
2024-10-10 13:56:11 +02:00
Weizhen Huang
3d29979edf EEVEE: improve GGX NDF precision at small roughness
See !125919
2024-10-10 13:56:11 +02:00
Weizhen Huang
3db43b6705 Cleanup: EEVEE: remove unused code block and simplify computations 2024-10-10 13:56:11 +02:00
Weizhen Huang
5df1afad1d Cleanup: EEVEE: remove unnecessary check of normal visibility
We always sample visible normals, this check is unnecessary
2024-10-10 13:56:11 +02:00
Philipp Oeser
e89cf5ecc0 Merge branch 'blender-v4.3-release' 2024-10-10 13:55:29 +02:00
Jacques Lucke
22eac7655d Fix: wrong return type
This only resulted in an assert in debug builds.
2024-10-10 13:55:16 +02:00
Philipp Oeser
da9cf98324 Fix: assert parenting a legacy curve to an armature
The armature modifier calls `BKE_armature_deform_coords_with_mesh` (and
thus `BKE_id_defgroup_list_get`) for legacy curves as well, these are
only "riggable" via envelope weights though (this situation could be
made a bit clearer when parenting -- which is for another commit
though).

So to avoid the (rightful) assert in `BKE_id_defgroup_list_get`, only
call it in case vertex groups are supported (and possibly used later on
-- which is never the case for legacy curves).

Note: this was reported in chat by @LazyDodo because the CurveArmature
test was failing in debug

Pull Request: https://projects.blender.org/blender/blender/pulls/128792
2024-10-10 13:53:51 +02:00
Jacques Lucke
f2352efe55 Fix: wrong return type
This only resulted in an assert in debug builds.
2024-10-10 13:26:07 +02:00
Jonas Holzman
85120627d8 Fix: Wrong RNA doc description for WM_cursor_modal_set() / _restore()
The RNA function doc string / generated bpy documentation for the
`WM_cursor_modal_set` function was being overridden by the documentation
of `WM_cursor_modal_restore` due to a missing `func =`assignment.
Making the `cursor_modal_set` use the documentation of `cursor_modal_restore`,
and leaving `cursor_modal_restore` with no documentation.

Pull Request: https://projects.blender.org/blender/blender/pulls/126227
2024-10-10 12:45:22 +02:00
Jeroen Bakker
318d61756f Merge branch 'blender-v4.3-release' 2024-10-10 12:17:11 +02:00
Jeroen Bakker
9bcba25bc2 Fix #128282: EEVEE: Unable to compile displacement
When using vertex displacement EEVEE didn't compile the generated
functions into the vertex shader. This could result in errors when
compiling materials.

**Notes**

- Should be back-ported to Blender 4.2

Pull Request: https://projects.blender.org/blender/blender/pulls/128525
2024-10-10 12:16:28 +02:00
Jeroen Bakker
a62fa40b58 Merge branch 'blender-v4.3-release' 2024-10-10 11:28:53 +02:00
Jeroen Bakker
7d5712be9b Fix #128407: EEVEE: Cannot allocate volume pool on Intel ARC/OpenGL
When using OpenGL on Intel ARC the driver reports a max 3d allowed size
of 2048. The volume probe will create a texture that doesn't fit in this
dimension when selecting a probe size of 512 or 1024 MB.

This PR will reshape the volume pool atlas texture until it found a shape
that is optimal and fit on the device. When reshaping selects a different
pool size a warning message will be displayed as it might change the
visual quality.

When reshaping the smallest row size will be selected in order
to improve the occupancy. Reshaping will only happens when a
different setting is set in the `Performance->Memory->Light Probes Volume Pool`.

Pull Request: https://projects.blender.org/blender/blender/pulls/128518
2024-10-10 11:28:09 +02:00
Bastien Montagne
d70477ad4e Silence compiler warning about struct initialization.
In C++, in most cases empty braces (aka value initilization) are
the best way to initialize to 0/null (or the default values if
specified in the class/struct declaration).
2024-10-10 11:15:26 +02:00
Bastien Montagne
3adcae5727 Fix compilation warnings with Clang.
Caused by b79dd3fc5d, `nonnull-compare` is a warning option only in
GCC currently.
2024-10-10 11:13:04 +02:00
Anthony Roberts
ef58d4ae26 Windows: Switch to ProcessorNameString for CPU identification on ARM64
This probably should always have been the value used, really.

Now, instead of reporting `Qualcomm Technologies Inc`, it reports the more informative `Snapdragon(R) X Elite - X1E78100 - Qualcomm(R) Oryon(TM) CPU` on a Thinkpad T14s Gen6 device.

Pull Request: https://projects.blender.org/blender/blender/pulls/128808
2024-10-10 10:37:17 +02:00
Campbell Barton
806d1fd1fa Cleanup: quiet set but unused warning 2024-10-10 18:36:08 +11:00
Campbell Barton
c9b7f22e98 Cleanup: use a structure to store edge neighbor for join triangles
Replace 3x arguments and a return value with a structure
that stores the neighboring edges & loops.

Also call add_without_duplicates from a loop instead of inlining.
2024-10-10 18:33:36 +11:00
Aras Pranckevicius
2d5106036f Cleanup: rename OPENEXR_COMPRESS for clarity
Rename to OPENEXR_CODEC_MASK and add comments in several places

Pull Request: https://projects.blender.org/blender/blender/pulls/128814
2024-10-10 08:45:55 +02:00
Jason C. Wenger
dc57693b0c Modeling: add support for merging triangles with reference to topology
A new parameter, topology influence, is added that causes the
join_triangles operator to prioritize edge joins that create quads with
sensible geometry relative to existing quads, instead of selecting the
'flattest' and 'squarest' next pair and then leaving leftover triangles
with no partners to merge with.

This produces its best results with the face and shape thresholds set to
180 degrees (no hard limits as a restriction against merging) and
topology influence somewhere between 100-130%, depending on the mesh.
Too low and many parallelograms and triangles are left, too high and the
algorithm tries too hard and starts making errors.

Note that both quads already present in the selection, as well as the
quads that are generated during the operator, will influence the
topology around them. This allows the modeler to manually merge a few
quads in key areas of the mesh, as a hint to the algorithm, indicating
what result they way they want to see, and the algorithm will then take
those quads into account and try to build around them according to the
modeler's guidance.

A new checkbox to leave only the remaining triangles selected has also
been added. This helps users visualize what remains to be fixed.

Ref !128610
2024-10-10 17:28:59 +11:00
Campbell Barton
085d959d87 Merge branch 'blender-v4.3-release' 2024-10-10 12:19:54 +11:00
Campbell Barton
de0cfcba67 Merge branch 'blender-v4.3-release' 2024-10-10 12:19:47 +11:00
Campbell Barton
a762f2b664 Merge branch 'blender-v4.3-release' 2024-10-10 12:19:45 +11:00
Campbell Barton
f666902d17 Fix error in snap-grid check
Correct check from 75ffda39b2.
2024-10-10 12:17:40 +11:00
Jacques Lucke
2dd9f454c9 Refactor: BKE: use StringRef in IDProperty API
This way it's not necessary anymore to always prepare null-terminated strings
when using IDProperties.

Pull Request: https://projects.blender.org/blender/blender/pulls/128729
2024-10-10 03:17:15 +02:00
Jacques Lucke
b79dd3fc5d BLI: improve FunctionRef constructor in case of a falsy callable
Previously, passing a falsy `std::function` (i.e. it is empty) or a null
function pointer would result in a `FunctionRef` which is thruthy and thus
appeared callable. Now, when the passed in callable is falsy, the resulting
`FunctionRef` will be too.

Pull Request: https://projects.blender.org/blender/blender/pulls/128823
2024-10-10 03:14:44 +02:00
Germano Cavalcante
75ffda39b2 Fix #126665: Reintroduce 'Absolute Grid Snap' (now 'Absolute Increment Snap')
The 'Absolute Grid Snap' feature remains useful even alongside
'Snap to Grid', so this option is being reintroduced, partially
reverting commit f0479e915f.

Pull Request: https://projects.blender.org/blender/blender/pulls/128135
2024-10-09 22:52:28 +02:00
notrudyyy
9da1b8a74b Fix #128473: New node insertion on link search connects to main socket
Fixes an issue with the new node insertion feature where, after a link drag search,
the main input of the new node is connected to, regardless of which one was chosen.

Pull Request: https://projects.blender.org/blender/blender/pulls/128640
2024-10-09 22:18:13 +02:00
Aras Pranckevicius
97208a42d3 UI: Reorder EXR compression dropdown and add tooltips
OpenEXR has many compression codecs exposed, with some of them arguably
not very useful. Generally, for lossless compression you want ZIP or PIZ,
and for lossy compression you want DWAA/DWAB. Reorder the dropdown
entries so that these are at the top just below "No compression".
Previously the not-really-great choice of Pxr24 was the first.

Add tooltips to all the compression codecs too, trying to explain
what each of them does in once sentence.

Remove "(lossless)" labels and keep only "(lossy)" -- this is much easier
to visually parse, since both of them were very similar to each other before.

Pull Request: https://projects.blender.org/blender/blender/pulls/128787
2024-10-09 20:28:59 +02:00
Harley Acheson
97c41218a9 Merge branch 'blender-v4.3-release' 2024-10-09 11:04:33 -07:00
Harley Acheson
cb26e5a169 Fix: Improve Blurry Text 3DView Drag Name
Like #128623 this improved the blurry text shown when dragging an
object into a 3DView.

Pull Request: https://projects.blender.org/blender/blender/pulls/128809
2024-10-09 19:31:11 +02:00
Julian Eisel
2499299ff2 Fix: Empty grease pencil brush libraries linked on startup
Second part to fix #128420.

On startup, the Blender File Outliner mode would show empty libraries
linked, pointing to the brush essentials files. This was because some
grease pencil versioning code would call
`BKE_paint_ensure_from_paintmode()`, which would link in the default
brushes. Then a bit later, brush assets versioning code would remove
local brushes from the default starup file, so the library link became
empty.

Initializing paint data shouldn't necessarily include importing default
brushes. In an earlier version I made this optional with a boolean, but
it's easy enough to separate out entirely.

Now `BKE_paint_ensure()` just initializes paint data, and
`BKE_paint_brushes_ensure()` has to be called to ensure that active
brushes are available.

Pull Request: https://projects.blender.org/blender/blender/pulls/128801
2024-10-09 16:13:01 +02:00
Bastien Montagne
60325a7f8c Gizmo: Refactor storage of 'target properties' to use a Vector.
Replace 'over-allocation' by a standard `blender::Vector` storage for
the `wmGizmoProperty` target properties of the gizmo. This simplifies code somewhat, and
makes the code ready to manage non-trivial types of data.

Explicit default values are also given to all data of `wmGizmoProperty`,
as it appears that the default constructor will not nullify values in
the (trivial) embedded `custom_func` struct.

NOTE: There is much more that could be done in the wmGizmo area to make
it use modern C++ features. The scope of this refactor is strictly
limited to allowing C++ construction/destruction of the wmGizmoProperty
data, as it embeds a PointerRNA pointer that will soon become
a non-trivial C++ struct.

Pull Request: https://projects.blender.org/blender/blender/pulls/128763
2024-10-09 16:07:12 +02:00
Bastien Montagne
2b72cccc85 Merge branch 'blender-v4.3-release' 2024-10-09 15:59:01 +02:00