Commit Graph

125117 Commits

Author SHA1 Message Date
Joseph Eagar 136fcec288 Sculpt: Fix #108267: Broken face set undo
BKE_sculpt_face_sets_ensure now takes an Object
as an argument and updates the internal PBVH's
face sets pointer.
2023-06-14 20:21:50 -07:00
Kévin Dietrich f509c213d0 Merge remote-tracking branch 'origin/blender-v3.6-release' into main 2023-06-15 03:41:07 +02:00
Kévin Dietrich d2b741bebe Fix #107877: Alembic procedural crashes with point clouds
Somehow the implementation for the main function to load point clouds
data was missing although everything else to support point clouds was
there. Compilers were more than happy to convert the IPointsSchema to
another schema type for the compilation to succeed, and the crash
occurs because the points schema does not contain the same data as the
compiler's chosen schema (in this case an ICurvesSchema).

Another crash was found due to the radius array not being properly
initialized and left with a size of 0, when Cycles expects a full array.
2023-06-15 03:40:15 +02:00
Kévin Dietrich ae5fc2a7f8 Fix #105409: vertex interpolation corrupts Alembic mesh
The Alembic data streaming can optionally interpolate between vertex of
two adjacent frames in order to smooth out the transition between
frames.

However, the decision to interpolate is only based on the vertex count.
This is not too robust as topology/connectivity can still differ even if
the number of vertices is the same (for example physics simulations and
videogrammetry can be set to output the same vertex count, but optimize
the triangle placement). This lead to vertices of unrelated polygons
being interpolated across frames.

To fix this, we now also check if the connectivity across frames is the
same, instead of just checking the topology counters. Although the bug
is revealed by the vertex interpolation routine, a similar fix is applied
to the check on topology change used to decide if the modifier has to be
evaluated for orco evaluation.

Pull Request: #105867
2023-06-15 03:40:14 +02:00
Iliya Katueshenock 4be143193d Fix #108977: Propagate material from first point cloud by Join Geometry node
Until point clouds support multiple materials, just copy
the material from the first point cloud. This approach is the
same as for texture coordinate of meshes, active color attribute
of custom data, etc.

Pull Request: https://projects.blender.org/blender/blender/pulls/108990
2023-06-14 22:49:37 +02:00
Ray Molenkamp 3d6a99d2aa Merge remote-tracking branch 'origin/blender-v3.6-release' into main 2023-06-14 14:37:40 -06:00
Ray Molenkamp 977081d72b DepsBuilder: Update OIIO to include PSD fix
This fixes #108487 by applying upstream OIIO commit 8da473e254

This commit fixes the deps builder to include the patch, the actual
bug will not be fixed until the platform maintainers update the OIIO
library in SVN.
2023-06-14 14:36:22 -06:00
Anthony Roberts ee1b2f53cc Deps_builder: Move Windows build from MinGW/GCC to msys2/MSVC
Currently on Windows some dependencies are built with MinGW/GCC 3.x
this commit removes that, in favor of building them with MSVC
via msys2. This will make it easier in the future to offer Win/Arm64
builds of blender.

Notable changes:

- This change drops support for the external libxvid library in favor
of ffmpegs built in support for this format. This has been done with
permission from the VFX module.

Pull Request: https://projects.blender.org/blender/blender/pulls/108983
              https://projects.blender.org/blender/blender/pulls/105502
2023-06-14 21:57:48 +02:00
Hans Goudey 41f5ed970d Fix: Fix two small link drag search issues, small cleanup
The named attribute node gave connections from the "Exists" socket
to the new rotation socket type, and the sample volume node set its
type to unsupported values, causing a crash.
2023-06-14 15:42:06 -04:00
Hans Goudey 87a6b98875 Cleanup: Fix debug build error, geometry nodes test failure 2023-06-14 15:40:31 -04:00
Hans Goudey 1f0e206da6 Cleanup: Use nullptr, clang format 2023-06-14 14:55:44 -04:00
Hans Goudey e08ff54228 Cleanup: Move rna_space.c to C++
See #103343

Pull Request: https://projects.blender.org/blender/blender/pulls/108985
2023-06-14 20:52:51 +02:00
Hans Goudey 63dae2a105 Nodes: Add rotation socket type, support in many geometry nodes
Add a quaternion rotation socket type, and using the recently added
rotation attribute type, support the type in most of the multi-type
geometry nodes, and modifier attribute inputs and outputs.

The socket is still exposed with an XYZ Euler default value.
In the future we can add modes to this rotation value similar
to object rotations.

Rotation values have no implicit conversions to other types.
Nodes to convert to and from rotation values will be added
in a follow-up commit.

For now, the new socket type is hidden behind and experimental
option, because we haven't chosen the final color for it yet.

