Commit Graph

129380 Commits

Author SHA1 Message Date
Hans Goudey 4ae4e25dc2 Merge branch 'blender-v4.0-release' 2023-10-17 09:25:51 +02:00
Hans Goudey 3d236bc858 Mesh: Add operator to select elements based on boolean attribute
Adds a "Select by Attribute" operator as mentioned in the discussion in
#105317. This is done in 4.0 to limit the breaking aspect of the removal
of face maps. The selection storage functionality is replaced by boolean
attributes. We already have a way to control the data in the boolean
attribute with the "Set Attribute" operator, but we didn't have a way to
convert the attribute into a selection.

This operator works on the active attribute if is a boolean attribute
and isn't on the face corner domain. It adds to the existing selection
similar to other existing operators.

While this behavior can be recreated as a node tool, we add it as a
builtin operator here to avoid limitations of the new node-based
tool system and to make the late-in-the-release-cycle change safer.

Pull Request: https://projects.blender.org/blender/blender/pulls/113772
2023-10-17 09:24:51 +02:00
Hans Goudey 820f0c24c4 Mesh: Add versioning to convert old face maps to boolean attributes
See #105317

In 46cf093270, face maps were just converted to an integer
attribute. While the internal data remains the same that way, we lose
the names and some convenient methods of interaction. This commit
additionally converts each face map to a separate boolean attribute
using the old name. This does require that no attributes were using that
name already.

Each boolean attribute can be thought of as a selection, accessible in
geometry nodes and properly interpolated by mesh processing
algorithms. The selections no longer have to be unique, meaning
one face can be part of multiple selections.

Pull Request: https://projects.blender.org/blender/blender/pulls/113769
2023-10-17 09:17:07 +02:00
Campbell Barton a89686240e Build: unbreak WITH_UNITY_BUILD=OFF 2023-10-17 16:11:04 +11:00
Campbell Barton 768dedbe5a Cleanup: reserve 'mval' for region-relative pointer coordinates 2023-10-17 12:57:00 +11:00
Germano Cavalcante f20e38d422 Merge branch 'blender-v4.0-release' into main 2023-10-16 17:26:32 -03:00
Germano Cavalcante bbf87ee78c Fix #113786: Snapping to vertex is broken, when instances are used in GN
Missed in ff4f14b21.

For GN instances, we should use `DupliObject::ob_data`.
2023-10-16 17:26:02 -03:00
Dalai Felinto dd8d3ec27b GPv3: Convex Hull node
We create one convex hull per layer, following what we do for instances.

This is covered as part of the design in #113602, and as such not
commented on the code itself.

Part of #113602.

Pull Request: https://projects.blender.org/blender/blender/pulls/113788
2023-10-16 22:16:34 +02:00
Brecht Van Lommel 4fe903bef7 Merge branch 'blender-v4.0-release' into main 2023-10-16 20:10:09 +02:00
Brecht Van Lommel 0c958129a3 Fix deps build issues with Ogg/Vorbis on new Xcode, switch to CMake
These were already building with CMake on Windows, do the same for
Linux on macOS.
2023-10-16 20:09:41 +02:00
Brecht Van Lommel 4a376326c9 Fix OpenImageIO wrong dependency builder hash after repository moved
And update to new URL.
2023-10-16 20:09:41 +02:00
Hans Goudey 57c27b47b9 Cleanup: Avoid unnecessary check for empty curves
In `CurvesGeometry`, curves should never be empty. We shouldn't have
to check for that in the drawing code.
2023-10-16 19:51:12 +02:00
Hans Goudey 2528b6da9b Cleanup: Use const in grease pencil drawing code 2023-10-16 19:51:12 +02:00
Iliya Katueshenock fb57767f78 Cleanup: simplify extracting GField from geometry nodes parameters
Pull Request: https://projects.blender.org/blender/blender/pulls/113743
2023-10-16 19:19:53 +02:00
Harley Acheson d0e6f894fe Merge branch 'blender-v4.0-release' 2023-10-16 10:18:41 -07:00
Harley Acheson ffe980afad Fix #113766: Incorrect Cursor With Offset Position
Next character left edge position incorrect when string has
an offset positioning (scrolled within the input box).

Pull Request: https://projects.blender.org/blender/blender/pulls/113784
2023-10-16 19:17:28 +02:00
Jacques Lucke 006380aaca Cleanup: deduplicate field socket type check 2023-10-16 19:13:27 +02:00
Sergey Sharybin f8ee27c88b Sculpt: Preserve edge attribute on split with dyntopo
Copy custom data and flag from the original edge to the ones created
from it when splitting a long edge.

Unfortunately, can not use generic "example" edge approach as there
is a temporary flag BM_ELEM_TAG is re-applied in a loop: the new
edges can not be tagged with this tag. Additional complication is
that even we clear this tag from the input edge before splitting it
this tag is re=applied via long_edge_queue_face_add().

