Commit Graph

129953 Commits

Author SHA1 Message Date
Campbell Barton
3d3b8ae736 Merge branch 'blender-v4.0-release' 2023-10-31 21:36:34 +11:00
Campbell Barton
ea86a77bc5 Docs: add notes on populating bpy.app.driver_namespace
Address issues raised by #114155.

Also fix sphinx documentation generation using incorrect identifiers
when looking up references from PyStruct types
(was looking for `bpy.app.bpy.app.driver_namespace.py`).
2023-10-31 21:34:32 +11:00
casey bianco-davis
c57fe9a6e0 Curves: Add radius transform mode to edit mode
This adds the radius control operator and active tool
to curves edit mode.

Pull Request: https://projects.blender.org/blender/blender/pulls/114017
2023-10-31 11:33:32 +01:00
Michael Jones
f2bb4c617f Cycles: Apple M3 tuning including hardware raytracing
This PR adds tunings for the [newly announced](https://www.youtube.com/watch?v=ctkW3V0Mh-k) M3 family of chips. In particular, MetalRT will be enabled as the automatic default for intersection testing on M3 and beyond to take advantage of hardware raytracing. This will result in significant path-tracing speedups, as well as faster BVH builds.

Pull Request: https://projects.blender.org/blender/blender/pulls/114296
2023-10-31 11:14:16 +01:00
Sietse Brouwer
faeb9e7775 Fix: missing attribute finish() in curves selection code
Fixes a missing attribute `finish()` in the curves selection code.

Pull Request: https://projects.blender.org/blender/blender/pulls/114147
2023-10-31 10:31:50 +01:00
Jeroen Bakker
e7148fc28e Vulkan: Enable Optional Vulkan 12 Features
`shaderOutputLayer` and `shaderOutputViewportIndex` are optional in
Blender, but when used they should be activated on physical device level.
This wasn't the case and when used the validation layer reported an error.

This PR activates the features when creating the device if the features
are available.

Pull Request: https://projects.blender.org/blender/blender/pulls/114303
2023-10-31 08:37:31 +01:00
Campbell Barton
6cc0d10d5f Merge branch 'blender-v4.0-release' 2023-10-31 16:26:53 +11:00
Julien Kaspar
ef0b7337a6 Fix #113920: Missing IC shortcuts
Add various shortcuts that were missing from the industry compatible
key-map. Various grease pencil shortcuts that were intended to be there
are now present.

These issues are now fixed:
- `Alt A` = Missing from GP sculpt mode.
- `Shift S` = Missing.
- `Shift Alt S` = Insert Blank Keyframe - Not added to Edit mode.
- `Y` = Active Layer Menu - Not added to Edit mode.
- `Shift Y` = Merge Down - Does not exist.
- `Shift Backspace/Delete` = Delete All Active Frames is missing from
  every mode except Draw.
- `Backspace/Delete` = Delete Menu is missing from all modes except
  Edit.
2023-10-31 16:01:04 +11:00
Lukas Stockner
d15013b583 Merge branch 'blender-v4.0-release' 2023-10-31 05:48:58 +01:00
Campbell Barton
4bec9d0d71 Fix #114282: Extrude to Cursor tool no longer tweaks on drag
Regression in [0] which only ran drag events if the press event passed
through.

Resolve using the same logic as select picking
(see: WM_operator_flag_only_pass_through_on_press).

[0]: 4d0f846b936c9101ecb76a6db962aac2d74a460a
2023-10-31 14:55:12 +11:00
Alaska
a15f9e49ec Shader: Only clamp undefined or unsupported inputs of Principled BSDF
Adjust clamping of inputs in the Principled BSDF to avoid errors and
inconsistencies between render engines, while trying to leave as many
inputs as possible unclamped for artisitc purposes.

Pull Request: https://projects.blender.org/blender/blender/pulls/112895
2023-10-31 03:14:04 +01:00
Campbell Barton
67b078aa6f Merge branch 'blender-v4.0-release' 2023-10-31 10:45:28 +11:00
Campbell Barton
0e8e8fa462 CMake: mark WITH_COMPILER_ASAN_EXTERN as advanced, quiet warning 2023-10-31 10:42:06 +11:00
Campbell Barton
b27ff093ca Build: resolve error configuring FFMPEG on Linux
Configure failed to find vorbis & vorbisenc on Linux with the errors:

ERROR: vorbis not found using pkg-config
ERROR: vorbisenc not found using pkg-config

the issue was caused by configures test program failing to link the test
code against the static library because functions in libm weren't found.

Resolve by adding `$libm_extralibs` to libvorbis.

Note that it's strange this issue didn't come up before,
since it occurs on a clean build it seems necessary.
2023-10-31 10:38:49 +11:00
Iliya Katueshenock
dca2490689 Fix #114240: Initialize output alpha for RGB color
Pull Request: https://projects.blender.org/blender/blender/pulls/114270
2023-10-30 22:19:58 +01:00
Brecht Van Lommel
4d244bb86d Merge branch 'blender-v4.0-release' 2023-10-30 21:50:35 +01:00
Brecht Van Lommel
39107b3133 Revert changes from main commits that were merged into blender-v4.0-release
The last good commit was 8474716abb0db3b06838a57f7217bc945638d8df.

After this commits from main were pushed to blender-v4.0-release. These are
being reverted.

Commits a4880576dc from to b26f176d1a that happend afterwards were meant for
4.0, and their contents is preserved.
2023-10-30 21:40:35 +01:00
Thomas Barlow
adc79ac8d8 PyAPI: Enable MeshPolygon.loop_start raw array access
This patch replaces MeshPolygon.loop_start's use of
RNA_def_property_int_funcs with RNA_def_property_int_sdna to enable raw
array access.

RNA_def_property_int_funcs disables the PROP_INTERN_RAW_ACCESS flag,
which forces rna_raw_access to fall back to its slower loop when using
bpy_prop_collection.foreach_get/foreach_set from Python.

Because MeshPolygon uses the MIntProperty struct and loop_start accesses
the "i" field of MIntProperty directly, it can use
RNA_def_property_int_sdna like other props that directly access the "i"
field of a StructRNA using the MIntProperty struct.

This then speeds up the Python API bpy_prop_collection.foreach_get/
foreach_set access of MeshPolygon.loop_total to the same speeds as
generic int attributes.

Given a mesh with 98304 faces:

foreach_get with a compatible buffer object:
- Face int attribute: ~0.23ms
- MeshPolygon.loop_start (before): ~1.8ms
- MeshPolygon.loop_start (after): ~0.23ms

foreach_get with a Python list:
- Face int attribute: ~2.2ms
- MeshPolygon.loop_start (before): ~3.4ms
- MeshPolygon.loop_start (after): ~2.2ms

foreach_set with a compatible buffer object:
- Face int attribute: ~0.25ms
- MeshPolygon.loop_start (before): ~2.3ms
- MeshPolygon.loop_start (after): ~0.25ms

foreach_set with a Python list:
- Face int attribute: ~1.1ms
- MeshPolygon.loop_start (before): ~3.1ms
- MeshPolygon.loop_start (after): ~1.1ms

Pull Request: https://projects.blender.org/blender/blender/pulls/114262
2023-10-30 21:03:34 +01:00
Julian Eisel
b659595ab2 Merge remote-tracking branch 'origin/blender-v4.0-release' 2023-10-30 20:26:09 +01:00
Clément Foucault
b26f176d1a Fix #114096: Workbench: Broken thumbnail shadows on Mac
This is the same as 5d06632565fe9cc6ea54260e746c437eaaa23888
but ported to the no-geometry shader version.

However the rendering is still broken for another reason.
See #114286.
2023-10-30 19:46:09 +01:00
Miguel Pozo
2fc17f5afc FIx: Workbench: Shadow debug mode 2023-10-30 19:15:31 +01:00
Julian Eisel
6e160b9054 Merge branch 'blender-v4.0-release' 2023-10-30 18:20:21 +01:00
Julian Eisel
2e1244f3cf Fix resizing asset shelf header edge not working without region overlap
If region overlap was disabled, the full background of the asset shelf
header would be drawn, unlike usually where we keep the space between
button sections transparent. But resizing the region by dragging wasn't
possible from the space between the button sections, even though the
header was fully opaque.

Button section drawing should only be respected when region overlap is
enabled.
2023-10-30 18:19:08 +01:00
Brecht Van Lommel
931c176b06 Merge branch 'blender-v4.0-release' into main 2023-10-30 18:09:42 +01:00
Brecht Van Lommel
9b2deb37a0 Fix Cycles render not stopping on OpenImageDenoise error
Stop so that render farms do not save an image that failed to be denoised
properly and assume it is correct.
2023-10-30 18:08:34 +01:00
Brecht Van Lommel
10645237e8 Cycles: change default Principled Hair BSDF back to Chiang
The Huang model has issues with fireflies in various scenes, and the
defualt choice is somewhat arbitrary anyway as they have both pros and
cons. For now be conservative and keep the default the same as before.
2023-10-30 18:08:34 +01:00
Julian Eisel
4a89720fe1 Fix asset shelf not hidden for new 3D Views
The asset shelf was hidden by default in 04d22d73f3. But this only
affected existing 3D Views, not newly created ones. This wasn't
intentional, 3D Views should have the same defaults here.
2023-10-30 18:02:51 +01:00
Bastien Montagne
a4880576dc I18N: updated translations from Git/Weblate repo (b475c02172373). 2023-10-30 17:20:59 +01:00
Omar Emara
56ffa441b9 Cleanup: Use input reading shaders for Movie Clip node 2023-10-30 17:33:10 +02:00
Omar Emara
f79b3ffe12 Cleanup: Generalise input reading in compositor
This patch generalises the pass reading shaders into input reading
shaders. This is done make future development easier.
2023-10-30 17:27:07 +02:00
Jeroen Bakker
5ba661b706 EEVEE-Next: Fix Infinite Loop With Reflection Probe
When a spherical reflection probe is in the scene and the viewport
is set to a lookdev world the scene was constantly being updated.

The cause for this was that the reflection probes where updated when
the lookdev shader was compiled, but that is almost always the case.

This PR fixes this by checking the compile status and compile status
change. Only the first time the world has been compiled the world
reflection probe will be marked dirty.

Pull Request: https://projects.blender.org/blender/blender/pulls/114276
2023-10-30 16:00:17 +01:00
Jeroen Bakker
fcb26fe72d EEVEE: Update UI Names
This PR will use "EEVEE (Legacy)" for the legacy EEVEE and renames
"EEVEE Next" to "EEVEE".

When starting Blender EEVEE Legacy will still be the default. We
will change the default to EEVEE when all missing features have been
addressed.

After that we can cleanup idnames and panels etc.

Pull Request: https://projects.blender.org/blender/blender/pulls/114272
2023-10-30 15:04:13 +01:00
Jeroen Bakker
f35b0373d6 Vulkan: Separate DataTransfer, Compute, Graphics Commands
Goal is to reduce the number of command buffer flushes by tracking what is
happening in the different command queues. This is an initial step towards
advanced queue-ing strategies.

The new (intermediate) strategy records commands to different command
buffers based on what they do. There is a command buffer for data transfers,
compute pipelines and graphics pipelines.

When a compute command is recorded it ensures that all graphic commands
are finished. When a graphic command is recorded it ensures all compute
commands are finished. When a graphic or compute command is scheduled
all recorded data transfer commands are scheduled as well.

Some improvements are expected as multiple compute and data transfers
commands can now be scheduled at the same time and don't need to unbind
and rebind render passes. Especially when using EEVEE-Next which is
compute centric the performance change is visible for the user.

Pull Request: https://projects.blender.org/blender/blender/pulls/114104
2023-10-30 14:21:14 +01:00
Lukas Tönne
9c8daeb8c9 Fix WM_draw_region_free function declaration.
02fb605f removed the `hide` argument but did not update the WM_api.hh
header.
2023-10-30 13:48:22 +01:00
Sergey Sharybin
ecb346d9df Merge branch 'blender-v4.0-release' 2023-10-30 12:49:40 +01:00
Sergey Sharybin
8474716abb Fix description of MetalRT option
Descriptions should not end with a full-stop.

Pull Request: https://projects.blender.org/blender/blender/pulls/114267
2023-10-30 12:48:04 +01:00
Julian Eisel
02fb605f8a Cleanup: Don't unset region visibility in unrelated WM function
`WM_draw_region_free()` should manage region-draw data, and not change
region state. This should be done by normal region state management
functions. Especially for a flag like `ARegion::visible` which is just
the cached result of the region's visibility evaluation, not the proper
way to actualy manage the region visibility.
2023-10-30 12:40:00 +01:00
Julian Eisel
28a28b9a2c Cleanup: Rename region visibility update function
The old name `region_subwindow()` wasn't really saying anything, and
basically had nothing to do with what the function actually did. Give it
a name that describes better what it does:
`region_evaluate_visibility()`.
2023-10-30 12:31:16 +01:00
Pratik Borhade
9ac87af839 Cleanup: Wrong comment
Mistake in 2a5c499585fe890b0c1c8540e1cf1f93509cec2c
2023-10-30 16:45:51 +05:30
Douglas Paul
b62a5db37b Fix: Node grid dot sizes on Metal
The changes in #112906 (Vulkan: Use Point Shaders When Drawing Points)
broke point sizes for the nodes editor grid on Metal. That PR switched the grid
point drawing code to a shader that sets its own point size, but (at least on Metal)
setting the point size in the shader has no effect unless `GPU_program_point_size(true)`
has been called to allow shader-specified point sizes.

This PR adds the necessary call to `GPU_program_point_size(true)` to fix that problem,
as well as a corresponding "cleanup" call to set it to `false` again.

Pull Request: https://projects.blender.org/blender/blender/pulls/114218
2023-10-30 10:53:13 +01:00
Hans Goudey
ccfe952f34 Depsgraph: Hard-code visibility for "from IDs" builder
`FromIDsBuilderPipeline` is used to build a minimal depsgraph from
a set of IDs. However, the "visibility" of those IDs is still calculated
based on things like the view layer and the relations. Typically we want
all of these to be visible, the builder just happened to be used in
cases when all of the IDs were already visible so far.

This is needed for node tools which may reference objects or other
IDs from outside of the active depsgraph.

Co-authored by: "Sergey Sharybin <sergey@blender.org>"
2023-10-30 10:45:30 +01:00
casey bianco-davis
dddd1d224d Fix #114060: GPv3: Transform crash with multiple object editing
The problem was that the array of `IndexMask`s was set to the
number of objects selected and not the number of curves in all
selected objects.

This fixes the transform code from relying on undefined behavior.

Pull Request: https://projects.blender.org/blender/blender/pulls/114088
2023-10-30 08:14:51 +01:00
Michael Jones
e9ad267151 Cycles: Remove MetalRT experimental status, and add "auto enable" option
_(NOTE: This is a clone of [PR 114067](https://projects.blender.org/blender/blender/pulls/114067), but targeting `blender-v4.0-release` as originally intended)_

This PR removes the "experimental" disclaimer from the MetalRT control now that the unit tests all render correctly with it enabled. As well as "Off" and "On", this adds a third "Auto" setting - a new default which can be used to pick the best option.

Pull Request: https://projects.blender.org/blender/blender/pulls/114232
2023-10-29 14:19:39 +01:00
Julian Eisel
69e5f5175b Grease pencil (legacy): Remove redundant "Use" for checkboxes
There is already a checkbox, so the word "Use" is redundant. See
https://wiki.blender.org/wiki/Human_Interface_Guidelines/Writing_Style#UI_Labels.
2023-10-29 12:33:20 +01:00
Campbell Barton
dffee8b323 Revert "Revert "Fix #112441: Restore Key Map Item does not restore the active property""
This reverts commit 0f36ac4e662f4c00f0f16bd3684a822e8b629f2a.

This revert was only done for testing and wasn't ment to be pushed.
2023-10-29 20:08:39 +11:00
Campbell Barton
88f63c36db Merge branch 'blender-v4.0-release' 2023-10-29 16:55:25 +11:00
Campbell Barton
e8d532a9b6 Merge branch 'blender-v4.0-release' 2023-10-29 16:55:22 +11:00
Campbell Barton
1dc683e376 Fix #114223: Crash when undo in curves edit mode
Regression in [0], missed scene assignment.

[0]: 585f43064a0170225044d16a33728f4b0ae76c9f
2023-10-29 16:53:25 +11:00
Omar Emara
01a2bd0369 Fix #113811: Blender freezes upon adding a Cryptomatte node
Blender freezes when adding a Cryptomatte node and using the GPU
compositor, even if the node is later removed.

This was because the CPU compositor acquired a render result mutex and
never released it due to an early exit that missed that release. This
patch fixes that by adding an appropriate release in that early exist.
2023-10-27 22:25:54 +02:00
Jason Fielder
b0a032e2eb Fix: EEVEE export CMDBuf out of memory in Metal
Previous commit 9333336a73f9e116771a52a2caa96455ea345c71
broke export rendering in Metal due to the command
submission not being flushed between samples.

This would lead to ghosting in export images due
to memory synchronization issues and GPU
scheduling dependency graph problems.

The in-flight memory could also get
extremely high if exporting high numbers
of samples due to all commands being
enqueued within a single submission.

Patch resolves this by flushing for
each render frame sample and
ensuring intermediate in-flight
memory remains controlled.

Authored by Apple: Michael Parkin-White

Pull Request: https://projects.blender.org/blender/blender/pulls/114174
2023-10-27 15:13:49 +02:00