Commit Graph

132936 Commits

Author SHA1 Message Date
Campbell Barton
3dde1e9df7 Merge branch 'blender-v4.1-release' 2024-02-15 11:03:45 +11:00
Campbell Barton
bdd40f167e Merge branch 'blender-v4.1-release' 2024-02-15 11:03:42 +11:00
Hans Goudey
c07132b43b Cleanup: Make format 2024-02-14 17:43:03 -05:00
Hans Goudey
c4d0e88e6e Fix: Asset browser crash after recent cleanup
After 57586df687. Turns out the library can be null here.
2024-02-14 17:41:17 -05:00
Hans Goudey
b9ed6ce0a5 Refactor: Various C++ improvements to collection property search
- Use FunctionRef to avoid passing a separate user_data pointer
- Use std::string in arguments struct
- Add search items in one loop after gathering search items
- Use Vector of unique_ptr for search items instead of linked list
2024-02-14 17:23:01 -05:00
Hans Goudey
61e61ce0e1 Cleanup: Use Span instead of Vector const reference
Span is preferrable since it's agnostic of the source container,
makes it clearer that there is no ownership, is 8 bytes smaller,
and can be passed by value.
2024-02-14 17:23:01 -05:00
Hans Goudey
a24d6e7012 Cleanup: Use StringRef instead of StringRefNull
The called function here only needs StringRef, that can apply here too.
2024-02-14 17:23:01 -05:00
Hans Goudey
aef0b6552b Cleanup: Use helper functions to access next and previous face corners 2024-02-14 17:23:01 -05:00
Hans Goudey
57586df687 Cleanup: Remove unnecessary asset system functions
These functions appear to be thin wrappers around the C++ classes
that previously weren't accessible in C code.
2024-02-14 17:23:01 -05:00
Hans Goudey
7098e53c61 Cleanup: Use "this" keyword to access class methods 2024-02-14 17:23:01 -05:00
Iliya Katueshenock
faf056f17b Cleanup: Move mesh utility to create mesh without attributes
Mesh with no attributes is used to build new mesh from scratch.
Some data can be shared, so there is no reason to have allocated attributes.

Pull Request: https://projects.blender.org/blender/blender/pulls/118297
2024-02-14 23:14:12 +01:00
Sergey Sharybin
33af56f13e GPU Compositor: Avoid global DST lock on Linux
It is not required to hold the lock of DST when performing
compositing on GPU, as the compositor implementation uses the
GPU module directly, bypassing the draw manager.

However, currently this is known to cause issues on macOS,
and is not yet tested on Windows.

On Linux it works correctly, and avoids lock while compositor
is running.

There could still be a small locking hiccup, when the GPU
context is created and disposed. This needs to be looked
into.

Pull Request: https://projects.blender.org/blender/blender/pulls/118286
2024-02-14 19:30:38 +01:00
Clément Foucault
7b328390f4 Cleanup: EEVEE-Next: Remove unused mip level in remap shader 2024-02-14 18:52:58 +01:00
Clément Foucault
da72cdee5e EEVEE-Next: Add compute shader to downsample sphere probe
This has no functional change except that it might speed
up probe updates since only updated pixels are processed.

Ref #118256
2024-02-14 18:52:58 +01:00
Hans Goudey
1c3c1e7776 Cleanup: Simplify asset metadata copy function
Also move the destructor declaration to be consistent with the style guide.
2024-02-14 12:06:56 -05:00
Harley Acheson
48dee674f3 UI: Changes to Menu Separator Padding
Add interior horizontal padding to menu separator lines.

Pull Request: https://projects.blender.org/blender/blender/pulls/118227
2024-02-14 17:14:17 +01:00
Hans Goudey
a52323d711 Cleanup: Move BKE_duplilist.hh to C++ 2024-02-14 10:51:46 -05:00
Hans Goudey
ed0be291c8 Cleanup: Use float4x4 matrix type in volume displace modifier 2024-02-14 10:51:46 -05:00
Iliya Katueshenock
85b93772db Fix #118104: Menu Switch shows menu socket in input link-drag-search
The node currently doesn't support outputting the menu socket type.

