Use enum types for event modifier and types,
`wmEventModifierFlag` & `wmEventType` respectively.
This helps with readability and avoids unintended mixing with other
types. To quiet GCC's `-Wswitch` warnings many `default` cases needed
to be added to switch statements on event types.
Ref !136759
MacOS generally uses mouse cursors we specifically made for that
platform. But in some cases, like WM_CURSOR_WAIT, the OS does not have
an equivalent and we don't have a platform-specific one. So it then
uses of of our base custom cursors. This type of cursor is always
enlarged on Mac high-DPI displays like Retina. So no need to ever
supply larger versions of this type of cursor as it will just get
huge.
Pull Request: https://projects.blender.org/blender/blender/pulls/136005
Neighboring areas can have right-aligned and left-aligned scroll bars
that doesn't leave room for area resizing. This PR carefully reduces
the scroll bar zone size at the area edge. To ensure that the behavior
you get matches the mouse cursor you see, this corrects an error that
we were not setting cursor when transitioning from area border to
scroll bars.
Pull Request: https://projects.blender.org/blender/blender/pulls/136794
Add icons to the rna enum definitions for socket types so they
are displayed in all socket type selection lists like the ones on the
various loop zones.
These places were missed, when the socket icons were added in
commit 821e0024d4.
Pull Request: https://projects.blender.org/blender/blender/pulls/136707
Before #136334 hovering over a zone used to open closed regions, we
would show left/right or up/down directional arrow cursors. That PR
replaced those with chevron cursors that point in the specific
direction the region would open. That change has caused some confusion
so this PR restores those old cursors.
Pull Request: https://projects.blender.org/blender/blender/pulls/136583
This happened because the viewport was drawn after
the UV editor when some update occur (e.g. canceling an
operator). The requested UV edit batch would require only
one specific UV channel. The viewport, in need of a different
UV channel, requested a VBO rebuild (freing the old UV VBO)
but did not correctly clear the UV batches that were referencing
the said VBO. This lead to use after free which would sometime
works because the same memory would be reused for a random new
batch.
Pull Request: https://projects.blender.org/blender/blender/pulls/136780
Part of incoming refactors in interface layout C++ code, this enables
forward declaring this enum type outside of `layout_interface.cc`. The
enum is renamed as `ItemInternalFlag` and moved to the `blender::ui`
namespace. `uiItemInternalFlag` is preserved as a shorthand for
`blender::ui::ItemInternalFlag`.
No user visible changes expected.
Pull Request: https://projects.blender.org/blender/blender/pulls/136782
I get a warning in a bunch of places where `library_ensure_catalogs_in_path` is
called. This is a known false positive of GCC. To workaround the warning, the
`AssetCatalogPath` can be constructed in a separate statement to avoid
implicitly constructing it as temporary value when calling
`library_ensure_catalogs_in_path`.
Pull Request: https://projects.blender.org/blender/blender/pulls/136762
Render Overlay Meshes after the Grid.
As a side effect, in-front wireframe objects are now displayed behind
non-in-front edit mode overlays.
Co-authored-by: Clément Foucault
Pull Request: https://projects.blender.org/blender/blender/pulls/136764
Area light with a size of zero should not contribute to the scene, so
set the light as disabled.
This does not only fix the reported bug where such light is visible to
the camera, but also a regression in 4.2 where the light contributes to
the scene when light tree is off.
Pull Request: https://projects.blender.org/blender/blender/pulls/136763
This API is not properly implemented in other SYCL backends at the
moment and we don't want it to fail at runtime, so we conservatively
enable it only for Level-Zero.
Part of incoming refactors in interface layout C++ code, this enables
forward declaring this enum type outside of `layout_interface.cc`. The
enum is renamed as `ItemType` and moved to the `blender::ui` namespace.
`uiItemType` is preserved as a shorthand for `blender::ui::ItemType`.
No user visible changes expected, layout introspection will still print
item types using property enum identifier format.
Pull Request: https://projects.blender.org/blender/blender/pulls/136740
Different areas of this code were using different checks for whether a
specific curve combination has caps or not. Extract the check to a separate
function to avoid that problem.
Fix an issue where copy-paste of keyframes was broken when action groups
are collapsed. It was caused by the `ANIMFILTER_LIST_VISIBLE` filter
flag; removing it (as it was before the bug-introducing commit) resolved
the problem.
Pull Request: https://projects.blender.org/blender/blender/pulls/136768
This is done because the library is necessary to make certain FFTW
functions thread safe, see #136557 as well.
Also pass each library variable separately to
`find_package_handle_standard_args` instead of as a list, as otherwise
it won't correctly detect if `libfftw3f` or `libfftw3f_threads` is
missing. This is because CMake considers a value false if it contains
`-NOTFOUND` at the end, but not if it's in the middle. For example,
CMake considers
`.../libfftw3f.a;.../libfftw3f_threads.a;FFTW3_LIBRARY_D-NOTFOUND` to be
false, but
`.../libfftw3f.a;FFTW3_LIBRARY_THREADS_F-NOTFOUND;.../libfftw3.a` to be
true.
---
I noticed that some other find modules also have the same list issue. I guess it was done this way to make CMake print all the found libraries instead of only the first.
Pull Request: https://projects.blender.org/blender/blender/pulls/136692
Due to !133498 layers containing incorrect material indices could lead to generating
to many GPU resources crashing Blender. As there is a maximum number of material slots
we can limit it.
This is just a safeguard for incorrect values in material_index attribute layer. Working with
this material index attributes should automatically limit, but I leave that to the modeling
module.
Pull Request: https://projects.blender.org/blender/blender/pulls/136302
This was only working if one had `+ Non-Grouped Keyframes` enabled.So
code wasnt finding the bone name in the groups of the Action.That in
turn was caused by the fact that `animviz_calc_motionpaths` solely uses
`BKE_action_group_find_name` [which is documented to support only legacy
Actions].
To resolve, check if the action is legacy, otherwise get the
`Channelbag` and use its `channel_group_find`
Pull Request: https://projects.blender.org/blender/blender/pulls/136757
After reviewing the locations where `GPU_flush()` are used it doesn't seem
to be harmfull to include these for the Vulkan backend as well. Hopefully
will save some lag that can happen when submitting one huge render graph.
Improved playback of rain_restaurant.blend where frames could be dropped
resulting into UI lag.
Pull Request: https://projects.blender.org/blender/blender/pulls/136654
In light of recent changes by Jeroen, #124515 seems to have been resolved properly, rather then using this workaround.
This also sidesteps the issue seen in #136633 which only happens when GPU sibdiv is disabled.
Pull Request: https://projects.blender.org/blender/blender/pulls/136678
Mailbox is lowest latency V-Sync enabled mode. Previously we selected
FIFO as that was always available and has more support when using debug
tools.
Improve the #136521 situation as well.
Pull Request: https://projects.blender.org/blender/blender/pulls/136753
Part of incoming refactors in interface layout c++ code, this enables
forward declaring this enum type. Enum is renamed as `EmbossType` and
moved to `blender::ui` namespace. No user visible changes expected.
Pull Request: https://projects.blender.org/blender/blender/pulls/136725
Calling `merge all` operation in an empty list triggers the crash. Check
node size before further evaluation to prevent the crash
- Add GP object
- Remove all layers
- Execute `Merge All` operation
Pull Request: https://projects.blender.org/blender/blender/pulls/136652
uv_select_all_perform had split the UV_SYNC_SELECTION
case into a separate block which complicated changes in this area.
Now each UV select function handles the sync-select case.
Also make UV's const when only used for comparison.
Caused by 6c05859b12
OpenVDB does not handle transformations with determinants smaller than
3e-15 and throws an `ArithmeticError` when a `Transform` is created
with invalid values.
To avoid abrupt crashes on the user side, this commit catches the error
and displays a warning message.
Pull Request: https://projects.blender.org/blender/blender/pulls/136690