Commit Graph

133950 Commits

Author SHA1 Message Date
Hans Goudey
733f02407d Merge branch 'blender-v4.1-release' 2024-03-08 20:56:27 -05:00
Hans Goudey
7b25699333 Fix #119232: Crash on Generate Data Layers in DataTransfer modifier
"r_map" is null for the generate layers operator (rather than the modifier
evaluation). It should disable the creation of the "CD_NORMAL" layer too,
like the crease, bevel weight, sharp edge, and uv seam attributes above.
2024-03-08 20:55:43 -05:00
Harley Acheson
196cd48aad UI: Positioning of 3DView Sidebar Tab Titles
Improve the positioning of the tab titles in the 3D Viewport sidebar
by taking the Text Style size into consideration.

Pull Request: https://projects.blender.org/blender/blender/pulls/119231
2024-03-09 01:34:42 +01:00
Hans Goudey
2d3d8c80c3 Cleanup: Make format 2024-03-08 18:29:11 -05:00
Harley Acheson
f85989f5db UI: Adjust template_ID Buttons Width For Content Length
The Template_ID uses fixed widths for "new" and "open" buttons.
Although scaled by resolution scale, they do not take into account
language differences, Text Styles, etc and therefore frequently
overflow. This PR sets the buttons widths from the text size.

Pull Request: https://projects.blender.org/blender/blender/pulls/119229
2024-03-08 23:30:10 +01:00
Clément Foucault
b8e726a158 GPU: Add support for small types
This implement the design of #118961.

- Add aliases in GLSL since theses types are
  not supported.
- Add detection mechanism that prevents usage
  inside shader shared code.

Check is only done in debug build to avoid slowing down
application startup.

Pull Request: https://projects.blender.org/blender/blender/pulls/119226
2024-03-08 23:28:15 +01:00
Jesse Yurkovich
7ba8087ac8 Merge branch 'blender-v4.1-release' 2024-03-08 14:26:03 -08:00
Jesse Yurkovich
88b335aa0f Fix #98572: handle the 'mirror' texture wrap mode for USD materials
Support for the texture extension mode of "mirror" was simply missed
from `925fb66693d`.

With this patch, #98572 should be completely fixed.

Pull Request: https://projects.blender.org/blender/blender/pulls/118947
2024-03-08 23:23:58 +01:00
Brecht Van Lommel
2e8e2be0af Merge branch 'blender-v4.1-release' 2024-03-08 22:55:42 +01:00
Brecht Van Lommel
9bebd39197 Cycles: Default to OIDN for NVIDIA in the viewport
For consistency across GPU devices, and between viewport and final
render.

