Commit Graph

138240 Commits

Author SHA1 Message Date
Campbell Barton
cb68d0c9d7 Merge branch 'blender-v4.2-release' 2024-06-27 22:28:57 +10:00
Andrej730
1553a75fed Fix regression installing an addon by drag'n'drop
Regression in [0].

Ref: !123832

[0]: fcba8b8099ca5dd7989eed81b97d4353ee1ee72b
2024-06-27 22:26:32 +10:00
Falk David
84e5de3327 Fix: GPv3: Crash in grease_pencil_object_cache_populate
This was due to wrong indexing into `num_triangles_per_stroke` and
`num_vertices_per_stroke`. We were using the the index of the stroke
in the drawing instead of the index into the `visible_strokes` mask.
2024-06-27 13:54:05 +02:00
Campbell Barton
8e2cbdc876 Merge branch 'blender-v4.2-release' 2024-06-27 21:41:03 +10:00
Campbell Barton
c3d18854f3 Cleanup: avoid unnecessary separator
The extensions UI was aligning all buttons then adding a separator.
Simplify the layout by removing align which removes the need for an
explicit separator.
2024-06-27 21:35:23 +10:00
Omar Emara
6f06e2258f Image: Clarify color depth tooltip for EXR images
Clarify the tooltip for the half float color depth property for EXR
images to indicate that it doesn't affected data passes and that they
will still be saved as full float.
2024-06-27 14:29:44 +03:00
Campbell Barton
f1bfaaf2f7 Merge branch 'blender-v4.2-release' 2024-06-27 21:26:23 +10:00
Campbell Barton
fb94028d10 Merge branch 'blender-v4.2-release' 2024-06-27 21:26:21 +10:00
Jeroen Bakker
e9cba0e588 Fix #123670: EEVEE: Add support for new grease pencil type
EEVEE didn't support the new grease pencil object type. Which would
not output the depth texture when overlays where turned off.

Pull Request: https://projects.blender.org/blender/blender/pulls/123816
2024-06-27 13:24:37 +02:00
Campbell Barton
42e1239ba8 Core: support restricting the types an XML preset may load
Prevent potential problems from untrusted XML (typically themes)
traversing into data outside the intended targets.

From what I can tell it's not currently possible but changes to RNA
could allow for this which would likely go by unnoticed.

Further details in code-comments.
2024-06-27 21:21:07 +10:00
Campbell Barton
65d0f365a9 Cleanup: correct misleading name of internal function 2024-06-27 21:01:15 +10:00
Sergey Sharybin
cb9060ede6 Merge branch 'blender-v4.2-release' 2024-06-27 12:48:26 +02:00
Sergey Sharybin
2dc4bd3cdf Fix: PSD images are read wrong
The original report on Blender is is #123218, this commit takes care of
fixing it for macOS by updating the OpenImageIO libraries.

Ref #123218
Ref #118455

Pull Request: https://projects.blender.org/blender/blender/pulls/123826
2024-06-27 12:47:39 +02:00
Bastien Montagne
6aa6aee2d5 Reapply "Fix (unreported) Assets: MEM_new/MEM_freeN mismatch usages."
This reverts commit cb76781be74320e2883b66de053dcb97e79ea169, and fixes
the issues from original da05bff96c2209 commit (missing initialization
of a pointer in copy constructor in some cases, and forgot to handle
one allocated string in the move constructor).

Many thanks to @julianeisel for finding the actual issues here.
2024-06-27 12:20:49 +02:00
Dalai Felinto
c6e452d865 UI: Extensions: Add a separator between Install and the "⌄" button
It was too easy to click on Install by mistake, while trying to click on
the "⌄" menu. This is particulary problematic since we enable add-ons by
default.

