Commit Graph

121186 Commits

Author SHA1 Message Date
Sean Kim
5bd6f41ff5 Fix: Silence deprecated warning
Introduced in d73b8dd4f3

Unfortunately, the `Sculpt` struct has an implicitly generated copy
constructor which accesses the deprecated field in `sculpt_ops.cc`,
instead of allowing access to potentially deprecated fields at runtime,
this commit silences the warning by appending `_deprecated` to the field
and removing `DNA_DEPRECATED` from it.

Additionally, to preserve forward compatibility, the field is added to
`dna_rename_defs.h`

Pull Request: https://projects.blender.org/blender/blender/pulls/141298
2025-07-02 05:27:00 +02:00
Hans Goudey
1f92fd7577 Refactor: Use AttrType instead of CustomData type in attribute API
Change `eCustomDataType` to `bke::AttrType` for uses of the attribute
API (the `AttributeAccessor` one anyway). I didn't touch any values that
might be saved in files; those should be handled on a case by case basis.

Part of #122398

Pull Request: https://projects.blender.org/blender/blender/pulls/141301
2025-07-01 22:14:26 +02:00
Hans Goudey
09902044ff Fix: Default value ignored for some new builtin attributes
0dbe435aa8 was not complete.

Pull Request: https://projects.blender.org/blender/blender/pulls/141304
2025-07-01 21:27:14 +02:00
Jesse Yurkovich
2683c876f0 Fix: Increase maximum collection name length for Collection Export
Follow up to fdaaea6328

The initial collection export code used the wrong define.

Pull Request: https://projects.blender.org/blender/blender/pulls/141239
2025-07-01 20:14:35 +02:00
Hans Goudey
b6e58c54bb Cleanup: Use attribute API in Mesh RNA API
Pull Request: https://projects.blender.org/blender/blender/pulls/141295
2025-07-01 19:20:07 +02:00
Hans Goudey
0dbe435aa8 Fix: Invalid default value when creating some builtin attributes 2025-07-01 19:20:05 +02:00
Hans Goudey
85dae1757e Cleanup: Use attribute API for some solidify modifier inputs 2025-07-01 19:20:05 +02:00
Hans Goudey
d0b749beb8 Cleanup: Use attribute API in texture paint code 2025-07-01 19:20:05 +02:00
Hans Goudey
e9cd348a36 Cleanup: Use attribute API for colors in particle instance modifier 2025-07-01 19:20:05 +02:00
Hans Goudey
c2cadc4174 Cleanup: Use attribute API to access UV map select/pin attributes 2025-07-01 19:20:05 +02:00
Hans Goudey
bf0bcfb7c6 Cleanup: Use attribute API to access selection attributes 2025-07-01 19:20:05 +02:00
Hans Goudey
22e6aa619b Cleanup: Use attribute API to access UV maps in a few places 2025-07-01 19:20:05 +02:00
Hans Goudey
e54fc0a78d Cleanup: Use span accessor for mesh edges in softbody.cc 2025-07-01 19:20:05 +02:00
Hans Goudey
1f49ad963d Cleanup: Attributes: Remove outdated comment 2025-07-01 19:20:05 +02:00
Hans Goudey
54f81da296 Cleanup: Use span arguments for mesh mapping function
And use the attribute API to retieve UV seam data.
2025-07-01 19:20:05 +02:00
Hans Goudey
8fa54601e8 Cleanup: Remove unused mesh mapping function 2025-07-01 19:20:05 +02:00
Sean Kim
7e61ae1a2b Merge branch 'blender-v4.5-release' 2025-07-01 10:07:56 -07:00
Sean Kim
531bc5ca69 Fix: SubdivCCG uses 2x as much memory as needed for edge adjacency
On a Suzanne mesh with 125k faces subdivided at level 3, this patch
results in a 40MB savings of memory, from 1.24 GB measured in Blender
itself to 1.20 GB with this patch applied.

Pull Request: https://projects.blender.org/blender/blender/pulls/141167
2025-07-01 19:07:10 +02:00
Sean Kim
1278088aee Merge branch 'blender-v4.5-release' 2025-07-01 09:40:50 -07:00
Sean Kim
113225d6f8 Cleanup: Use references instead of pointers for subdiv_ccg.cc
Pull Request: https://projects.blender.org/blender/blender/pulls/141257
2025-07-01 18:36:05 +02:00
Sean Kim
750845589e Cleanup: Remove unused struct from subdiv_ccg.cc
Pull Request: https://projects.blender.org/blender/blender/pulls/141255
2025-07-01 18:31:21 +02:00
YimingWu
d6fcb6d1fe Fix #140934: Compositor: Support Grease Pencil pass in viewport
This patch adds support for viewport compositor for grease pencil pass.
It also comes with an option for viewing grease pencil pass directly
inside the viewport without compositor.