Pull Request: https://projects.blender.org/blender/blender/pulls/108903
2023-06-14 20:30:10 +02:00
Germano Cavalcante 9265fa1eed Cleanup: Split 'transform_snap_object.cc' into smaller files
This commit splits the `transform_snap_object.cc` file into 4 files:
- `transform_snap_object.hh`
- `transform_snap_object.cc`
- `transform_snap_object_editmesh.cc`
- `transform_snap_object_mesh.cc`

The `transform_snap_object.hh` header, in addition to sharing common
types, allows functions defined in each of these files to be shared
between them.

This makes the code easier to read and simplifies maintenance.

Pull Request: https://projects.blender.org/blender/blender/pulls/108949
2023-06-14 20:08:08 +02:00
Hans Goudey f98e488311 Cleanup: Silence unused parameter warning 2023-06-14 14:03:23 -04:00
Hans Goudey 68c6402666 Cleanup: Use C++ accessor for mesh position attribute 2023-06-14 12:37:52 -04:00
Hans Goudey a43c7997aa Cleanup: Remove unnecessary includes and declarations from mesh headers 2023-06-14 12:37:52 -04:00
Hans Goudey af53207b43 Cleanup: Remove unnecessary C wrappers for mesh evaluation functions 2023-06-14 12:37:52 -04:00
Hans Goudey 7826aed105 Cleanup: Use C++ accessors for mesh data 2023-06-14 12:37:52 -04:00
Hans Goudey f1d1caa44a Cleanup: Remove redundant copy of mesh fields
These are already copied by `BKE_mesh_nomain_to_mesh`.
2023-06-14 12:37:52 -04:00
Hans Goudey a45f09decd Cleanup: Clarify comment about ownership in meah header
The ownership of the result mesh isn't "unkown", that doesn't
really make sense. Also use "true" instead of "truth".
2023-06-14 12:37:52 -04:00
Hans Goudey 4e21db30bf Cleanup: Remove unused mesh function 2023-06-14 12:37:52 -04:00
Guillermo Venegas 43a0f22be2 Cleanup: Move space sequencer files to C++
See #103343

Pull Request: https://projects.blender.org/blender/blender/pulls/108959
2023-06-14 18:36:17 +02:00
Sergey Sharybin f96f310a9f Merge branch 'blender-v3.6-release' 2023-06-14 18:21:09 +02:00
Sergey Sharybin 3aaf076e8d Fix compilation error with oneAPI disabled and GPU Embree enabled
Happens with systems which do not provide GOLD linker: the linking state
would failing with some missing symbols and print about missing libsycl.so.6.

Seems that BFD linker expects to resolve all symbols, even the indirectly
used ones. This is somewhat counter-intuitive and is not how LLD, GOLD,
or MOLD worls.

The current state of the CMakeLists.txt does request the cycles_bvh to be
linked against SYCL_LIBRARIES. However, the SYCL was only requested to be found
if WITH_CYCLES_DEVICE_ONEAP is true.

Arguably the SYCL_LIBRARIES should only be linked-in into cycles_bvh if
EMBREE_STATIC_LIB, but that does not solve the issue with BFD.

This change makes it so the SYCL is requested to be found if the oneAPI
device is enabled, or if the Embree is detected to require/use SYCL
support.

Pull Request: https://projects.blender.org/blender/blender/pulls/108965
2023-06-14 18:20:45 +02:00
Sergey Sharybin 3806f3020b Merge branch 'blender-v3.6-release' 2023-06-14 18:11:55 +02:00
Sergey Sharybin fc440c4fa0 Fix monster performance benchmark run on Windows
The scene contains some interesting names, which requires to be
written as utf-8. And on Windows file descriptor is not guaranteed
to be using utf-8. Or, will error out if the invalid utf-8 sequence
is written.

This change makes it so running benchmarks on windows it fully successful.

Pull Request: https://projects.blender.org/blender/blender/pulls/108982
2023-06-14 18:11:22 +02:00
Lukas Tönne 8c2ad8bbd3 Nodes: Panel declarations for grouping sockets
Adds an optional list of panels to node trees. Each socket can be
assigned a panel. UI panels will be created in the future in the
modifier for these grouped sockets.

Panels are stored as a pointer array in node trees, next to socket
declarations. Each panel has a name, but it does not have to be unique.
In future a panel might also store whether it is visible by default and
similar information.

C API and RNA API are both added. Panels and their socket
assignments are accessible to users through another list in the "Group"
tab of the node editor sidebar.

Sockets in the same panel will remain together even when adding,
removing, or moving sockets or panels, renaming, etc.
A socket can be moved up or down within a panel but each panel
remains a contiguous block. Actual tree views may be created later.