Pull Request: https://projects.blender.org/blender/blender/pulls/119213
2024-03-08 22:52:36 +01:00
Brecht Van Lommel
f278e4138c Fix #118016: OpenImageDenoise not using GPU for CPU + GPU render
Thanks to Alaska for pointing out the cause of the problem.
2024-03-08 22:52:35 +01:00
Hans Goudey
04a9790035 Merge branch 'blender-v4.1-release' 2024-03-08 16:35:33 -05:00
Hans Goudey
c4bf2d43e7 Fix #116395: Auto smooth versioning modifier added unnecessarily
As mentioned in new code comments, the auto smooth behavior in 4.0 was
to skip sharp angle tagging when the evaluated mesh had custom normals.
There was already a check for custom normals on the original mesh (we
can't access the evaluated mesh from versioning code). But that didn't
handle cases where custom normals were created by modifiers (the normal
edit and weighted normal modifiers). Now skip adding the new modifier
when those modifiers come last in the stack. Alternatively we could
check if they existed in the stack at all, but that seems a bit more
risky.
2024-03-08 16:09:05 -05:00
Harley Acheson
85762d99ef UI: Allow Some Buttons to Scale Width With Text Style
Allow some View3D buttons to change their width according to content
and Text Styles, rather than be fixed amount of UI_UNIT_X. Examples
include "Object Mode", "Transform Orientation", "Grease Pencil Layers",
"Texture Slots", "Vertex Groups", "Attribute", etc.

Pull Request: https://projects.blender.org/blender/blender/pulls/119223
2024-03-08 21:49:56 +01:00
Harley Acheson
4dd11c458a UI: Adjust template_ID String Length for Pin Icon
Fix text overflow in Scene selector. This Template_ID uses a "pin" icon
which will cause the name to clip at some sizes.  Also decreases the
minimum width because of this fix.

Pull Request: https://projects.blender.org/blender/blender/pulls/119227
2024-03-08 21:49:12 +01:00
Germano Cavalcante
e55ab09f86 Fix #89289: crash transforming after altering loops/faces count in script
Transform operators for mesh do partial updates and don't reallocate
the looptris arrays that may be incorrectly sized. Therefore, we must
check the array size before performing updates.
2024-03-08 16:42:51 -03:00
Clément Foucault
4205718dce GPU: Cleanup type aliases
This define all aliases for supported types,
document which one to use in C++ shared code,
move relevant defines to their backend file.

Rename `bool1` to `bool32_t` and cleanup
its usage as mentioned in #118961.

Rel. #118961

Pull Request: https://projects.blender.org/blender/blender/pulls/119098
2024-03-08 19:09:10 +01:00
Jacques Lucke
1cca960677 Fix #103985: crash when using viewer node on curves with gpu subdivisions
The `cache.curves_cache.proc_attributes_buf[i]` is independent of the subdivision level.
Therefore it's not freed when the subdivision level changes currently. However, the
check assumed that when no attribute was changed, the final subdivided buffer is
non-zero, which is not true when the subdivision level changed.

Now directly check whether the attribute is cached already.

Pull Request: https://projects.blender.org/blender/blender/pulls/119216
2024-03-08 18:33:35 +01:00
Ray Molenkamp
850b89ba51 deps_builder: fix URI for the blender mirror of the source packages
This was still using the SVN repository, which isn't used any more
since the migration to git lfs.
2024-03-08 10:01:44 -07:00
Hans Goudey
fbaf6219eb Cleanup: Return catmull rom basis weights by value 2024-03-08 11:51:10 -05:00
Hans Goudey
01941e2b50 Geometry Nodes: Use boolean type for "use attribute" inputs
When the "use_attribute" properties were added, boolean IDProperties
didn't exist. Then we didn't change it for a while because of forward
compatibility concerns. But currently we always convert boolean
properties to integer properties when saving anyway (since
2ea47e0def, so there is no issue with compatibility.
Using booleans makes working with the properties in the Python API
a bit friendlier.

Pull Request: https://projects.blender.org/blender/blender/pulls/119129
2024-03-08 17:49:09 +01:00
Bastien Montagne
581f1b96cf GPv3: Fix missing Custom Properties panel for new GreasePencil ObData.
Fairly simple fix, for once. :)
2024-03-08 17:27:49 +01:00
Ray Molenkamp
940fed49e0 Windows_Libs: OSL 1.13.7, OIDN 2.2.1 2024-03-08 09:14:05 -07:00
Jörg Müller
91eb50ec2f Audaspace: Bugfix for PulseAudio ported from upstream. 2024-03-08 17:02:26 +01:00
Germano Cavalcante
930b11b0fe Fix: Edge Slide sometimes slides edge in wrong direction
Caused by 7f1b70ac50.

The test to find the best direction did not work for boundary edges.
2024-03-08 12:53:41 -03:00
Hans Goudey
456c34da1a Cleanup: Use higher level APIs for "set attribute" geometry nodes
Similar changes to a2726a3d7f
Also tweak variable names and the access of geometry set grease pencil data.
2024-03-08 10:50:42 -05:00
Brecht Van Lommel
898187cfab Fix #118466: Cycles renders black on Metal + AMD
Global built-ins appear to not work on AMD cards.

Also add a tweak to avoid a performance regression, similar
to what was done before. Disable adaptive subdivision kernel
code if not used.

Pull Request: https://projects.blender.org/blender/blender/pulls/119175
2024-03-08 16:41:27 +01:00
Germano Cavalcante
d1bcc0306e Cleanup: use more descriptive names for variables
And follow convection for comments.
2024-03-08 12:09:03 -03:00
Germano Cavalcante
1ce73b6bce Cleanup: use 'r_' prefix for output parameters, order last
Also use const arguments.
2024-03-08 12:07:32 -03:00
Hans Goudey
1050d6147f Cleanup: Remove unnecessary C wrappers for UI view classes 2024-03-08 09:16:07 -05:00
Christoph Lendenfeld
e07e983fc1 Fix: Memory leak when inserting keyframes with NLA offset
Introduced with #118957

When calling `BKE_animsys_get_nla_keyframing_context`
the function allocates memory, which needs to be freed later.
This was missed.

Pull Request: https://projects.blender.org/blender/blender/pulls/119208
2024-03-08 14:42:35 +01:00
megakite
8f120749dd Fix #119021: Crash when adding GP object
Added a null check for RE_GetRenderLayer() which could possibly return
null and then stored in `render_layer`, in order to prevent members of
`render_layer` being accessed in RE_pass_find_by_name(), and thus solved
the segmentation fault.

Pull Request: https://projects.blender.org/blender/blender/pulls/119200
2024-03-08 14:28:05 +01:00
YimingWu
6ed4282771 GPencil: Remove subdiv modifier unused vgroup UI
The UI was erroneously added initially for the stroke filter, now
removed.
2024-03-08 20:19:46 +08:00
Pratik Borhade
7e3abdf503 Merge branch 'blender-v4.1-release' 2024-03-08 16:56:20 +05:30
Pratik Borhade
2191cbf7f5 Fix #119106: Set Action in outliner does not update the animation
This is due to the missing depsgraph update

Pull Request: https://projects.blender.org/blender/blender/pulls/119112
2024-03-08 12:24:03 +01:00
Pratik Borhade
021565d867 Fix #119142: Skip linking collection inside another linked collection
When linking a collection from library, it can be linked inside another
linked/overrided collection if it is selected in outliner. This can be
prevented by linking with editable parent collection.

Pull Request: https://projects.blender.org/blender/blender/pulls/119144
2024-03-08 12:23:19 +01:00
Jacques Lucke
f9abbeca09 Fix: exception in poll function of some node operators 2024-03-08 11:58:47 +01:00
Campbell Barton
eabff7334d Merge branch 'blender-v4.1-release' 2024-03-08 20:58:33 +11:00
Campbell Barton
738c1b6ca9 Docs: correct typo & terms in --help text 2024-03-08 20:57:56 +11:00
Omar Emara
f25983f69b Merge branch 'blender-v4.1-release' 2024-03-08 11:57:37 +02:00
Omar Emara
8cf8b54332 Fix: Viewport Compositor depth has low precision
The depth pass of the Viewport Compositor has low precision if the
precision of the node tree is set to Auto. To fix this, we always
expose the depth pass in full precision.
2024-03-08 11:55:23 +02:00
Christoph Lendenfeld
57419c9653 Refactor: keyframing functions return more detailed status
The keyframing functions up to this point created many
messages through the `ReportList` about what went wrong
when inserting keys.

This has 2 issues:
* Everyone that wants to insert keyframes needs to have
a `ReportList` which comes from `bContext`
* The keyframing functions are very verbose.
Providing the user with errors when there is actually nothing wrong.

To combat that, return a status enum from functions that deal
with a single FCurve.
Functions that deal with more than one FCurve collect those statuses
into a new class `CombinedKeyingResult`
Based on that we can create a single well worded error message,
instead of potentially flooding the user with individual messages.

The downside is that some info is lost, e.g. we do not
know which exact FCurve has failed.

This will show a formatted error when inserting keys with a keying
set or when pressing `I` over the property to keyframe.
But not when pressing `I` in the viewport. The latter can be fixed in a later patch.

Pull Request: https://projects.blender.org/blender/blender/pulls/117449
2024-03-08 09:56:40 +01:00
Omar Emara
a444a5eeba Fix: Byte interpolation with clamped boundary returns zero
The byte BLI image interpolation function with clamped boundary returns
zero for out of bound pixels. This is the same as #119164, but for byte
interpolation.

Pull Request: https://projects.blender.org/blender/blender/pulls/119173
2024-03-08 07:50:01 +01:00
Campbell Barton
f3e0e39df5 Cleanup: use const pointers where camera data isn't modified 2024-03-08 17:15:08 +11:00
Campbell Barton
8cbb57ee0a CLI: suppress noisy prints when running commands
Messages such as "Blender quit" get in the way of custom commands,
add G.quiet to suppress noisy "info" prints.
2024-03-08 13:27:29 +11:00
Campbell Barton
75b6dbd132 WM: move prints for loading startup & preferences to logging
Now messages for loading the preferences are logged instead of printed,
with additional logging for the startup file.
Access with the argument --log "wm.files"

Custom command-line actions would print that the preferences were
loading which distracts from the commands output.

Regular blend files loading still prints a message.
2024-03-08 13:27:27 +11:00
Campbell Barton
20b5908af8 Docs: reference G & U from Global & UserDef doc-strings
Include some context for how these structs are used as it's not so
clear where values are set/initialized.
2024-03-08 13:26:07 +11:00
Campbell Barton
8dd049d569 Cleanup: clarify argument names for passing a file buffer
Prefer the term size over length for size in bytes.
2024-03-08 12:57:34 +11:00
Campbell Barton
ba3c9e1661 Cleanup: de-duplicate logic for setting background mode 2024-03-08 12:57:34 +11:00
Jesse Yurkovich
e07081e15b USD: Fix cyclic bezier curve export
During work on GeometrySet import it was discovered that periodic
(cyclic) bezier curves do not need their first control point repeated
in the actual scene description.

The USD API documentation was a bit unclear on this aspect but this has
been confirmed informally on the AOUSD forum and emperically using
another implementation.

This patch removes the duplicated start point during export.

Pull Request: https://projects.blender.org/blender/blender/pulls/119185
2024-03-08 02:18:15 +01:00