Pull Request: https://projects.blender.org/blender/blender/pulls/140960
2025-07-01 16:39:28 +02:00
Clément Foucault
caf659880f Fix #101702: EEVEE: Script node with shader output crashes blender
Fixed by removing connections to the script node before
doing any complex tree processing.

Pull Request: https://projects.blender.org/blender/blender/pulls/141280
2025-07-01 16:33:06 +02:00
Hans Goudey
68759af516 Attributes: Use AttributeStorage for curves and Grease Pencil
This commit moves Curves and Grease Pencil to use `AttributeStorage`
instead of `CustomData`, except for vertex groups. This PR mostly
involves extending the changes from the above commit for point clouds
to generalize to other geometry types.

This is mostly straightforward, though a couple non-trivial places of
note are the joining of Grease Pencil objects (`merge_attributes`), the
"default render fallback" UV for curves objects which was previously
unused at the UI level and just ended up being the first attribute, and
the `update_curve_types()` call in the curves versioning function.

Similar to:
- fa03c53d4a
- f74e304b00

Part of #122398.

Pull Request: https://projects.blender.org/blender/blender/pulls/140936
2025-07-01 16:30:00 +02:00
Christoph Lendenfeld
8da357f1ea Fix #140669: Graph Editor Gaussian smoothing causing artifacts for keys on subframes
This adds to the fix done with #110059.
With the changes of this patch, the smoothing still happens ONLY on full frames.
Any subframe data is linearly interpolated to reduce the stepping seen before this PR.

As a side effect, the operator now has to store the original y values of the keys in question.
This is needed for correct blending, whereas before it was assumed that the samples
contain the original y values.

No changes to the butterworth filter, because that already has a property to increase the
sample rate for sub-frame data.

Pull Request: https://projects.blender.org/blender/blender/pulls/140928
2025-07-01 16:02:49 +02:00
Falk David
8b9755b537 Merge branch 'blender-v4.5-release' 2025-07-01 15:33:50 +02:00
Falk David
cac2806ee2 Fix: Grease Pencil: Use correct "aspect_ratio" in draw tool
The `aspect_ratio` was defaulting to 0 when drawing. Now use the correct
brush setting values. This also ensures that the default is 1.
2025-07-01 15:33:01 +02:00
Miguel Pozo
75bf405647 Merge branch 'blender-v4.5-release' 2025-07-01 15:26:56 +02:00
Miguel Pozo
e2b898fea7 Fix #141132: Crash on background GP render
The crash seems to come from libepoxy GL functions pointing to null.
It seems that libepoxy "Automatically initializes as new GL functions are used."
and that to call a function without a GL context bound, the function
must have been called before with a bound context.

This just modifies the scope of the context binding from
DRW_module_exit to  RE_engines_exit, which seems the safest solution
for 4.5.

Pull Request: https://projects.blender.org/blender/blender/pulls/141233
2025-07-01 15:24:45 +02:00
Christoph Lendenfeld
8be420ff1f Merge branch 'blender-v4.5-release' 2025-07-01 14:33:41 +02:00
Christoph Lendenfeld
3233ddc3b3 Fix #141243: Crash when removing constraints with drivers via python
The issue was that the depsgraph was not rebuilt, thus
the driver node still stuck around. This then crashed when the
depsgraph evaluated.

The reason why this wasn't caught in the unit tests, was because the
depsgraph was not updated between creating and removing the data.

Pull Request: https://projects.blender.org/blender/blender/pulls/141272
2025-07-01 14:28:27 +02:00
Clément Foucault
c49e9e1773 Fix: Workbench: Incomplete commit 5231f0c02a
The commit didn't include the other part of the fix and
included an invalid changed line.
2025-07-01 12:44:12 +02:00
Philipp Oeser
5231f0c02a Action Slot selector UI: Show Slot Type
Expand the selector to not just show the name, but also the type icon,
similar to the Action editor channel list.
Adds it in the icon in both the unexpanded (currently selected) slot as
well as the Slots menu [the former being the more questionable one I
think].

Part of #137276