Co-authored by: Pablo Vazquez, based on (informal) report by Campbell Barton.
2024-06-27 12:06:53 +02:00
Brecht Van Lommel
6320066a88 Merge branch 'blender-v4.2-release' 2024-06-27 11:50:34 +02:00
Brecht Van Lommel
b802f146e6 Tools: Move warning about wrong clang-format version to the bottom
So it doesn't scroll off screen and is easy to miss.
2024-06-27 11:49:00 +02:00
Bastien Montagne
cb76781be7 Revert "Fix (unreported) Assets: MEM_new/MEM_freeN mismatch usages."
This commit causes crashes when opening a second blendfile (attempt to
free already freed data).

This reverts commit da05bff96c2209c9acd3fa3255ed001198d00cc3.
2024-06-27 11:05:48 +02:00
Philipp Oeser
77f874ae1d Fix #123782: Asset Browser does not show tags for active asset
Caused by a6ed013baa20

Tags live on the `AssetMetaData` of an `AssetRepresentation` (so
`metadata` in py),
`asset_data`(also pointing to `AssetMetaData`) is a member of
`FileSelectEntry` only [which the above commit tried to get rid off...]

Pull Request: https://projects.blender.org/blender/blender/pulls/123818
2024-06-27 10:57:33 +02:00
Bastien Montagne
da05bff96c Fix (unreported) Assets: MEM_new/MEM_freeN mismatch usages.
This one was a bit more involved than the previous ones, since the
mismatch was intentional here, and happened on a non-trivial type.

It was done because the new object (managed by the `unique_ptr`) steals
the internal data of the original object. Calling `MEM_delete` (and
therefore the destructor of the `AssetMetaData` object) would then lead
to access-after-free and double-freeing errors.

This is addressed by adding two new 'copy' and 'move' constructors to this type.

The copy one ensures that deep-copy of internal data happens as expected, and
allows to simplify greatly the code in `BKE_asset_metadata_copy`, which
becomes a mere wrapper around it.

The move one allows `make_unique` to properly steal (and clear) the internal
data of the source object, which can then safely be deleted.

Pull Request: https://projects.blender.org/blender/blender/pulls/123693
2024-06-27 09:44:22 +02:00
Campbell Barton
f43cf39689 Merge branch 'blender-v4.2-release' 2024-06-27 14:43:39 +10:00
Campbell Barton
989de85cf6 Extensions: fixed & refactor internals for extension visibility
Add utility class to check extension visibility to remove
incomplete logic that was duplicated into operator code.
Also minor refactoring to reduce the number of arguments passed
to internal function.s
2024-06-27 14:33:47 +10:00
Sean Kim
99c75beabf Cleanup: Silence unused variable warning
Pull Request: https://projects.blender.org/blender/blender/pulls/123806
2024-06-27 04:43:19 +02:00
Sean Kim
11d0a9db1b Fix: Build error from missing change in recent commit
Pull Request: https://projects.blender.org/blender/blender/pulls/123805
2024-06-27 04:36:09 +02:00
Sean Kim
1a392104c3 Cleanup: Sculpt: Add BLI_NOINLINE to mask.cc helper methods
Pull Request: https://projects.blender.org/blender/blender/pulls/123804
2024-06-27 04:18:21 +02:00
Sean Kim
0bc7631693 Sculpt: Initial data-oriented refactor for clay brush
Part of #118145.

Performance after this change results in an 119% speedup. This is
measured on the fucntion `stroke_update_step` on a mesh with 24k verts
across 5k instances of the function being timed. In absolute values,
this represents a 0.06ms speedup, from 0.38ms to 0.32ms.

Pull Request: https://projects.blender.org/blender/blender/pulls/123751
2024-06-27 04:07:10 +02:00
Sean Kim
6b7255b978 Refactor: Sculpt: Use return value instead of reference for orig_data
Pull Request: https://projects.blender.org/blender/blender/pulls/123755
2024-06-27 01:42:14 +02:00
Harley Acheson
eed83b56d2 UI: Calm Warnings With New Icons
Just calming warning with unused argument and
missing switch default.

Pull Request: https://projects.blender.org/blender/blender/pulls/123802
2024-06-27 01:35:45 +02:00
Sean Kim
9d4d1aea98 Sculpt: Add stroke stabilization to lasso tools
This PR adds stroke stabilization settings for the Sculpt mode lasso
tools:
* Mask
* Hide
* Trim
* Face Set

