Improve the selection of headers included in the precompiled header.
This reduces build time of the full `io/usd` directory by 12 to 19%.
Laptop i7-8750h: Average 30.3 sec --> 24.5 sec
Desktop i7-13700k: Average 12.1 sec --> 10.7 sec
Pull Request: https://projects.blender.org/blender/blender/pulls/140418
Small constant trivial referencing objects should be passed by value.
Current state of code most likely legacy from the times there was an optional strings.
Pull Request: https://projects.blender.org/blender/blender/pulls/138058
Replaces pointer based EXPECT_EQ_ARRAY with EXPECT_EQ_SPAN in most cases
as they already used spans (or span compatible datastructures).
Currently EXPECT_EQ_ARRAY only takes in one size variable and doesn't
compare the number of elements between arguments (requiring an
additional line to do so).
This should make the code cleaner and safer. Goal is also to promote
the use Spans in new test code.
Pull Request: https://projects.blender.org/blender/blender/pulls/140340
This replaces API for accessing the uiLayout active_default,
acviated_init, enabled properties with methods, following uiLayout
refactors and the Python API naming.
Pull Request: https://projects.blender.org/blender/blender/pulls/140226
Subtle visual tweaks to the way highlights are drawn in the Outliner
in order to improve readability.
* Similar to the File Browser, draw highlights as rounded corners.
* Draw an additional slightly lighter outline in active elements.
* Replace the dark background for dragged-onto elements with a
lighter color, and add an outline.
See PR for details and screenshots.
Part of #135192
Pull Request: https://projects.blender.org/blender/blender/pulls/140371
Make node headers (or body when collapsed) use the exact theme color
set for that node type, instead of a hardcoded blend between it and the
node backdrop.
This can result in unreadable combinations, but allows more
flexibility and it is consistent with the rest of Blender.
Both dark and light theme defaults have been updated.
See PR for details and screenshots.
Pull Request: https://projects.blender.org/blender/blender/pulls/140481
Previously `blend_name` was using the same path to get its file name
as `//` used. However, the choice of path for `//` seems to be
bespokely chosen at each call site. There may be a logic to it, but
if so it's not immediately clear what it is.
This PR changes `blend_name` to instead always use the currently open
("global") file path, making it well-defined and predictable for
users.
This also prepares better for PR #139438 for 5.0, which adds
`blend_name_lib`, which always uses the blend file that the ID owning
the path is linked from. Over-all this should be much more predictable
and controllable for users.
Pull Request: https://projects.blender.org/blender/blender/pulls/140474
Currently the mode transfer overlay has to check whether it should
draw for every single object. For scenes with many instances even
that small amount of work per object can be significant. I observed
the overlay taking 1.8% of the samples in a profile.
This commit removes the mode transfer timer and stores it in a
global map instead. Besides the benefit of removing 8 bytes per
object, the main improvement is that it's now trivial to check
whether the overlay can be completely disabled.
Pull Request: https://projects.blender.org/blender/blender/pulls/140374
This patch removes the Map Range node that was deprecated in 4.5 and was
planned for removal in 5.0. The common Shader Map Range node should be
used instead.
Pull Request: https://projects.blender.org/blender/blender/pulls/140476
From 4b4ed8bccc
The vert to loop map is unnecessary here, we don't need information
about neighboring faces. This was just incorrectly copied from older
code where this data was mixed with normal evaluation.
The BMesh python API was fully broken by this commit.
While the fix seems to be reasonably simple, it is safer for now to revert
the faulty commit, as the breakage is fairly impactful for people using 4.5
and/or 5.0 daily builds.
This reverts commit bd3a66a416.
This patch removes the Mix Color node that was deprecated in 4.5 and was
planned for removal in 5.0. The common Shader Mix Color node should be
used instead.
Pull Request: https://projects.blender.org/blender/blender/pulls/140468
Remove the last uses of `BKE_boundbox_init_from_minmax` in
favor of the newer `bounds::corners`. Besides clearer naming
and better ergonomics, it's also inline-able which seems to be a
good thing for such a simple function.
In order to get the same behavior as before I changed the
C++ bounds function to give the same vertex order as the
older function.
Pull Request: https://projects.blender.org/blender/blender/pulls/140401
Remove the `use_attribute_storage_write` experimental option and always
write in the new format, which is supported by 4.5. The new format is
only used at runtime by point clouds currently but there is no reason
for it to be an option at this point.
Pull Request: https://projects.blender.org/blender/blender/pulls/140284
This patch removes the Color Ramp node that was deprecated in 4.5 and
was planned for removal in 5.0. The common Shader Color Ramp node should
be used instead.
Pull Request: https://projects.blender.org/blender/blender/pulls/140462
- Removes asserts where polygon shaders are used to draw lines and
points. This is incorrect and leads to asserts in Vulkan.
- Kept as close to the existing control flow. Didn't want to introduce
regressions as this PR lands in 4.5
Pull Request: https://projects.blender.org/blender/blender/pulls/140337
The reasoning is that this is not supported by Vulkan.
In order to make shaders cross API compatible, python scripts
needs to use `GPUShaderCreateInfo`.
This removes the constructor all-together. Another option
is to raise an error inside the constructor and always
return none.
Rel #107374
Pull Request: https://projects.blender.org/blender/blender/pulls/140368
Nodes code uses direct access to enum property values definition
(outside of the RNA API) to generate UI (translated) messages, this is
risky/messy since the i18n context potentailly defined for the actual
RNA property is not available in these cases.
A few reports used string formatting in a way which made translation
awkward, by splitting the message into several individually translated
submessages, instead of just one message with formatting markers.
Pull Request: https://projects.blender.org/blender/blender/pulls/139895
Fix a crash in the inbetweener (and other similar tools) when bones have
custom properties, but no system properties. It just needed another
`nullptr` check.
Pull Request: https://projects.blender.org/blender/blender/pulls/140455
When initially saving a file, we would now always create a catalog
definition file that would be writted to disk on file save. This
shouldn't be done if there are no new catalogs to write.
This is replaced by geometry nodes, where volumes can now be generated from
point clouds and meshes with more control, and more efficient rendering as a
sparse volume.
No backwareds compatibility is provided, as this would be complicated, and
probably this feature was not used much in the past few years.
This node was supported in Cycles only, not by EEVEE.
Pull Request: https://projects.blender.org/blender/blender/pulls/140292
It is possible to resize tree view too much that only one row is
visible. To add the resize limit, clamp rows value in `tot_visible_row_count`,
that way visible rows are restricted when building the UI inside
`build_from_tree`. Limit is set to 4 (see `MIN_ROWS`).
Pull Request: https://projects.blender.org/blender/blender/pulls/140184