Pull Request: https://projects.blender.org/blender/blender/pulls/140970
2025-07-01 12:14:33 +02:00
Philipp Oeser
2c4dd6c6be Merge branch 'blender-v4.5-release' 2025-07-01 12:11:34 +02:00
Philipp Oeser
c261718085 Fix #141117: Sculpt mode edit voxel size stuck at certain values
It seemed "stuck" if the initial voxel size value under the remesh tab
was larger than or equal to the longer side of the bounding plane. It
actually was not stuck, but needed long mouse travels to get into the
range that we were clamping to (behavior from 4221f827cf clamps to
"sane" values on modal that make sense for differently sized meshes).

The "sane" sizes are kept, but this PR makes sure we actually start off
with an `init_voxel_size` that is already based on the clamped minimum/
maximum (so we dont have to mousetravel that far)

Pull Request: https://projects.blender.org/blender/blender/pulls/141208
2025-07-01 12:11:20 +02:00
Clément Foucault
1c41815c4d Fix: Workbench: Color imprecision for pure black color
The bias for mapping to log color space was wrong and
was assuming `log(2x)` instead of `log2(x)`.

This made pure black colors result in 0.00008 values
after AA resolve.

Using the correct bias ensures 0 stays at 0 during the
AA process and doesn't exhibit any imprecision.
2025-07-01 11:10:18 +02:00
Aras Pranckevicius
293cdac6ab Merge branch 'blender-v4.5-release' 2025-07-01 11:53:30 +03:00
Aras Pranckevicius
5cbb1c62c4 Fix #139552: VSE strips wrongly occlude others, when render resolution scale is small
get_strip_screen_quad function was not taking render scale into account,
unlike all other places that did a similar calculation.

Pull Request: https://projects.blender.org/blender/blender/pulls/141229
2025-07-01 10:49:10 +02:00
Damien Picard
81fa28fa26 I18n: Translate two report messages needing manual translation
This call to `BKE_reportf()` uses a tertiary operator to select a
message using singular or plural, which cannot be translated
automatically. This commit adds `RPT_()` translation for both
variants.

Reported by Ye Gui in #43295.
2025-07-01 10:47:09 +02:00
Damien Picard
ac1f875a2f I18n: Translate Insert Unicode Character Cancel/Confirm Buttons
These buttons use `uiDefIconTextBut`(), which needs manual translation
for the label using `IFACE()`.

Reported by Ye Gui in #43295.
2025-07-01 10:47:09 +02:00
Clément Foucault
1b499bdffb Fix #141112: EEVEE: Plane Probe is cut off in camera view if Shift X/Y
The projection matrix Y offset was not inverted properly to compensate
the view matrix Z axis flip.

Pull Request: https://projects.blender.org/blender/blender/pulls/141227
2025-07-01 10:06:56 +02:00
Aras Pranckevicius
ff5e9c66e7 Fix #141033: VSE proxies have inaccurate colors for YUV444 or full-range videos
When converting from say YUV444 to the YUV420 that proxies use,
ffmpeg libswscale was not being told of the full vs limited value
ranges as needed.

Pull Request: https://projects.blender.org/blender/blender/pulls/141241
2025-07-01 09:27:48 +02:00
Campbell Barton
9fc300a0ea Cleanup: rename the value used to store the cursor image
Rename `render_bmp` to `bitmap_rgba` since BMP has an assassination
with the BMP file format, and this is an RGBA equivalent of an existing
`bitmap` variable.
2025-07-01 17:13:50 +10:00
Campbell Barton
bd5346e94b Fix: missing error check when loading SVG cursors 2025-07-01 17:04:10 +10:00
Campbell Barton
2b34354392 Merge branch 'blender-v4.5-release' 2025-07-01 16:38:46 +10:00
Campbell Barton
dd0a38691b Merge branch 'blender-v4.5-release' 2025-07-01 16:38:36 +10:00
Campbell Barton
cbfa328327 Fix: memory leaks in SVG & WEBP thumbnail loader on error 2025-07-01 16:32:55 +10:00
Jorn Visser
46f23bd066 Fix: memory leaks in OpenEXR thumbnail loader on error
Delete file and stream when the file is incomplete, and free ibuf when
an exception occurs.

Found while working on !139739.

Ref !139885
2025-07-01 16:32:55 +10:00
Campbell Barton
f754cf3a61 Cleanup: use float2 for the cursor hot-spot
Also resolve a clang-tidy warning.
2025-07-01 15:56:31 +10:00
Campbell Barton
a3cd145f8d Cleanup: pass cursor pixel data by reference instead of by value 2025-07-01 15:38:23 +10:00