Only Sculpt tools have a user facing change, even though this was
implemented in `WM_gesture_lasso_modal` and related methods. Other
modes may choose to add these settings and toggles.

## Implementation
The implemented functionality is similar to the Annotate tool in both
interpolation of the new point and drawing the UI hint that
stabilization is happening.

The `radius` and `factor` properties have similar bounds as the same
Brush properties. All values are stored on a per-operator level, not on
a scene or otherwise global tool level.

Based off of [1].

[1] - https://blender.community/c/rightclickselect/ZWG5/

Pull Request: https://projects.blender.org/blender/blender/pulls/122062
2024-06-27 01:32:09 +02:00
Harley Acheson
8da3b74ee2 Cleanup: Remove Unneeded Old Icon-Related Files
Remove some unused icon-related files. alert_icons.*, blender_logo.png,
prvicons.*

Pull Request: https://projects.blender.org/blender/blender/pulls/123799
2024-06-27 01:18:13 +02:00
Hans Goudey
4d29e1dccb Refactor: Sculpt: Remove some constants from PBVH
The aim is to simpliofy the construction of a PBVH and to reduce
the breadth of its responsibilities.
2024-06-26 17:17:01 -04:00
Hans Goudey
c365daaedb Cleanup: Sculpt: Remove another unused PBVH variable 2024-06-26 16:53:49 -04:00
Hans Goudey
d3d9be486b Cleanup: Sculpt: Remove unused PBVH draw cache status variables 2024-06-26 16:47:32 -04:00
Harley Acheson
b7256b1ea7 UI: Use SVG Icon for Logo in Splash About
Use new SVG icon the "Blender" logo shown on the About screen. Allows
removal of blender_logo.png and no need for 1024x256 bitmap. Instead it
is made at exact requested size. This PR updates blender_logo_large.svg
because the (R) in it is not a stroke or path, but actual text - not
rasterized by Nano.

Pull Request: https://projects.blender.org/blender/blender/pulls/123790
2024-06-26 22:43:59 +02:00
Brecht Van Lommel
3072e6f518 Merge branch 'blender-v4.2-release' 2024-06-26 21:30:39 +02:00
Brecht Van Lommel
4e4d8476c4 Tools: Remove cycles commit syncs script, moved to the standalone repo
Pull Request: https://projects.blender.org/blender/blender/pulls/123788
2024-06-26 21:30:00 +02:00
Brecht Van Lommel
4b47a48ea2 Hydra: Fix Cycles render delegate to build with USD 24.x 2024-06-26 21:06:40 +02:00
Harley Acheson
5c377686e7 UI: Use SVG Icons for Alert Icons on Dialogs
Use new SVG icons in place of current "Alert" icons, used on dialogs
and confirmations. No need for alert_icons.svg, alert_icons.png,
alert_icons_update.py. Also looks better as they are made at exact
requested size instead of 256x256 then scaled down to display.

Pull Request: https://projects.blender.org/blender/blender/pulls/123786
2024-06-26 20:54:20 +02:00
Brecht Van Lommel
a060de65a4 Cycles: Sync minor build related changes with standalone repo 2024-06-26 20:39:03 +02:00
howetuft
5e40dcc95d Cycles: Expose object node in XML API
The Object node is not currently exposed in the XML API, but rather
implicitly created along with Mesh nodes. This prevents accessing
features that are dependent on this node, like caustics settings.

Pull Request: https://projects.blender.org/blender/cycles/pulls/8
2024-06-26 20:39:03 +02:00
howetuft
dc35852107 Cycles: Expose vertex normals and tangent space attributes in XML API
The vertex normals and tangent space attributes are not currently exposed by
the XML API, in the Mesh node. This notably prevents the XML API user
from applying normal maps to meshes in tangent space.

To overcome this situation, this commit adds three attributes to the Mesh node:
N: vertex normals
tangent: tangents
tangent_sign: tangent signs

