The new drawing operator uses the `paint_stroke` API which didn't
know about grease pencil yet. This simple change causes the redraw
to happen on every(?) event, which did not happen before.
The multiplication sign looks like an "x" but should be used in its
stead to display calculations and dimensions such as "1920x1080". It
is supported in many fonts including DejaVu Sans, the font currently
used for the UI.
Pull Request: https://projects.blender.org/blender/blender/pulls/106388
This is the minimal change required to start using modern CMake in the
blender build system. This change is designed to allow small
incremental changes to the build system rather than doing it in one
big bang which would be unmaintainable (for me)
The biggest functional change is, previously all libraries in the
`LIB` section of a `blender_add_lib` call had the `INTERFACE` scope,
which is rarely, if ever the correct scope. This diff changes this to
`PRIVATE`
Concrete implications of this diff :
The `LIB`, `INC` and `INC_SYS` sections of an `blender_add_lib` call
now allow scoping keywords (`PUBLIC`, `PRIVATE,` `INTERFACE`) to
declare the scope of the dependency.
Right now the only library using any modern cmake is
`bf_intern_atomic` which is an header only interface library that will
just advertise its include directories.
This allows us to clean up any `CMakeLists.txt` that adds
`../../../intern/atomic` to its `INC` section to remove it in `INC` by
adding a `PRIVATE bf_intern_atomic` to the `LIB` section.
Pull Request: https://projects.blender.org/blender/blender/pulls/107858
As suggested in #108669, the "Navigate during Transform" option has
been removed and this feature works by default.
Now if you press `G`, `R` or `S` to move, rotate or scale an object you
can also navigate in the viewport.
Note that this update modifies the default keymap.
Now pressing `Alt` is required for the following modals:
- `PROPORTIONAL_SIZE_UP`,
- `PROPORTIONAL_SIZE_DOWN`,
- `PROPORTIONAL_SIZE`,
- `AUTOIK_CHAIN_LEN_UP`,
- `AUTOIK_CHAIN_LEN_DOWN`,
- `AUTOCONSTRAIN`,
- `AUTOCONSTRAINPLANE`.
Pull Request: https://projects.blender.org/blender/blender/pulls/109388
The root of the issue was that when localizing all linked data, it makes
no sense (and there is no way) to keep liboverrides, since some linked
data would then remain linked.
The solution is then to clear any override data from localized IDs.
While simple in theory, this adds a noticeable amount of complexity to
the 'append' process, as now some IDs should remain linked, and some
should be forcefull copied (instead of directly made local), such that
the liboverride reference data remains valid.
NOTE: Appending without `Localize All` remains unchanged here, and will
keep the liboverrides untouched, since in that case having some linked
data as result of the append operation is expected.
This fix should be backported to the 3.6 LTS.
In some cases, when making a linked liboverride data local, the
liboverride data should be preserved (and therefore produce a local
liboverride data).
However, it implies that the data is not really, fully made local, since
it has (critical) dependencies to linked data.
This new option allows 'make local' code to also clear any liboverride
data in the processed ID, making it effectively fully local.
Preliminary step to solve #109004.
- Use C++ types for matrices and vectors;
- Deduplicate code with `SnapData::register_result`;
This commit also improves the way of detecting supported snap types.
In 3957a1ad03 was
added the new Rotation socket to a Mix node.
Mix node can be used in shaders node tree. This cause problem,
rotation socket is not supported in shader currently. This fix
just add check to ignore any unsupported sockets in shader and
to fix any related problem.
Pull Request: https://projects.blender.org/blender/blender/pulls/109410
This commit implements building of the layer tree hierarchy in the
layer tree UI.
Layer Groups that contain layers are now collapsible and visibility as well
as locking can be toggled.
This adds a `groups` collection property to the grease pencil data
to access group information.
For now groups have a `name`, `hide`, and `lock` property.
Similar how nodes and layers are cached in a flat vector, this commit
adds caching of layer groups. This will be used e.g. by the python API
to access all the groups as a collection property.
This adds functions to check if a `LayerGroup` is visible or locked.
Additionally, visibility and the lock state is now inherited.
E.g. `Layer`s that are the children of a hidden `LayerGroup` will also
be hidden. This does not change their stored visibility. It just means
that the function `is_visible()` on the layers will return `false`.
The same applies for locking.
`uiDefAutoButR` (or actually `uiDefButR_prop` > `ui_def_but_rna` later
down the line) has this behavior when "" string is passed in, it will
not display text on or next to the button.
This is of course desired in most scenarios -- it might even be desired
for non-icon enums in certain cases (though this is already a bit harder
to find cases for), so changing behavior in said functions is probably
not what we want.
The behavior - from the dopsheet sliders - would seem like a bug though.
Passing NULL (instead of "") to `uiDefAutoButR` results in properly
displaying the chosen item on the dropdown for enums, but for other
property types it would then show the property ui name alongside the
button (which is not what we want in the dopsheet, UI names are already
drawn there separately).
So now, pass "" or NULL conditionally (depending on property type
`PROP_ENUM`).
Pull Request: https://projects.blender.org/blender/blender/pulls/109205
This happened, because `SEQ_retiming_find_segment_start_handle()` does
not consider last handle as valid return value, so it was never checked
against.
In 3.6, the legacy to current mesh format conversion of edge creases
would crash when loading a file from 4.0, because it expected there to
be an `MEdge` array, which doesn't exist in 4.0. This didn't happen
previously because edge creases were stored in the same format for 4.0.
Other "legacy to current" format conversions have similar null checks,
it was just missing here.
Pull Request: https://projects.blender.org/blender/blender/pulls/109386
Checking to snap the region within a threshold didn't use the absolute
delta before comparison, making a larger snap size always pass
the threshold check.
Also assign variables for clarity.
Crash occurs during drawing on fresh added layer due to missing keyframe
on it. Use `insert_frame` to add frame on new layer.
This is similar to GPv2 (`BKE_gpencil_layer_frame_get` is used there to
add default keyframe on new layer)
Pull Request: https://projects.blender.org/blender/blender/pulls/109321
Add support a new Rotation socket/data type to a Mix node.
Rotation socket avala ible only in Geometry Nodes right now,
list of supported types for node depend on own node tree type.
Mixing kind is slerp (interpolation) of a quaternion. As initial
phase this is enough. In a future, other modes of interpolation
can be added (Euler for XY+Z, YZ+X, ZX+Y, ...). Clamping for
factor work the same as for all other data types.
Drag and drop should take care avoiding create links between
Rotation sockets and all other socket types, this requires chages
is mix node callback for drag & drop system.
See: https://projects.blender.org/blender/blender/issues/92967
Pull Request: https://projects.blender.org/blender/blender/pulls/109084
This is the same as 48fad9cd0c but applied to the positions
array instead of other generic attributes. For test case with 90k poly
curves, this reduced the conversion time from 1.7 to 1.3 ms, and reduced
memory usage from 67 to 59 MiB (as reported by Blender).