Hence, use our own simple function to copy minimal subset of data and
tags.

Co-Authored-By: Hans Goudey <hans@blender.org>

Pull Request: https://projects.blender.org/blender/blender/pulls/113783
2023-10-16 19:12:10 +02:00
Sergey Sharybin a19a36c631 Cleanup: More proper C++ usage in PBVH edge split
- More consistent naming of variables in diagram and code.
- Use C++ array and span, and make them short-lived, without
  trying to reuse them.

Co-Authored-By: Hans Goudey <hans@blender.org>
2023-10-16 19:12:08 +02:00
Sergey Sharybin 529392bb2c Cleanup: Const-correctness in bmesh code
Only handful of functions which are needed for the PBVH edge split.

Co-Authored-By: Hans Goudey <hans@blender.org>
2023-10-16 19:12:08 +02:00
Iliya Katueshenock bd6db0acea Cleanup: Nodes: unify data type conversion functions
Pull Request: https://projects.blender.org/blender/blender/pulls/113744
2023-10-16 19:09:07 +02:00
Jacques Lucke b47372356d Cleanup: remove now unused CustomDataAttributes
This is not used anymore, because there are better alternatives:
* Higher level `AttributeAccessor` interface.
* Lower level `CustomData` interface.
2023-10-16 18:44:48 +02:00
Jacques Lucke ff4d5b6f04 Geometry Nodes: don't use CustomDataAttributes in Instances
This was the last use of `CustomDataAttributes`. It's not very useful
nowadays because we have a lower level (`CustomData`) and higher level
(`AttributeAccessor`) API.

As part of this I removed the ability to `reserve` instances which was
useful when adding instances one by one. Generally, such code should
eventually be rewritten to handle more instances at once, instead of
handling them one by one. This will lead to better performance and
is more in line with how other geometry types (like mesh) are handled.

This also adds the ability to move and assign `Instances` just like we can
move and assign `CurvesGeometry`.
2023-10-16 18:41:32 +02:00
Omar Emara cea5ea4096 Fix #113768: GPU compositor is leaking memory
The experimental GPU compositor is leaking memory in any setup.

This is because the current implementation of the render texture pool
always created a new texture and only freed the textures upon deletion.
This was a temporary implementation until a proper implementation that
uses the DRW textures pool was used.

This patch implements a small texture pool as a temporary fix until the
aforementioned DRW texture pool implementation is done.
2023-10-16 19:31:06 +03:00
Dalai Felinto 0dcf92f945 GPv3: Fix Curve to Mesh node replacing instances
The code is already replacing instances when needed (when there was no
instances previously created in the file). To do it regardless may lead
to remove instances from the loop.

The other related nodes did not have that issue:
* Curve to Points
* Curve Fill
2023-10-16 17:33:30 +02:00
Clément Foucault 5831913204 Fix EEVEE-Next: SubSurfaceScattering: Invalid buffer format
This fixes issues on NVidia GPUs.
2023-10-16 17:17:18 +02:00
Clément Foucault 69e85382cd Fix #113759: EEVEE-Next: NaN artifacts caused by raytracing denoising
This was caused by spatial denoising pass sampling invalid data.
This patch make it so that there is one padding tile all
around the denoise area.

This simplifies the denoise shader too.

This is a bit wasteful to dispatch tracing tiles for clearing
and a better solution would be to use a separate shader and
tile list only for this purpose.
2023-10-16 17:17:18 +02:00
Germano Cavalcante dae06c7562 Merge branch 'blender-v4.0-release' into main 2023-10-16 11:48:02 -03:00
Germano Cavalcante 88a6df24aa Fix #113552: NLA Markers do not reset when length reaches 0.0
Before bd00324c26, strip lengths were changed in
`rna_NlaStrip_frame_start_ui_set` and `rna_NlaStrip_frame_end_ui_set`
so as not to be shorter than NLASTRIP_MIN_LEN_THRESH.

This prevented `BKE_nlameta_flush_transforms` from working with
zero-length strips.

But now, in some cases, strip can be zero length.

Therefore, consider this case and avoid division by zero.

Pull Request: https://projects.blender.org/blender/blender/pulls/110121
2023-10-16 16:46:47 +02:00
Jacques Lucke 5f80242bc2 Cleanup: use CustomDataAttributes from Instances interface
It's still used internally currently. `CustomDataAttributes` will be removed
soon because there are better alternatives (`AttributeAccessor`).
2023-10-16 16:39:39 +02:00
Jacques Lucke d0342b1782 Cleanup: don't use CustomDataAttributes when realizing instances
`CustomDataAttributes` does not serve much of a purpose nowadays,
since we usually use either the lower level `CustomData` or the higher
level `AttributeAccessor` interface.
2023-10-16 16:27:33 +02:00
Peng Yan 640b0dd6da Cleanup: Remove redundant flag setting in RNA_def_property
In switch-case structure, `PROP_NEVER_NULL` is already set
for String properties. However, the code setting `PROP_EDITABLE`
below was overwriting the flag. Then `PROP_NEVER_NULL` had
to be set for a second time.