Nota: at the moment, these attributes are only available for non-subdivided
meshes.

Pull Request: https://projects.blender.org/blender/cycles/pulls/9
2024-06-26 20:39:02 +02:00
Pierre Pontier
3be050ed47 Fix: Cycles build error with GCC and Clang with some build options
Pull Request: https://projects.blender.org/blender/cycles/pulls/5
2024-06-26 20:39:02 +02:00
Brecht Van Lommel
d9bd35c4bc Cleanup: make format 2024-06-26 20:39:01 +02:00
Harley Acheson
fe4c7c4178 UI: Consistent Status Bar Spacing
Drawing operator keymap information on the status bar is sometimes
custom and and sometimes automatic. This PR just make the automatic
display have the same spacing as custom. Slightly tighter with a
greater proportion of space between items than between an item's
icon and text.

Pull Request: https://projects.blender.org/blender/blender/pulls/123785
2024-06-26 20:29:48 +02:00
Hans Goudey
aa4c42958d Fix: Sculpt: Anchored brush "restore" broken for refactored brushes
Currently the "Anchored" stroke option doesn't work on the refactored
brushes. That's because the previous implementation used the combination
and application of proxies to restore to the previous position stored in the
undo step. The new brushes don't use proxies for performance reasons,
so the restoration of shape keys and original positions didn't happen.

Now, fully restore the original positions of shape keys and mesh original
positions. This method is quite simple since it uses the same mechanism
brushes use to change that data.

Pull Request: https://projects.blender.org/blender/blender/pulls/123783
2024-06-26 20:10:43 +02:00
Harley Acheson
992e47bc45 Fix #123675: Use ICON_TYPE_MONO_TEXTURE Icons for Error Conditions
VSE is drawing error icons on strips using icons of type
ICON_TYPE_COLOR_TEXTURE, using the regular icon texture, which is
no longer used for standard icons. This PR changes this to use regular
UI_icon_draw_ex() here instead.

Pull Request: https://projects.blender.org/blender/blender/pulls/123700
2024-06-26 19:52:10 +02:00
Bastien Montagne
f6358f6e71 Merge branch 'blender-v4.2-release' 2024-06-26 19:28:22 +02:00
Damien Picard
f739d4832e I18n: Extract and disambiguate a few messages
Disambiguate
- "Thickness": use "Material" for EEVEE's thickness material setting.
- "Generated": use "Texture" for texture coordinates, "Image" for
  image source, keep default context for animation keyframe types.

Translate
- Split "Online access required to (check for|install) updates..."
  into 2x2 messages individually translatable.
- "Geometry" input in bake node.
- "New" for the Palette ID: extract it as part of the
   BLT_I18N_MSGID_MULTI_CTXT for "New".

Some issues reported by Gabriel Gazzán and Satoshi Yamasaki.

Pull Request: https://projects.blender.org/blender/blender/pulls/123404
2024-06-26 19:25:22 +02:00
Damien Picard
26cdf7e340 I18n: Extract many custom labels defined in uiItem*
Those labels needed a manual translation with IFACE_() or RPT_():
  - "Add Item",
  - "Blend",
  - "Cached from the first line art modifier.",
  - "Custom Curve",
  - "Custom Path",
  - "Custom Range",
  - "End",
  - "Enter a Unicode codepoint hex value",
  - "Forward Axis",
  - "Insert Unicode Character",
  - "Mid Level",
  - "Min",
  - "Mode",
  - "No Items",
  - "Object",
  - "Path",
  - "Probability",
  - "Sample Radius",
  - "Sharp edges or custom normals detected, disabling GPU subdivision",
  - "Start",
  - "Texture Mapping",
  - "Up Axis",
  - "Using both CPU and GPU subdivision",
2024-06-26 19:25:20 +02:00
Bastien Montagne
a50ab48709 Core: Cleanup: foreach_id: document acceptable return values from callbacks.
Essentially, callbacks in non-readonly are never expected to early-abort
the ID usages iteration. Add comments and an assert to ensure this.
2024-06-26 19:11:10 +02:00