Pull Request: https://projects.blender.org/blender/blender/pulls/108649
2023-06-14 18:02:40 +02:00
Brecht Van Lommel 8d457cb68f Merge branch 'blender-v3.6-release' into main 2023-06-14 17:16:32 +02:00
Brecht Van Lommel ea3cbf4942 Fix #108980: OpenEXR channels with unknown channel names fail to load
The example EXR is non-standard, but we may as well load the data anyway even
if we don't know the type of channels.
2023-06-14 17:15:30 +02:00
Germano Cavalcante 23f4fe4af1 Merge branch 'blender-v3.6-release' into main 2023-06-14 11:50:37 -03:00
Germano Cavalcante 5b39f39695 Clenaup: Remove unreferenced formal parameters
This silences warnings.
2023-06-14 11:45:46 -03:00
Jacques Lucke 2db1ab9245 Merge branch 'blender-v3.6-release' 2023-06-14 16:09:18 +02:00
Jacques Lucke ebd2c5fc27 Cleanup: change class to struct to avoid warnings 2023-06-14 16:08:46 +02:00
Campbell Barton ffdce441ee License headers: use SPDX-FileCopyrightText for source/
There are still some files that need to be manually updated due to
missing copyright dates.
2023-06-14 23:36:23 +10:00
Campbell Barton 8f109712ee License headers: use SPDX-FileCopyrightText for build_files/ & tools/ 2023-06-14 23:36:23 +10:00
Campbell Barton 49594c37ae License headers: use SPDX-FileCopyrightText for CMake files 2023-06-14 23:36:23 +10:00
Lukas Tönne f3dd63e25c Cleanup: Convert several RNA C files to C++
C++ RNA files for object, nodetree, and curves.

Pull Request: https://projects.blender.org/blender/blender/pulls/108934
2023-06-14 15:27:59 +02:00
Germano Cavalcante cfede90082 Merge branch 'blender-v3.6-release' into main 2023-06-14 10:27:36 -03:00
Germano Cavalcante c2ed9c39cd Fix #108958: Crash in edit mode when snapping is enabled
Caused by cad897de16

The crash happens because the `SnapData_EditMesh` is removed from the
map but still accessed afterwards.

However, after cad897de16, invalidating an object's unique snap date is
no longer required.
2023-06-14 10:25:34 -03:00
Clément Foucault cbfb9bcee4 EEVEE-Next: Fix wrong buffer location for sampling_buf
This created missing bind errors on some implementations.
2023-06-14 15:10:30 +02:00
Julian Eisel 8783038a38 Refactor: Remove asset library reference in node add menu code
The asset library reference isn't needed anymore for importing assets
since ccc9eef1b9. So it doesn't need to be set in the add menu context,
which simplifies code a bit.
2023-06-14 14:57:05 +02:00
Jacques Lucke 345d4087b7 Merge branch 'blender-v3.6-release' 2023-06-14 14:39:34 +02:00
Jacques Lucke f43dd04aac Fix: missing simulation cache allocation when creating new modifier 2023-06-14 14:39:10 +02:00
Jacques Lucke 3298c72ea2 Merge branch 'blender-v3.6-release' 2023-06-14 14:24:08 +02:00
Jacques Lucke 54e303a69c Fix #108720: allow discovering baked simulation data during rendering
Sometimes the modifier has never been evaluated by an active depsgraph
before it is used for rendering. In this case, the baked data was never
loaded. Now also allow checking for baked data in a non-active depsgraph.
The locking that is in-place already should probably already be enough
to make this thread-safe but maybe that could be made more explicit.
2023-06-14 14:23:13 +02:00
Jacques Lucke f1ce94d09e Merge branch 'blender-v3.6-release' 2023-06-14 14:14:38 +02:00
Jacques Lucke 7b61dcf6bc Geometry Nodes: deduplicate anonymous attribute analysis algorithm
Previously, there were two independent algorithms for analysing how anonymous
attributes are used in a node tree: One that just computed the `aal::RelationsInNode`
for an entire node tree and one that performed a more in depth analysis to
determine how far anonymous attributes should be propagated.

As it turns out, both operations can also be done at the same time and the result
can be cached on the node tree. This reduces the amount of code and allows for
better code reuse.

This simplification is likely only an intermediate step as things will probably have
to be refactored further to support e.g. serial loops (#108896).
2023-06-14 14:04:22 +02:00
Jacques Lucke 87643d173e Geometry Nodes: use shared_ptr for sharing simulation cache
With this the simulation cache pointer is copied over to the evaluated modifier.
This allows the original modifier to be removed without breaking the evaluated
modifier, which results in better decoupling. This can avoid issues when a
non-active depsgraph is evaluated in the background while the user is manipulating
the scene.

Also, it is now assumed that the simulation cache is always allocated even if
there is no simulation (similar to run-time data). This simplifies the code.

Pull Request: https://projects.blender.org/blender/blender/pulls/108976
2023-06-14 14:04:02 +02:00
Jacques Lucke b169469016 Geometry Nodes: crash when propagating attributes
Pull Request: https://projects.blender.org/blender/blender/pulls/108801
2023-06-14 13:59:38 +02:00