Fixed by using proper API function to set these flags, and removed
the redundant second flag setting.

Pull Request: https://projects.blender.org/blender/blender/pulls/113739
2023-10-16 16:09:33 +02:00
Thomas Dinges 6479ba4bad New splash screen for the main development branch
by Blender Studio https://studio.blender.org/wing-it
2023-10-16 16:05:48 +02:00
Germano Cavalcante 47867549e8 Merge branch 'blender-v4.0-release' into main 2023-10-16 10:40:08 -03:00
Germano Cavalcante 6dda18269c Fix #113650: Vertex Creasing is using Mirror
`Vertex Crease`, like `Edge Crease`, is not supposed to use transform
symmetry.

So remove it.

(`Skin Resize` remains using symmetry since that case seems desirable.
See #84376)
2023-10-16 10:39:31 -03:00
Falk David 97c5cb19d1 GPv3: Hide points overlay in stroke selection mode
This makes sure that we only show the point selection if the
selection domain is `ATTR_DOMAIN_POINT`.
2023-10-16 15:12:10 +02:00
Damien Picard 9c0c9789cc I18n: fix Vector Math and Mix node sockets search
When searching for a new node by dragging from a socket, some results
were untranslated. This is because they did not use a translation
context matching other occurrences, from which the strings were
extracted to the translation files.

Three nodes using operations were affected: Mix and Vector Math.
- Vector Math used the default context when it should have used
  NodeTree.
- Mix and Mix RGB used NodeTree when they should have used the default
  context.

Pull Request: https://projects.blender.org/blender/blender/pulls/113485
2023-10-16 14:45:47 +02:00
Pratik Borhade d03d03402b GPv3: Fix problems related to insert/delete keys in edit mode
Send notifiers to redraw dopesheet when keyframe is inserted/deleted.
Change default duration (and soft/hard min) to 0 for inserting
keyframe. This unnecessarily adds extra keyframe.

Pull Request: https://projects.blender.org/blender/blender/pulls/113765
2023-10-16 14:15:46 +02:00
casey bianco-davis 0508e81b79 GPv3: Add edit mode lines to overlay
Adds lines in edit mode to the overlay.

Pull Request: https://projects.blender.org/blender/blender/pulls/111596
2023-10-16 13:59:26 +02:00
Miguel Pozo 54511f59aa Merge branch 'blender-v4.0-release' 2023-10-16 13:49:44 +02:00
Miguel Pozo e3014ffc27 Fix #113741: Workbench: Reset TAA on overlay toggle
Reset TAA when enabling overlays,
since we won't have valid sample0 depth textures.
2023-10-16 13:49:12 +02:00
Miguel Pozo 465291e716 Merge branch 'blender-v4.0-release' 2023-10-16 13:25:05 +02:00
Miguel Pozo f2ba12a053 Fix: Workbench: Volume compositing
Regression after fe39456ba5
2023-10-16 13:24:35 +02:00
Thomas Dinges fc21513709 Merge branch 'blender-v4.0-release' 2023-10-16 12:33:22 +02:00
Thomas Dinges 1f0520034a Revert "Fix #113201: Assets in same folder as current file ignored in All library"
This reverts commit 7705e49bcd.

It broke the bf_asset_system_tests test and this cannot be fixed now so reverting.
2023-10-16 12:32:42 +02:00
Thomas Dinges 6a6308a07a Revert "Fix #113201: Assets in same folder as current file ignored in All library"
This reverts commit 7705e49bcd.

It broke the bf_asset_system_tests test and this cannot be fixed now so reverting.
2023-10-16 11:49:53 +02:00
Bastien Montagne 764ce8ce86 Merge branch 'blender-v4.0-release' 2023-10-16 11:36:47 +02:00
Dalai Felinto 9c22af32a9 Cleanup: Remove unecesary includes 2023-10-16 11:30:22 +02:00
Dalai Felinto 47cfeb45d8 GPv3: Delete Geometry node
Incorporated the cleanup and tweaks from Hans Goudey to return CurvesGeometry directly.

Part of #113602.

Co-authored-by: Hans Goudey <hans@blender.org>
Ref !113721
2023-10-16 11:29:07 +02:00
Bastien Montagne 8220820611 I18N: Updated UI translations from git/weblate (61c02b1e7f0506c). 2023-10-16 11:19:35 +02:00