Pull Request: https://projects.blender.org/blender/blender/pulls/118110
2024-02-14 16:49:07 +01:00
Clément Foucault
0c279526eb EEVEE-Next: Render Tests: Bake world in volume probes
Improves quality. Doesn't impact performance
2024-02-14 16:24:02 +01:00
Clément Foucault
f20425bc4c Fix: EEVEE-Next: Missing Volume Probe update after world update 2024-02-14 16:24:02 +01:00
Hans Goudey
1c0f374ec3 Object: Move transform matrices to runtime struct
The `object_to_world` and `world_to_object` matrices are set during
depsgraph evaluation, calculated from the object's animated location,
rotation, scale, parenting, and constraints. It's confusing and
unnecessary to store them with the original data in DNA.

This commit moves them to `ObjectRuntime` and moves the matrices to
use the C++ `float4x4` type, giving the potential for simplified code
using the C++ abstractions. The matrices are accessible with functions
on `Object` directly since they are used so commonly. Though for write
access, directly using the runtime struct is necessary.

The inverse `world_to_object` matrix is often calculated before it's
used, even though it's calculated as part of depsgraph evaluation.
Long term we might not want to store this in `ObjectRuntime` at all,
and just calculate it on demand. Or at least we should remove the
redundant calculations. That should be done separately though.

Pull Request: https://projects.blender.org/blender/blender/pulls/118210
2024-02-14 16:14:49 +01:00
Clément Foucault
bdd15e827f Fix: EEVEE-Next: Crash in bake caused by motion blur
Motion blur needs to be disabled for volume probe baking.
2024-02-14 15:55:36 +01:00
Clément Foucault
b647bed2d5 EEVEE-Next: Render Tests: Cosmetic changes 2024-02-14 15:55:36 +01:00
Clément Foucault
90dc66885f Fix: EEVEE-Next: Render Tests: Change probe visibility before bake 2024-02-14 15:55:36 +01:00
Omar Emara
357d6fcae1 Cleanup: Format 2024-02-14 16:50:20 +02:00
Brecht Van Lommel
aefd930317 Fix: Build error when not using unity build 2024-02-14 15:13:12 +01:00
Clément Foucault
2d08e16601 Cleanup: EEVEE-Next: Split display sync function 2024-02-14 15:09:31 +01:00
Clément Foucault
ee6c7d8eea Fix: EEVEE-Next: Sphere Probe: Wrong world probe index 2024-02-14 15:09:31 +01:00
Jacques Lucke
d27a1c47fa Nodes: hide uneditable input sockets in sidebar
This hides some labels from the sidebar which look a bit out of place.

Pull Request: https://projects.blender.org/blender/blender/pulls/118264
2024-02-14 14:47:07 +01:00
Omar Emara
da238bdb2f Fix: Realtime Compositor tests use CPU compositor
The Realtime Compositor uses the CPU compositor. That's because the enum
identifier of the Realtime Compositor changed to GPU, so update the test
script accordingly.
2024-02-14 15:35:35 +02:00
Sergey Sharybin
a8a05ebba1 Compositor: Switch CPU compositor to Full-Frame
The tiled compositor code is mainly still around, which is only
expected to be a short-lived period. Eventually it will also be
removed.

The OpenCL, Group Buffers, and Chunk size options are already removed.

Pull Request: https://projects.blender.org/blender/blender/pulls/118010
2024-02-14 14:23:49 +01:00
Clément Foucault
7cc4339ce2 EEVEE-Next: Improve tests appearance
This improves the volume probe resolution and
dimensions to envelope most test scenes.
This doesn't increase the baking time
that much as most of the baking time is
spent compiling shaders.
2024-02-14 13:02:01 +01:00
Clément Foucault
1f8fac5082 Fix: EEVEE-Next: Broken light baking from script
The G.is_break was not properly set back to false
and the data was never copied back to the original
object.
2024-02-14 13:02:01 +01:00
Brecht Van Lommel
088ae8d905 Build: Remove LLVM linking no longer needed by OSL
These are now included in the OSL shared libraries, so no reason to
link against it.

The CMake code for WITH_LLVM remains in case it is useful in the future,
but is not enabled by any Blender feature now.

Pull Request: https://projects.blender.org/blender/blender/pulls/118229
2024-02-14 12:06:52 +01:00
Sergey Sharybin
2cec7e3aa5 Fix levels node regression in tiled compositor
Caused by previous change for full-frame compositor.

The determine_canvas() is still used by the tiled compositor,
so restore it to the state which makes both compositors to work.

Pull Request: https://projects.blender.org/blender/blender/pulls/118254
2024-02-14 12:02:59 +01:00
Pratik Borhade
dda277e48c Merge branch 'blender-v4.1-release' 2024-02-14 16:22:28 +05:30
Pratik Borhade
f344823785 UI: Opus files not included in sound files filter
Include `.opus` extension in audio filter list

Fixes #118235

Pull Request: https://projects.blender.org/blender/blender/pulls/118238
2024-02-14 11:39:11 +01:00
Pratik Borhade
18912561b5 Fix #118163: Crash hiding face sets with multires
Caused by ce4ec6d42b
Crash occurs due to accessing `corner_tri_faces` when pbvh tpye is
"grid".
Fix is same as 72d324bd81

Pull Request: https://projects.blender.org/blender/blender/pulls/118183
2024-02-14 11:37:11 +01:00
Sergey Sharybin
a1047e0689 Compositor: Make CPU Level node output single value
This aligns the node behavior to GPU compositor.

The implementation is a bit of a stretch of the full-frame
constant-foldable operations, but this is as good as it can
get in a short time.

The alternative could be to somehow inject a SetValue
operation, but since it expects ahead-of-time known value it
is not as straight forward.

Pull Request: https://projects.blender.org/blender/blender/pulls/118248
2024-02-14 10:54:59 +01:00
Campbell Barton
8a4c45a202 Merge branch 'blender-v4.1-release' 2024-02-14 15:33:09 +11:00
Campbell Barton
0b9ec567c8 Cleanup: format 2024-02-14 15:31:31 +11:00
Campbell Barton
156fffbfde Merge branch 'blender-v4.1-release' 2024-02-14 14:29:55 +11:00
Campbell Barton
5a86067ff0 Fix build error from duplicate include 2024-02-14 14:27:58 +11:00
Campbell Barton
291ca4ec8e Cleanup: unused variable, redundant strlen call 2024-02-14 13:59:37 +11:00
Campbell Barton
aa6ab9caf9 Cleanup: various non-functional changes for C++ 2024-02-14 13:56:58 +11:00
Campbell Barton
cdc17751ae Cleanup: format 2024-02-14 13:53:36 +11:00
Campbell Barton
1111dff0a6 Tests: improvements to BLI_convexhull_2d_test
The convex hull tests included a reference AABB-fitting function for
comparison which was used to validate the optimized implementation.
This wasn't great as it depended on matching exact return values and
didn't test the logic of AABB-fitting worked usefully.

Replace this with a more general test that creates random polygons with
known bounds, apply a random rotation & translation, then use
AABB-fitting to un-rotate the points, passing when the bounds are no
larger than the size of the generated input.

Details:

- Make BLI_convexhull_aabb_fit_hull_2d a static function again as it was
  only exposed for tests. Use BLI_convexhull_aabb_fit_points_2d instead.
- Remove brute force reference implementation from tests,
  moving this to an assertion within convexhull_2d
  (disabled by default since it's quite slow).
2024-02-14 13:42:14 +11:00
Campbell Barton
d7dfbce288 code_clean: exclude BLI_strict_flags.h from removal
As this is only added to set strict warnings, cleaning logic would
remove as the compilers output is unchanged.

Support excluding headers from removal, others can be added if needed.
2024-02-14 13:40:33 +11:00
Campbell Barton
3f8cd44485 Cleanup: move BLI_strict_flags.h last, not that it should be kept last
Also add a note in the header why it should be kept last.
2024-02-14 13:40:31 +11:00